Closed Thread Icon

Preserved Topic: onmouseover function inside script (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=17752" title="Pages that link to Preserved Topic: onmouseover function inside script (Page 1 of 1)" rel="nofollow" >Preserved Topic: onmouseover function inside script <span class="small">(Page 1 of 1)</span>\

 
RyanS09
Obsessive-Compulsive (I) Inmate

From: decatur, il, usa
Insane since: Jun 2000

posted posted 06-05-2000 07:38

I have a menu in which there is a script that looks as follows

ecMenu[0] = new menuLink("Text", "link.htm")
the text is just Text, and the link is a link to link.htm

I am wondering if i can combine this script and put mouseover functions such as

onmouseout="btnTimer(); change('design',0)"
onmouseover="showLayer('designMenu');change('design',1)"

inside of the above script. I think it can be done, but i am not sure how the syntax would go for it. Thank you very much, and any help is appriciated.

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 06-05-2000 22:30

hmm.... not enough info. you should have a function in this page that creates menulink objects. I'd really need to see that to tell you where to add the onmouseover stuff. (a link to the full page would actually be helpfull)


Walking the Earth like Kane

RyanS09
Obsessive-Compulsive (I) Inmate

From: decatur, il, usa
Insane since: Jun 2000

posted posted 06-05-2000 22:35

http://www.ecweb2000.com/home.shtml
there it is. the actual script i am having trouble with is http://www.ecweb2000.com/navmenus.js
thanks a lot.
Ryan

bitdamaged
Maniac (V) Mad Scientist

From: 100101010011 <-- right about here
Insane since: Mar 2000

posted posted 06-05-2000 23:38

Okay, this is a little tricky, but it can be done. I think what you want to do is when you mouseover one of the items in the drop down menus it calls the timer fucnction and changes some other image right?.

Okay in the .js script there is a function called MenuMaker. in there is a line that looks like this.

"n += bgnrow + "<a href='" + eval(menuArray + "[" + i + "].url") + "' onMouseOver='menuOver(\"" + eval(menuArray + ".imgname") + i + "\")' onMouseOut='menuOut(\"" + eval(menuArray + ".imgname") + i + "\")' class='menus' target='_top'>" + eval(menuArray + "[" + i + "].title") + "</a>" + endrow"

This is the line that writes the script for these links if you look in there you will see that there are already onMouseover and onMouseout events.

onMouseOver='menuOver(\"" + eval(menuArray + ".imgname") + i + "\")

onMouseOut='menuOut(\"" + eval(menuArray + ".imgname") + i + "\")

this is where you want to add the calls. I hope you are familiar with the eval statement cuz this uses it a lot. to call the btnTimer function you can just add it it at the end of the mnouse out line here:

onMouseOut='menuOut(\"" + eval(menuArray + ".imgname") + i + "\");btnTimer()

then there should be the change call. Because this is written in a "for" loop it will be a little tricky but it should lookk something like this:

onMouseOut='menuOut(\"" + eval(menuArray + ".imgname") + i + "\");btnTimer();change(eval("'design','"+ i +"'")); and then the single quote that is already written in the script.

The onMouseover would be something similar.

Does any of this make sense? It looks like you are using someone elses script here and what you are trying to do requires you to have a pretty solid understanding of how the script works. in order to tweak it. If you don't you are going to have trouble. This script is kinda long but actually not that complicated, work it through and you should be able to figure it out, if not you can e-mail me (click on the link above) with specific questions




Walking the Earth like Kane

« BackwardsOnwards »

Show Forum Drop Down Menu