1) Script Title: Rollover background-color button
2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex5/button3.htm
3) Describe problem: Okay I have installed script ok, and all seems to be ok, but with I have 1 problem.
My site uses frames and in this script it seems you can only point to one 'TARGET' .
Is there any way I can point my links to two targets.
My script
<style type="text/css">
.initial2{font-weight:bold;background-color:lime}
</style>
<script type="text/javascript">
<!--
/***********************************************
* Rollover background-color button Script- © Dynamic Drive (www.dynamicdrive.com)
* This notice must stay intact for use
* Visit http://www.dynamicdrive.com/ for full source code
***********************************************/
//Specify optional button target: "_new" for new window, or name of FRAME target (ie "myframe")
var buttontarget="right_bot"
function change(e, color){
var el=window.event? event.srcElement: e.target
if (el.tagName=="INPUT"&&el.type=="button")
el.style.backgroundColor=color
}
function jumpto2(url){
if (buttontarget=="")
window.location=url
else if (buttontarget=="_new")
window.open(url)
else
parent[buttontarget].location=url
}
//-->
</script>
----------------------------------------------------------------------
<form onMouseover="change(event, 'yellow')" onMouseout="change(event, 'lime')">
<input type="button" value="Yahoo" class="initial2" onClick="jumpto2('http://yahoo.com')"> (Would like 1 of these links pointing to 'left_bot')
<input type="button" value="Google" class="initial2" onClick="jumpto2('http://google.com')">
<input type="button" value="AlltheWeb" class="initial2" onClick="jumpto2('http://alltheweb.com')">
</form>
Any help would be greatly appreciated.



Reply With Quote

Bookmarks