SMF For Free Support Forum
Signup For Free Forum
August 30, 2008, 07:52:01 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Welcome to SMF For Free. The best free SMF Host
 
   Home   Help Search Arcade Gallery Login Register  

Pages: [1]
  Print  
Author Topic: Help with HTML code please, gurus  (Read 289 times)
0 Members and 1 Guest are viewing this topic.
Nutz
SMF For Free Sr. Member
*
Offline Offline

Posts: 251


Aloha from Maui


View Profile
« on: June 19, 2007, 01:41:24 pm »

Forum Url: http://w123gassers.smfforfree2.com
Dunno,I can't get the first name links to set to the right which they are supposed to do. Can't even position below equally  idiot2
Is it the software? PS,it's a rollover code,meaning if you place your cursor over the link,the photo changes.



You can see it in the first forum at my site
Code:
<SCRIPT TYPE="text/javascript"><!--

// var image information object
var mloi=new Object();

// set the image for swapping
function setswap()
{
if (! document.images)return;
var imgInfo=new Object();
imgInfo.defaultImg = new Image();
imgInfo.defaultImg.src = document.images[arguments[0]].src;
imgInfo.opts = new Object();
for (var i=1; i < arguments.length; i=i+2)
   {
   imgInfo.opts[arguments[i]]=new Image();
   imgInfo.opts[arguments[i]].src = arguments[i+1];
   }
mloi[arguments[0]] = imgInfo;
}

// set up the link for swapping
function swap(link,imgName,optName)
{
if (! document.images)return;
if (! link.swapReady)
   {   
   link.imgName    = imgName;
   link.onmouseout = swapBack;
   link.swapReady  = true;
   }
document.images[imgName].src=mloi[imgName].opts[optName].src;
}

function swapBack()
   {document.images[this.imgName].src=mloi[this.imgName].defaultImg.src}

//-->
</SCRIPT>
<IMG SRC="http://i169.photobucket.com/albums/u207/sharktrainers/speedo123.jpg"
   WIDTH=100 HEIGHT=100 ALT="W123 Photo Contributors"
NAME="showperson"><SCRIPT TYPE="text/javascript"><!--
setswap("showperson",
   'StreekG',              'http://i169.photobucket.com/albums/u207/sharktrainers/str1.jpg',
   'streetrules',          'http://i169.photobucket.com/albums/u207/sharktrainers/Upintheclouds2.jpg',
   '79Mercy',             'http://i169.photobucket.com/albums/u207/sharktrainers/mer2.jpg',
   'vipercrazy',           'http://i169.photobucket.com/albums/u207/sharktrainers/vip2.jpg',
   'des',                    'http://i169.photobucket.com/albums/u207/sharktrainers/des2.jpg'
   );
//--></SCRIPT>
<A HREF="http://w123gassers.smfforfree2.com/index.php/topic,18.0.html"    onMouseOver="swap(this,'showperson','StreekG')">StreekG</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php/topic,43.0.html" onMouseOver="swap(this,'showperson','streetrules')">streetrules</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php?action=gallery;sa=view;id=25" onMouseOver="swap(this,'showperson','79Mercy')">79Mercy</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php?action=gallery;sa=view;id=39"  onMouseOver="swap(this,'showperson','vipercrazy')">vipercrazy</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php/topic,152.0.html"  onMouseOver="swap(this,'showperson','des')">des</A>
« Last Edit: June 19, 2007, 01:46:23 pm by Nutz » Logged

Agent Moose
Moderator
*****
Offline Offline

Posts: 623


Do not PM me for Code Support or Request


View Profile WWW
« Reply #1 on: June 19, 2007, 01:50:52 pm »

Try this:
Code:
<SCRIPT TYPE="text/javascript"><!--

// var image information object
var mloi=new Object();

// set the image for swapping
function setswap()
{
if (! document.images)return;
var imgInfo=new Object();
imgInfo.defaultImg = new Image();
imgInfo.defaultImg.src = document.images[arguments[0]].src;
imgInfo.opts = new Object();
for (var i=1; i < arguments.length; i=i+2)
   {
   imgInfo.opts[arguments[i]]=new Image();
   imgInfo.opts[arguments[i]].src = arguments[i+1];
   }
mloi[arguments[0]] = imgInfo;
}

// set up the link for swapping
function swap(link,imgName,optName)
{
if (! document.images)return;
if (! link.swapReady)
   {   
   link.imgName    = imgName;
   link.onmouseout = swapBack;
   link.swapReady  = true;
   }
document.images[imgName].src=mloi[imgName].opts[optName].src;
}

function swapBack()
   {document.images[this.imgName].src=mloi[this.imgName].defaultImg.src}

//-->
</SCRIPT>
<IMG SRC="http://i169.photobucket.com/albums/u207/sharktrainers/speedo123.jpg"
   WIDTH=100 HEIGHT=100 ALT="W123 Photo Contributors"
NAME="showperson"><br /><SCRIPT TYPE="text/javascript"><!--
setswap("showperson",
   'StreekG',              'http://i169.photobucket.com/albums/u207/sharktrainers/str1.jpg',
   'streetrules',          'http://i169.photobucket.com/albums/u207/sharktrainers/Upintheclouds2.jpg',
   '79Mercy',             'http://i169.photobucket.com/albums/u207/sharktrainers/mer2.jpg',
   'vipercrazy',           'http://i169.photobucket.com/albums/u207/sharktrainers/vip2.jpg',
   'des',                    'http://i169.photobucket.com/albums/u207/sharktrainers/des2.jpg'
   );
//--></SCRIPT>
<A HREF="http://w123gassers.smfforfree2.com/index.php/topic,18.0.html"    onMouseOver="swap(this,'showperson','StreekG')">StreekG</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php/topic,43.0.html" onMouseOver="swap(this,'showperson','streetrules')">streetrules</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php?action=gallery;sa=view;id=25" onMouseOver="swap(this,'showperson','79Mercy')">79Mercy</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php?action=gallery;sa=view;id=39"  onMouseOver="swap(this,'showperson','vipercrazy')">vipercrazy</A><BR>
<A HREF="http://w123gassers.smfforfree2.com/index.php/topic,152.0.html"  onMouseOver="swap(this,'showperson','des')">des</A>
Logged

Eternal Flame Coming Soon

SMC Code Index - The best Code Index for all your Needs!  Includes a bunch of codes not on Support.
Nutz
SMF For Free Sr. Member
*
Offline Offline

Posts: 251


Aloha from Maui


View Profile
« Reply #2 on: June 19, 2007, 01:56:39 pm »

Hey,you're good! Any way to get the name links to set to the right side of that image though? Thanks regardless,I was getting quite irritated with it Wink
Logged

Nutz
SMF For Free Sr. Member
*
Offline Offline

Posts: 251


Aloha from Maui


View Profile
« Reply #3 on: June 19, 2007, 02:06:46 pm »

Oh,like this is what I mean (photoshopped it,didn't figure it out)



Logged

Agent Moose
Moderator
*****
Offline Offline

Posts: 623


Do not PM me for Code Support or Request


View Profile WWW
« Reply #4 on: June 19, 2007, 02:26:33 pm »

Sorry, I can't do that.  I am not good with working with columns...sorry.
Logged

Eternal Flame Coming Soon

SMC Code Index - The best Code Index for all your Needs!  Includes a bunch of codes not on Support.
Nutz
SMF For Free Sr. Member
*
Offline Offline

Posts: 251


Aloha from Maui


View Profile
« Reply #5 on: June 19, 2007, 02:32:01 pm »

Ah,no worries Smiley Thanks again for getting it like it is now,I was completely stumped.
Logged



Pages: [1]
  Print  
 
Jump to:  

Powered by SMF 1.1.5 | SMF © 2006-2008, Simple Machines LLC
ServerBeach Coupon
Page created in 0.826 seconds with 17 queries.