J98680Bxxxxx
07-19-2008, 06:14 PM
Hi All,
I am having some trouble with a cron job not receiving vbulletin global variables. The cron job runs fine if activated manually from the ACP, but it fails to work as a standalone scheduled task.
The file content looks like this
<?php
error_reporting(E_ALL & ~E_NOTICE);
if (!is_object($vbulletin->db)) {exit;}
if ($vbulletin->options['mysettingname'] == 1){
... do something...
}
...
?>
Any call to "$vbulletin->options['mysettingname']" or to "vbphrase['myphrasename']" fails to work and even the function "construct_phrase(...)" fails to work and I ressorted to get the values directly from the "setting" and "phrase" tables in the database.
Is there any type of memory limitation in vbulletin for a hack/mod amount of settings/phrases used that might prevent global variables to be passed?
Any hint or insight is appreciated. :)
I read the recommendations by Lynne (https://vborg.vbsupport.ru/showpost.php?p=1438621&postcount=10) and Marco (https://vborg.vbsupport.ru/showpost.php?p=1438695&postcount=11), but to no avail.
I am having some trouble with a cron job not receiving vbulletin global variables. The cron job runs fine if activated manually from the ACP, but it fails to work as a standalone scheduled task.
The file content looks like this
<?php
error_reporting(E_ALL & ~E_NOTICE);
if (!is_object($vbulletin->db)) {exit;}
if ($vbulletin->options['mysettingname'] == 1){
... do something...
}
...
?>
Any call to "$vbulletin->options['mysettingname']" or to "vbphrase['myphrasename']" fails to work and even the function "construct_phrase(...)" fails to work and I ressorted to get the values directly from the "setting" and "phrase" tables in the database.
Is there any type of memory limitation in vbulletin for a hack/mod amount of settings/phrases used that might prevent global variables to be passed?
Any hint or insight is appreciated. :)
I read the recommendations by Lynne (https://vborg.vbsupport.ru/showpost.php?p=1438621&postcount=10) and Marco (https://vborg.vbsupport.ru/showpost.php?p=1438695&postcount=11), but to no avail.