Launch new window, set its size and parameters, from image map

1108 views javascript
-4

I have an image with 22 defined map zones. The map looks like this:

map name="22_zones"
area shape="circle" coords="251,528,29" href="registration.php?r=22"
area shape="circle" coords="308,451,28" href="registration.php?r=21"
.
.
.
.
/map

I would like the map-driven hyperlink to spawn a new window, and set it size/scroll/size etc. In other instances -- not an image map -- I would use something like:

a href="#" onclick="javascript:window.open('../registration.php?r=22', 'none',menubar=no,scrollbars=yes,resizable=yes,location=no,directories=no,status=no,width=470,height=550');"

Can this approach be adapted to an image map?

answered question

1 Answer

2

My bad. It turns out HTML and Javascript require correct spelling. The fix:

<area shape="circle" 

coords="251,528,29" target="_blank" href="#" onclick="javascript:window.open('http://www.townofsilvercity.org/pickitupsc/registration.php?r=14', 'none', 'menubar=no,scrollbars=yes,resizable=yes,location=no,directories=no,status=no,width=470,height=550');">

posted this

Have an answer?

JD

Please login first before posting an answer.