Help - Search - Members - Calendar
Full Version: Help with this syntax error
HTMLHelp Forums > Web Authoring > Markup (HTML, XHTML, XML)
Robs
Can anyone help me identify the syntax error in this code? I get an error on each line starting with <area shape according to IE error reporting.

<img src="images\home_display.JPG" usemap="#home_display" border=0>
<map name="home_display">
<area shape=CIRCLE coords="70,115,57" href="http://domain.com/index.php?cPath=105" alt="" Title="Protein Skimmers" OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Protein Skimmers"; return true">
<area shape=CIRCLE coords="208,60,58" href="http://domain.com/index.php?cPath=129" alt="" Title="Chillers" OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Chillers"; return true">
<area shape=CIRCLE coords="350,54,59" href="http://domain.com/index.php?cPath=121" alt="" Title="Sumps" OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Sumps"; return true">
<area shape=CIRCLE coords="494,59,60" href="http://domain.com/index.php?cPath=75" alt="" Title="Lighting" OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Lighting"; return true">
<area shape=CIRCLE coords="636,105,56" href="http://domain.com/index.php?cPath=114" alt="" Title="Pumps" OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Pumps"; return true">
<area shape=CIRCLE coords="62,315,62" href="http://domain.com/index.php?cPath=110" alt="" Title="Overflow Boxes"OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Overflow Boxes"; return true">
<area shape=CIRCLE coords="204,374,61" href="http://domain.com/index.php?cPath=66" alt="" Title="Test Equipment"OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Test Equipment"; return true">
<area shape=CIRCLE coords="350,399,59" href="http://domain.com/index.php?cPath=50" alt="" Title="Supplies"OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Supplies"; return true">
<area shape=CIRCLE coords="494,381,60" href="http://domain.com/index.php?cPath=69" alt="" Title="Heaters" OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Heaters"; return true">
<area shape=CIRCLE coords="640,325,58" href="http://domain.com/index.php?cPath=78" alt="" Title= "Water Filtration" OnMouseOut="window.status=""; return true" OnMouseOver="window.status="Water Filtration"; return true">
</map>
pandy
JavaScript errors you mean? You can't nest quotes of the same kind.

CODE
OnMouseOut="window.status=""; return true"


As you have it above, the stement is "window.status=" + some junk. Use single quotes for one of the quote pairs.
Robs
QUOTE(pandy @ Jul 23 2009, 03:59 PM) *

JavaScript errors you mean? You can't nest quotes of the same kind.

CODE
OnMouseOut="window.status=""; return true"


As you have it above, the stement is "window.status=" + some junk. Use single quotes for one of the quote pairs.



I am using a ' quote for my php. is there a way to ' outside " inside and then something else inside that?

Hope that makes sense coming from a nubie coder.
Robs
/' did the trick. thanks for the help. you got me going in the right direction.
Frederiek
AFAIK, the escape character is a backslash \, nor a forward slash /.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.