NamePros
Welcome, Guest! Ready to make a name for yourself in the domain business? We welcome both the hobbyist and professional domainer to join the discussion as part of the NamePros community.

Click here to create your profile to start earning reputation for posting, and trader ratings for buying & selling in our free e-marketplace. Build your trader rating with each successful sale. Our system has tracked over 100,000 sales and counting!
FAQ & TOS Register Search Today's Posts Mark Forums Read

Go Back   NamePros.com > Website Development Discussion Forums > Programming
Reload this Page [resolved] Some help with image display code

Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics.

Advanced Search


Closed Thread
 
LinkBack Thread Tools
Old 08-05-2008, 07:28 PM THREAD STARTER               #1 (permalink)
Senior Member
Join Date: Mar 2005
Location: canada
Posts: 1,045
skrilla is just really niceskrilla is just really niceskrilla is just really niceskrilla is just really niceskrilla is just really niceskrilla is just really niceskrilla is just really niceskrilla is just really nice
 


Protect Our Planet Child Abuse

Some help with image display code


Here is my code:

Code:
<div id="display1" style="display: none">
<div class="dropdown">
<img src="dropdown.jpg" name="ludwig13" border="0" usemap="#Map55">
  <map name="Map55">
    <area shape="rect" coords="10,3,90,18" href="index.php?section2=strategy" onMouseOver = "imgOFF('ludwig13');" onMouseOut = "imgON('ludwig13');">
    <area shape="rect" coords="10,21,90,37" href="index.php?section2=branding" onMouseOver = "imgOFF('ludwig14');" onMouseOut = "imgON('ludwig14');">
    <area shape="rect" coords="10,40,90,56" href="index.php?section2=advert">
    <area shape="rect" coords="11,59,90,73" href="index.php?section2=esolutions">
  </map>
</div>
</div>
I am trying to display a new image for each hotspot on my one image the first hotspot (ludwig13) works fine.. I cant seem to get the other 3 to swap the image tho.. i believe it has to do with
Code:
<img src="dropdown.jpg" name="ludwig13" border="0" usemap="#Map55">
The image only has 1 name...ludwig13..... can i assign several names to this image? please help..
????: NamePros.com http://www.namepros.com/programming/500657-resolved-some-help-image-display-code.html

I also have my script in place

Code:
<script language="JavaScript">
<!--
if (document.images) {             
	ludwigON = new Image();
	ludwigOFF = new Image();
    ludwigON.src = "tab4.jpg";  
    ludwigOFF.src = "tab4b.jpg"; 
	ludwig2ON = new Image();
	ludwig2OFF = new Image();
    ludwig2ON.src = "tab3.jpg";  
    ludwig2OFF.src = "tab3b.jpg"; 
	ludwig3ON = new Image();
	ludwig3OFF = new Image();
    ludwig3ON.src = "tab2.jpg";  
    ludwig3OFF.src = "tab2b.jpg"; 
	ludwig4ON = new Image();
	ludwig4OFF = new Image();
    ludwig4ON.src = "tab1.jpg";  
    ludwig4OFF.src = "tab1b.jpg"; 
	
	ludwig13ON = new Image();
	ludwig13OFF = new Image();
    ludwig13ON.src = "dropdown.jpg";  
    ludwig13OFF.src = "dropdown2.jpg"; 
	
	ludwig14ON = new Image();
	ludwig14OFF = new Image();
    ludwig14ON.src = "dropdown.jpg";  
    ludwig14OFF.src = "dropdown3.jpg"; 
}

function imgON(imagename) {
	if (document.images) {
		document[imagename].src = eval(imagename+"ON.src");       
	}
}

function imgOFF(imagename) {
	if (document.images) {
		document[imagename].src = eval(imagename+"OFF.src");        
	}
}
//-->
</script>
Ok never mind all.. I figured it out
__________________
Add Me to G+
skrilla is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


Liquid Web Smart Servers  
All times are GMT -7. The time now is 09:59 AM.

Managed Web Hosting by Liquid Web
Domain name forum recommended by Domaining.com Powered by: vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.6.0 Ad Management plugin by RedTyger