View Single Post
Old 05-18-2001, 12:24 AM  
TFCash
Confirmed User
 
Industry Role:
Join Date: Apr 2001
Posts: 1,738
Rip -

There are a lot of ways to do that, I prefer to use php to add new content each day by looking at which day it is. The absolute easiest way to do it, is to have all your content uploaded and a new picpage.html for each new addition. i.e. picpage1.html picpage2.html picpage3.html and so on. Then use crontab to copy the new page over at midnight each night. And presto it looks like you are updating each and every night. Nice thing is you can do all your page updates on one day, and the script does your updates for you each day. The crontab would look something like this:

0 0 * * 0 /home/yourname/mov_sunday.sh
0 0 * * 1 /home/yourname/mov_monday.sh
0 0 * * 2 /home/yourname/mov_tuesday.sh
0 0 * * 3 /home/yourname/mov_wednesday.sh
and so on

the mov_sunday.sh would look like this

/bin/cp -f /home/dir/somefolder/picpage2.html /home/dir/somefolder/picpage.html

and you would make one for each day of the week. That would give you 7 days of automatic updates with no intervention on your part Sorry it's so techy, I'm sure your server support team can add it for you if you have not done crontab stuff before.


Tim
TFCash is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote