Jump to content

Cron won't run.


jeff5656

Recommended Posts

Not sure if this is the right category but it's the closest I could find.

 

I am trying to run a cron job and I get a permission denied when the cron job is run.

 

But in that script I have this at the top:

$dbhost = "localhost";
$dbname = "mydb_name";
$dbuser = "mehere";
$dbpass = "mypassword";
mysql_connect ( $dbhost, $dbuser, $dbpass) or die("Could not connect: ".mysql_error());
mysql_select_db($dbname) or die(mysql_error());

$curr_date=date("Y-m-d");
//delete table here
$query = "select this from that where thois = that"
$result=mysql_query($query) or die(mysql_error());

 

But when it says "permission denied" it looks like I am not even running the script?

 

To administrator: if this belongs in another forum that is seldom-used, could you keep this here for a short while until I get an answer and then move it? :-)

 

I am pointing to the correct directory int he cron job:

 

/home/myname/cronjobs/runthis.php

 

 

Link to comment
https://forums.phpfreaks.com/topic/265197-cron-wont-run/
Share on other sites

Archived

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

×
×
  • Create New...

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.