Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

JavaScript Forum


You are currently viewing our JavaScript Forum as a guest. Please register to participate.
Login



Reply
need help with button
Old 10-18-2010, 11:21 PM need help with button
Banned

Posts: 408
Name: mushget
Trades: 0
i am trying to make a button which is a .gif that will change when a mouse over occurs and a animation will occur when click then will relocate to a new page but i am getting multiple images at the same time pleas help.
Code:
<html>
<body>
<img src="Jepordy/Fla files/Button set 1.gif" >
<img name="jsbutton" src="Jepordy/Fla files/Button set 1.gif" width="550" height="400" border="0" alt="javascript button">
<SCRIPT language="JavaScript">
var myimgobj = document.images["jsbutton"];
</SCRIPT>
<A href="#" onMouseOver="return changeImage()" ><img
name="jsbutton" src="Jepordy/Fla files/Button mouse over.gif" width="550" height="400" border="0"
alt="javascript button"></A> 
<SCRIPT language="JavaScript">
function changeImage()
{
document.images["jsbutton"].src= "C:\Documents and Settings\fus10n\Desktop\Jepordy\Fla files\Button mouse over.gif";
return true;
}
</SCRIPT> 
  <A href="#" onMouseOver="return changeImage()" onMouseOutwidth="550" height="400" border="0" alt="javascript button"= "return changeImageBack()"
onMouseDown="return handleMDown()" onMouseUp="return handleMUp()"
><img
name="jsbutton" src="Jepordy/Fla files/Button set 1.gif" width="550" height="400" border="0"
alt="javascript button"></A>

<SCRIPT language="JavaScript">
function changeImage()
{
document.images["jsbutton"].src= "C:\Documents and Settings\fus10n\Desktop\Jepordy\Fla files\Button set 1.gif";
return true;
}
function changeImageBack()
{
 document.images["jsbutton"].src = "C:\Documents and Settings\fus10n\Desktop\Jepordy\Fla files\Button set 1.gif";
 return true;
}
function handleMDown()
{
 document.images["jsbutton"].src = "C:\Documents and Settings\fus10n\Desktop\Jepordy\Fla files\Button set 1.gif";
 return true;
}
function handleMUp()
{
 changeImage();
 return true;
}
</SCRIPT>
<A href="QUESTION LOCATION FOR THIS BUTTON GOES HERE!"
onMouseOver="return changeImage()" onMouseOut= "return changeImageBack()"
onMouseDown="return handleMDown()"
onMouseUp="return handleMUp()">
  <A href="http://www.javascript-coder.com/"
onMouseOver="return changeImage()"
onMouseOut= "return changeImageBack()"
onMouseDown="return handleMDown()"
onMouseUp="return handleMUp()"
><img
name="jsbutton" src="Jepordy/Fla files/Button mouse over.gif" width="550" height="400" border="0"
alt="javascript button"></A>


</body>
</html>
mushget is offline
Reply With Quote
View Public Profile Visit mushget's homepage!
 
 
Register now for full access!
Old 10-19-2010, 01:56 PM Re: need help with button
Skilled Talker

Posts: 52
Name: Alex
Trades: 0
<img src="Jepordy/Fla files/Button mouse over.gif" width="550" height="400" border="0" alt="javascript button" Onmouseover="this.src='somegif';" Onmouseout="this.src='somegif2';" OnClick="this.src='somegif3';">

dont forget to preload these images
elf2002 is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to need help with button
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.32926 seconds with 12 queries