Source: digitalfamily Blog

digitalfamily Blog Follow the cursor JavaScript sample

Here's a simple piece of code that you can copy and paste if you want to set up an effect where an object follows the cursor around your web page: <head><style>#divtoshow {position:absolute;display:none;color:white;background-color:black}#onme {width:150px;height:80px;background-color:yellow;cursor:pointer}</style><scripttype="text/javascript">var divName ='divtoshow';// div that is to follow the mouse (must be position:absolute)var offX =15;// X offset from mouse positionvar offY =15;// Y [...]The post Follow the cursor JavaScript sample appeared first on .

Read full article »
Est. Annual Revenue
$25-100M
Est. Employees
25-100
Janine Warner's photo - Managing Partner of digitalfamily

Managing Partner

Janine Warner

CEO Approval Rating

70/100