jmdelgado Posted January 19, 2012 Share Posted January 19, 2012 Hello, I have to launch automated tasks from an external application executing URL's that running php scripts against the prestashop backoffice like prestashop "searchcron.php" wich is offered to perform the rebuild indexing function. I want to know if anyone has managed to launch externally scripts with some of the tasks below or it has created some specific script for it to be executed in the cron and could tell me: 1 .- Prestashop indexing products (PS back office: Preferences> Search). -- Only achieve this one! 2 .- The Prestashop update your sitemap (PS back office: Modules> Referencing SEO). 3 .- The generation of the XML feed file Prestashop of products (PS back office: Modules> Advertising and marketing). 4 .- Prestashop thumbnail regeneration (PS back office: Preferences> Images> Regenerate thumbnails). Thanks, Jm Link to comment Share on other sites More sharing options...
jmdelgado Posted January 19, 2012 Author Share Posted January 19, 2012 I'm trying to use the function _regeneratethmbnails in a PHP script that I created and I get the following output and errors whe I put execute the call to the URL http://www.XXXXX.com/XXXXX/thumbnailscron.php?type=all&erase=1&token=XXXXXXXX. Warning: key_exists() expects parameter 2 to be array, null given in /usr/home/XXXXXX.com/web/classes/AdminTab.php on line 224 ......................................................................................... ......................................................................................... Warning: key_exists() expects parameter 2 to be array, null given in /usr/home/XXXXXX.com/web/classes/AdminTab.php on line 224 get to the function: all Fatal error: Call to undefined function imageResize() in /usr/home/XXXXXXX.com/web/XXXXX/tabs/AdminImages.php on line 317 Here is the code of thumbnailscron.php: ***************************************************** <? php include (dirname (__FILE__ ).'/../ config / config.inc.php '); include (dirname (__FILE__). '/ tabs / AdminImages.php'); if (substr (_COOKIE_KEY_, 34, 8)! = Tools:: getValue ('token')) die; ini_set ('max_execution_time', 7200); $ obj = new AdminImage (); if ($ obj-> regenerarminiaturas (Tools:: getValue ('type'), Tools:: getValue ('erase'))) echo "Update successful"; else echo "Update failed"; ***************************************************** I've created the function regenerarminiaturas located in AdminImages.php and I use it to call _regenerateThumbnails because this is a private function. regenerarminiaturas public function ($ type, $ erase) { echo "get to the function: $ type"; $ this-> _regenerateThumbnails ($ type, $ erase); echo "Exit the"; return true; } Can anybody help me? Thanks, Link to comment Share on other sites More sharing options...
jmdelgado Posted January 24, 2012 Author Share Posted January 24, 2012 Does anyone know anything about it? Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now