GetDotted Domains

Viewing Thread:
"3rd party cron site use"

The "Freeola Customer Forum" forum, which includes Retro Game Reviews, has been archived and is now read-only. You cannot post here or create a new thread or review on this forum.

Sun 30/08/09 at 01:33
Regular
Posts: 595
Hi,

Without naming 3rd party sites, can you please tell me how to use a 'free cronjob' site to manipulate my webspace (such as backups).

The sites I have seen say enter full URL.

I have a cron helper script that needs to be run as a command line, so won't work as a URL.

I have another URL for a front-end backup which also appears not to work but is a parameterised full URL.

I'm stumped.

Neil
Tue 01/09/09 at 23:13
Regular
"Devil in disguise"
Posts: 3,151
I think you're wandering down a dead end here. From reading the documentation, it explicitly says it needs to run from the command line. So hacking away at it to make it run via a url is probably a waste of time.

Also cron is the standard *nix task scheduler. Its not part of apache, so installing that locally wont help you. You could use the windows task scheduler though. So you might be able to install php locally and run your script that way but I've no clue whether its capable of acting on remote installations of joomla (my guess is no).
Tue 01/09/09 at 21:19
Regular
Posts: 595
Didn't work. :(

I just thought...

If I run Apache (XAMPP) locally, can I set up cronjobs that way? If so, is it easyish to 'install' a crontab tool?

N.
Tue 01/09/09 at 16:36
Regular
"Embrace the Martian"
Posts: 285
Neilj99 wrote:
> I notice that the first thing in the croninclude.php file is:
>
> // Make sure we are being called from the command line
> if( array_key_exists('REQUEST_METHOD', $_SERVER) )
> die("Access Forbiddenn");
>
> :(

Ahh that may well be causing the issue, you will need to remove that if statement to hack it to work from a URL rather than path.
Tue 01/09/09 at 15:53
Regular
Posts: 595
I notice that the first thing in the croninclude.php file is:

// Make sure we are being called from the command line
if( array_key_exists('REQUEST_METHOD', $_SERVER) ) die("Access Forbiddenn");

:(
Tue 01/09/09 at 14:20
Regular
"Embrace the Martian"
Posts: 285
Okay thats fine, generally ignore most of what they are saying about command line, cron runs from command line but free online versions handle it slightly easier and do the hard work for you. Just put the cron files into a non-digest protected directory, make sure the 'croninclude.php' file is referenced correctly and then create a cron on the website of your choice like the following URL:

http://yoursite.com/cronfolder/cron1.php

Like I said previously you can check the script to see if the cron is working correctly by visiting the same URL in your browser.
Tue 01/09/09 at 13:59
Regular
Posts: 595
The backup is a job in Joomlapack. They say that you need to enter this:

"In order to use these scripts, create a CRON job on your server's control panel which calls a command similar to:

/path/to/php /cron1.php "

The cron1.php has:

$config = array(
'verbose' => '1',
'siteurl' => 'http://www..com/beta/vs/',
'profile' => '1',
'secret' => 'default',
'postop' => 'email',
'email' => 'webmaster@.com',
'ftphost' => 'vipxx.freeola.net',
'ftpport' => '21',
'ftpuser' => 'vipxxxx',
'ftppass' => '',
'ftpdir' => '/htdocs/beta/vs'
);
require_once('croninclude.php');

The Joomlapack people say this cannot be used as a full URL.

The other job is GuardXT (Joomla security) says to have a command:

/cron.guardxt.php.

The htdocs/beta directory and the 'site' administrator directory are both basic auth protected.
Tue 01/09/09 at 12:50
Regular
"Embrace the Martian"
Posts: 285
What you need to do is create a script in PHP that does what you need it to do. Save it in a folder called "cron" (or whatever else you want to call it) within "htdocs", test it in a web browser to see whether it actually does what you want it to do. If it does, just type the URL into the cron site and it should work fine.

URL Example: http://yourdomain.com/crons/forum-cleanup.php

Any reason you want to pass params to the script? A cron generally is built to do a task over and over again without needing any changing parameters.

Also what command line only features are you trying to use?
Sun 30/08/09 at 01:33
Regular
Posts: 595
Hi,

Without naming 3rd party sites, can you please tell me how to use a 'free cronjob' site to manipulate my webspace (such as backups).

The sites I have seen say enter full URL.

I have a cron helper script that needs to be run as a command line, so won't work as a URL.

I have another URL for a front-end backup which also appears not to work but is a parameterised full URL.

I'm stumped.

Neil

Freeola & GetDotted are rated 5 Stars

Check out some of our customer reviews below:

Very pleased
Very pleased with the help given by your staff. They explained technical details in an easy way and were patient when providing information to a non expert like me.
Wonderful...
... and so easy-to-use even for a technophobe like me. I had my website up in a couple of hours. Thank you.
Vivien

View More Reviews

Need some help? Give us a call on 01376 55 60 60

Go to Support Centre

It appears you are using an old browser, as such, some parts of the Freeola and Getdotted site will not work as intended. Using the latest version of your browser, or another browser such as Google Chrome, Mozilla Firefox, or Opera will provide a better, safer browsing experience for you.