Category Archives: Other

Adding jquery – colorbox,thickbox popup on your blog/site with a time delay

Happy New Year, Everybody !!

You may have seen many sites/blogs use a time delayed light weight Jquery popups like colorbox,thickbox and lightbox etc. for capturing leads or promoting something. See a example here -> Facebook Profits ( First we see their normal salepage, but after some seconds they serve a discounted price page with the help of colorbox )

Lets do this here. I hope it will help you.

We are going to setup a content colorbox using a “settimeout” javascript function. For this we need to include two .js files and a .css file in our webpage’s header.

1. jquery core file        2. colorbox widget files

Add following lines before </head> tag of webpage.

<script src="file-path/jquery.js" type="text/javascript"></script>
<script src="file-path/colorbox.js" type="text/javascript"></script>
<link rel="stylesheet" href="file-path/colorbox.css" type="text/css" />

Download these files via following links :

Jquery.js : jQuery JavaScript library
Colorbox : colorbox widget

Colorbox can be used in many different ways like showing any outside URL in a frame box on any trigger of html element. You can find all example in the colorbox download. We are going to supply a url to colorbox main function which will popup a box with the supplied url.

So here is the colorbox function, we will use to pass url…