Jump to content

Archived

This topic is now archived and is closed to further replies.

Ge64

Running scripts automatically

Recommended Posts

For my website I need to update a few numbers in the mysql database exactly every hour, so I will need to run a php script then. Is there a way to make a PHP script do something at a particular moment?

Share this post


Link to post
Share on other sites
if your web server uses cron jobs, you can run a script every hour with that. Do a search on cron jobs here and you should find it no problem.

Ray

Share this post


Link to post
Share on other sites
[!--quoteo(post=349884:date=Feb 27 2006, 05:56 PM:name=craygo)--][div class=\'quotetop\']QUOTE(craygo @ Feb 27 2006, 05:56 PM) [snapback]349884[/snapback][/div][div class=\'quotemain\'][!--quotec--]
if your web server uses cron jobs, you can run a script every hour with that. Do a search on cron jobs here and you should find it no problem.

Ray
[/quote]

No it doesnt, but is there software to run php scripts at certain times so I can put it on one of my 24/7 pc's and run it remotely?

Share this post


Link to post
Share on other sites
you could use windows task scheduler to run your browser at the appointed times. and have the browser point to a php script that does what you want done.

clear as mud?

Lite...

Share this post


Link to post
Share on other sites
let me know if your still looking for one, i could whip up a visual basic program for you to run it

Share this post


Link to post
Share on other sites
[!--quoteo(post=349910:date=Feb 27 2006, 07:23 PM:name=joecooper)--][div class=\'quotetop\']QUOTE(joecooper @ Feb 27 2006, 07:23 PM) [snapback]349910[/snapback][/div][div class=\'quotemain\'][!--quotec--]
let me know if your still looking for one, i could whip up a visual basic program for you to run it
[/quote]

Do you have code to run sql queries on remote mysql servers? Because that would be even better but probably a lot of work. What I need is a few scripts that need to run at all sorts of times, like every day or every hour, or totally random. You would only need to use an Inet control because I have the files on a HTTP server with PHP so you only have to run them then, don't think thats really hard to do right? I would actually do it myself but I lost my VS cd :(

Let me know if you feel like doing that...

Share this post


Link to post
Share on other sites
tell me the files you want to run, and at what times, and ill add it to the cron jobs on my server

Share this post


Link to post
Share on other sites
[!--quoteo(post=349917:date=Feb 27 2006, 07:36 PM:name=joecooper)--][div class=\'quotetop\']QUOTE(joecooper @ Feb 27 2006, 07:36 PM) [snapback]349917[/snapback][/div][div class=\'quotemain\'][!--quotec--]
tell me the files you want to run, and at what times, and ill add it to the cron jobs on my server
[/quote]

The site isnt finished yet so I don't know... Is there a cron jobs module for apache2?

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.