jEye plugin: documentation and demo page
Demo
In this page you see 2 jEye in action!
The first one is attached on body, you must move mouse around body and eyes follow you!
The second one is attached to a div of 250 pixels width and height. You must move mouse around this div and the eyes in the div follow you!
This is the javascript code to launch the 2 double eyes:
$().ready(function() {
$('body, #myBlock').jEye();
});
Documentation
To use this jquery plugin:
- download jquery.jEye.js and images files
- download last version of jquery.js
-
include the js in the head section of the page:
<head> ... <script type="text/javascript" src="js/jquery.js" ></script> <script type="text/javascript" src="js/jquery.jEye.js" ></script> ... </head>
-
in the read function launch the jEye relative at your element:
<script type="text/javascript"> $().ready(function() { $("body, #myBlock").jEye(); }); </script>
Download
You can download the entire archive:
- jquery.jeye.zip - a zip archive containing the plugin source, a minified version of jQuery and a demo page.
- jquery.jEye.js - js code.
- occhio.png - eye image.
- pupilla.png - pupil image.
Release
- 0.0 - Sep 17 2009 - First release of jEye
License
Dual licensed under the MIT and GPL licenses.