Hi all,
Sorry if this is a common thread. I did a search but couldn't find a solution I was looking for...
You know the popup that appears if you're not logged in about joining Daniweb, I need to put together one very similar for a forum I'm working on. All the functionality I want is an ajax popup showing our latest offer, with a close button, and the ability to set a cookie that expires in a month so it doesn't annoy our users and pop up each time they load a different page.
I figured I would use the jQuery library to display the popup when the page loads, whilst using Klaus Hartl's cookie plugin here:
http://plugins.jquery.com/files/jquery.cookie.js.txt
The problem is I'm a novice to javascript and have no idea how to integrate the two together. Would anyone happen to know where to start?
I know what I want to do, just not how to...
$(document).ready(function() {
// Check if cookie exists
// If exists, do nothing
// If it doesn't exist then invoke div later in HTML as modal AJAX popup
// Set cookie to expire in a month
});
Many thanks in advance for all your help
Paul