shage Posted November 6, 2007 Share Posted November 6, 2007 I have a database that has a date such as 2007-12-01 with a inactive colum, what is the best way to have it make that cell active on the date that is in the date cell? So on 2007-12-01 that site would be active. Thank you Link to comment https://forums.phpfreaks.com/topic/76156-solved-date/ Share on other sites More sharing options...
toplay Posted November 6, 2007 Share Posted November 6, 2007 I have a database that has a date such as 2007-12-01 with a inactive colum, what is the best way to have it make that cell active on the date that is in the date cell? So on 2007-12-01 that site would be active. Thank you You really got to expand on what you mean and want to accomplish, I'm not sure if you're asking for a MySQL help or PHP related help. What does "cell" mean and "that site would be active" mean? Link to comment https://forums.phpfreaks.com/topic/76156-solved-date/#findComment-385423 Share on other sites More sharing options...
smc Posted November 6, 2007 Share Posted November 6, 2007 A cron job is really your best bet. Just run a cron that says <?php if( strtotime( $mySQL ) >= time() ){ $sql = mysql_query( "UPDATE myTable SET activityColumn = 'true'" ); } ?> Or along those lines Link to comment https://forums.phpfreaks.com/topic/76156-solved-date/#findComment-385425 Share on other sites More sharing options...
shage Posted November 6, 2007 Author Share Posted November 6, 2007 I have a database that has a date such as 2007-12-01 with a inactive colum, what is the best way to have it make that cell active on the date that is in the date cell? So on 2007-12-01 that site would be active. Thank you You really got to expand on what you mean and want to accomplish, I'm not sure if you're asking for a MySQL help or PHP related help. What does "cell" mean and "that site would be active" mean? the sites are inactive until the date, now looking to make the site active on the date in the table Link to comment https://forums.phpfreaks.com/topic/76156-solved-date/#findComment-385426 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.