Solved

Delay onmouseover effect for 1 second

Posted on 2006-07-08
2
340 Views
Last Modified: 2012-06-22
in the following script there is only one modication that I wish to make, that is I want the mouse to hover over the link for 1 second before the mouseover effect takes place, is this possible

<a  onmouseover="javascript:this.style.cursor='hand';window.open('http://whatever.html','mypage','')"</A>
0
Comment
Question by:kempvet
2 Comments
 
LVL 26

Accepted Solution

by:
DireOrbAnt earned 500 total points
ID: 17067035
<SCRIPT LANGUAGE="JavaScript">
var TimerID = 0;
function StartOver() {
  TimerID = setTimeout('ActivateOver()', 1000);
}

function StopOver() {
  if (TimerID) {
        clearTimeout(TimerID);
            TimerID = 0;
      }
}

function ActivateOver() {
  window.open('http://whatever.html','mypage','');
}
</SCRIPT>

<a href="javascript:;" onmouseover="StartOver()" onmouseout="StopOver()">Test me</a>
0
 

Author Comment

by:kempvet
ID: 17067069
thanks, I suspected that a function may need to be called, this then saves the hassle when someone is moving their mouse to another page and just flicking over the link,
regards
kempvet
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Javascript create file issue 4 48
Auto refresh part of an MVC5 View 7 57
Google Sheets Script 21 57
what is the difference between currentTarget and target 4 34
When you need to keep track of a simple list of numbers or strings, the Array object is your most direct tool.  As we saw in my earlier EE Article (http://www.experts-exchange.com/A_3488.html), typical array handling might look like this: (CODE) B…
Article by: DanRollins
This article describes a JavaScript program that creates a maze made of hexagonal cells.  In Part 2 (http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/A_7850-Hex-Maze-Part-2.html), we'll extend the program by adding a depth-…
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now