Load Jquery
<script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jqueryui/1.10.3/jquery-ui.min.js"></script>
I'm trying to get a popup to only load once then not show again for another 31 days.
<script type="text/javascript"><!--
jQuery(document).ready(function()
{
if (jQuery.cookie('test_status') != '1')
{
setTimeout(function()
{
jQuery('.lightbox-handle').reveal()
jQuery('.lightbox-handle').click();
jQuery.cookie('test_status', '1', { expires: 31});
}, 1000);
}
});
//--></script>
Are you including the jQuery cookie plugin, https://github.com/carhartl/jquery-cookie. You can find on CDNJS at http://cdnjs.cloudflare.com/ajax/libs/jquery-cookie/1.3.1/jquery.cookie.min.js
Works for this fiddle http://jsfiddle.net/WyYZ8/
I had the same problem and I found this solution: