Ok. I did a search to find any easy solutions but I haven't found any. I am a n00b in javascript so please bear with me. I know what needs to be done though but I don't know how to do it. I want to run this script once only per day. <script src="example.js" language="javascript"></script> Code (markup): I know I have to use cookies... something along the lines of: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_22775587.html http://www.weberdev.com/get_example-4280.html But I don't know how to implement this run once function. I don't know where to put the code in the html or what to put in the html and what to put in the separate javascript cookie file... Please help? Thanks!
<?php if(!isset($_COOKIE['coockieName'])) { $expire=time()+60*60*24; setcookie("coockieName", "value", $expire); echo "<script src=\"example.js\" language=\"javascript\"></script>"; } ?> PHP: