Damn man you write the hardcore xhtml huh? So you're supposed to put scripts inside cdata, why?
Is this GIS stuff? Looks like it. > -----Original Message----- > From: Tony [mailto:[EMAIL PROTECTED] > Sent: Thursday, May 25, 2006 3:46 PM > To: CF-Community > Subject: CrossPost from CF-Talk: Javascript Question > > Hi there... this should be quick and easy for you Jscript ninja's... > > in this line: > marker.openInfoWindowHtml("#url.address# #url.city# #url.state# > #url.zip# Report time: #url.time# Report Date: #url.date# "); > > i want to put <BR>'s so that the text, line breaks, and the pop up > window isnt huge. > > any idea how to add that into the string, so that it doesnt break it? > > > <script type="text/javascript"> > //<![CDATA[ > <cfoutput> > function load() { > if (GBrowserIsCompatible()) { > var map = new GMap2(document.getElementById("map")); > map.setCenter(new GLatLng(#insert('.',url.lat,2)#, > #insert('.',url.lon,3)#), 13); > map.addControl(new GLargeMapControl ()); > map.addControl(new GMapTypeControl()); > > // Creates a marker at the given point with the > given number label > function createMarker(point, number) { > var marker = new GMarker(point); > GEvent.addListener(marker, "click", function() { > marker.openInfoWindowHtml("#url.address# > #url.city# > #url.state# #url.zip# Report time: #url.time# Report Date: #url.date# > "); > }); > return marker; > } > // Add 1 markers to the map > for (var i = 0; i < 1; i++) { > var point = new GLatLng(#insert('.',url.lat,2)#, > #insert('.',url.lon,3)#); > map.addOverlay(createMarker(point, i + 1)); > } > } > } > </cfoutput> > //]]> > </script> > > > thanks! > tony > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:5:207570 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/5 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:5 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.5 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
