Home > JavaScript > replacing your pop-ups with DOMInclude

replacing your pop-ups with DOMInclude

Using DOMinclude library you now can easy replace old pop-up script with new one, it’s written using fully CSS and DOM. This is one of new techniques today for developing web page. You can go to this page for more information or download .zip file using this link

Steps to install DOMinclude:

1. You need two script files: DOMinclude_config.js and DOMinclude.js.Then put them to the head of your web page

2. Instead of callling <a href=”your link”> link</a> now you just place a class atttribute into <a> tag, like this: <a href=”saywhat.jpg” class=”DOMpop”>photo of a confused puppy</a>

3. Alter the configuration by editing the DOMinclude_config.js file:

DOMinccfg={
   // CSS classes
   // trigger DOMinclude
   triggerClass:’DOMpop’,
   // class of the popup
   popupClass:’popup’,
   // class of the link when the popup
   // is open
   openPopupLinkClass:’popuplink’,
   // text to add to the link when the
   // popup is open
   displayPrefix:’Hide ‘,
   // filter to define which files should
   // not open in an iframe
   imagetypes:’jpg|JPG|JPEG|jpeg|gif|GIF|png|PNG’,
   // dimensions of the popup
   frameSize:[320,180]
}
Advertisements
Categories: JavaScript Tags:
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: