Satisfy Your Sweet Tooth!

Subscribe to Emails and You'll Never Miss a Recipe!

console.log( "Server Timestamp is " + swp_cache_data.timestamp ); var browser_date = Date.now(); if( !browser_date ) browser_date = new Date().getTime(); browser_date = Math.floor( browser_date / 1000 ); console.log( "Browser Timestamp is " + browser_date ); var elapsed_time = ( swp_cache_data.timestamp - browser_date ); if( elapsed_time > 60 ){ console.log( "Elapsed time since server timestamp is greater than 60 seconds -- " + elapsed_time + "seconds" ); within_timelimit = false; } else { console.log( "Elapsed time since server timestamp is less than 60 seconds -- " + elapsed_time + "seconds" ); within_timelimit = true; } if( within_timelimit === true ){ jQuery.post( swp_admin_ajax, swp_cache_data, function( response ) { console.log(response); }); socialWarfarePlugin.fetchShares(); } } } , 250 ); }); swp_post_id='6132'; swp_post_url='http://sarahsbakestudio.com/best-chocolate-chip-cookies-for-two/'; swp_post_recovery_url = 'http://sarahsbakestudio.com/2014/09/best-chocolate-chip-cookies-for-two/'; // socialWarfarePlugin.fetchShares(); }