PHP Classes

rollover: Basic rollover images

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 1,826 All time: 2,155 This week: 488Up
Version License Categories
rollover 1.0GNU General Publi...HTML
Description 

Author

Basic rollover images

Picture of Carlos Falo Hervás
Name: Carlos Falo Hervás <contact>
Classes: 10 packages by
Country: Spain Spain
Age: 49
All time rank: 361 in Spain Spain
Week rank: 195 Down7 in Spain Spain Down
Innovation award
Innovation award
Nominee: 1x

Details

===== BASIC DOCUMENTATION FOR rollover class ===== 0.- INTRODUCTION The class handles generation of a rollover image (that means an image that changes whenever the mouse is over it or not). Javascript interface is based on old dynlayer api and works well on all 3 major browsers (IE 5.x, NS 4.x, NS 5+) and has been tested up to 1 layer depth (i.e. <div ....><img ...></div>) but will possibly fail on a more intrincated layer structure (almost for sure... at least on NS browsers) 1.- INTERFACE The public interface for the class is formed by: rollover($dirapp,$layer,$imgname,$baseimg,$selimg,$alt="",$link="#") CONSTRUCTOR: initializes all data $dirapp -> root directory for the web to path generation operations $layer -> name for the layer where the img is places $imgname -> name for the image (<img name='XXXX'...) $baseimg -> src for the not selected image $selimg ->src for the selected image $alt -> alt text for the image $link -> where to link from the image (as onMouseOver/Out is on an <a> element preload() PRELOADER: Generates the extra img objects used by the JavaScript NOTE: must be called within an existing <script> tag image() GENERATOR: puts the image and the event handling on screen The Javascript interface works in 2 functions (placed in the images.js file) that must be included in the page (i.e. <script language=javascript src=images.js></script>) preload(imgobj,srcimg) imgobj -> string: name for the img object srcimg -> string: path & filename for the image to preload changeImage(layer,image,imgobj) layer -> string: name for the layer where the img is placed image -> string: name for the image that does 'roll' imgobj-> string: name for the imgobject with the new image 2.- Future releases and WIP This class will not have many revisions as it is fully functional for it's intended use. For further developement any suggestions appreciated 3.- Contact information Carlos Falo Hervás carles@bisinteractive.net http://www.bisinteractive.net C/Manila 54-56 Esc. A Ent. 4ª 08034 Barcelona Spain Phone: +34 9 3 2063652 Fax: +34 9 3 2063689

  Files folder image Files (4)  
File Role Description
Accessible without login Plain text file example.php Example a little usage example
Accessible without login Plain text file images.js Appl. Javascript functions required (from old dynlayer api)
Accessible without login Plain text file README_EN Doc. Documentation
Plain text file rollover.php Class Base class

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:1,826
This week:0
All time:2,155
This week:488Up
User Comments (1)
Error on line 30 (rollover.
9 years ago (Juan Jose)
25%StarStar