Jump to content

Better way to make cron jobs


Recommended Posts

Hi, i've created a module and i need that the client when install the module create too a cron job that run every day calling cron.php file that is localizated inside module folder. 

 

I don't know if i Let the responsability for the client do this under the server configuration or suggest they to user the cron module. 

 

The cron module is trustworthy? I probabily will have windows and linux clients.

 

Another question. I  need to make a call by php, right? Becouse the prestashop need autentication token on url call.

Ex. http:www/myprestashop/admin/modules/mymodule/cron.php 

 

or

 

php http:www/myprestashop/admin/modules/mymodule/cron.php

 

 

Thanks!

 

Link to comment
Share on other sites

With my AJAX Dropdown Categories module, I have modules/categoriesnc/cron.php which uses a secure key generated when the module is installed to prevent it being misused. I then print the full URL with the secure key on my module's configuration page and rely on the merchant to manually create their own cron job with the specified URL.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...