Dear readers of comp.lang.php,
I recently finished a script for a website, and altough
I'm happy with it, it's a bit too slow, due to the many
and somewhat complex queries to a MySQL database.
This has been partially solved writing the script so
that only the first person after midnight that requests
that page actually generates it. Everybody else will
get the stored html file out of that first request until
the next midnight.
A new opportunity has arisen though, because altough another
person would have to set it up, now it would be possible to
run a script through a cronjob.
Ideally, to avoid touching the first script, I'd write a
second, to be run through cronjob, that act like a browser
and triggers the page generation sometime after midnight.
I therefore tried something simple like this:
----
#!/usr/sbin/php
<?php
header("Location: http://www.euroharmony.com/~manu/hubstats2.php?which=ESSA&page4&force=1");
exit;
?>
----
But it doesn't actually do anything else other than print out
Location: http://www.euroharmony.com/~manu/hub...&page4&force=1
Content-type: text/html
What should I do instead? Am I using the wrong command?
Any hint? tip? trick?
Thank you!
Manu