The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#11
|
|||
|
|||
I copied your cron code from above and created a scheduled task for it. I created a award_user table and userfields 49 and 50 (all empty). I foudn that it runs OK, but of course since I have no data in my database (and only 1 test user), it's not trying to execute most of the code. But I did find that you can add echo statements and when you run the task manually they will be displayed, so you could do that - add echo statements to find out what's going on when it runs.
|
#12
|
||||
|
||||
Do I have to add this to a crondata set somewhere? IE:
PHP Code:
|
#13
|
|||
|
|||
I'm not 100% certain, but I don't think you need to do anything with the lastrun stuff unless your task needs to know exactly how long it's been since the last run. For example, the promotions scheduled task works on users that have been active since the last run, so i needs to know exactly when that was so it won't miss anyone. But based on what that script does you would need to save it yourself in that case (but it looks like you probably started with promotion.php when writing yours?)
|
#14
|
||||
|
||||
I did start with promotion.php and tried to mimic it. I don't really need to know when the last time the script ran is. Could it be this:
PHP Code:
PHP Code:
|
#15
|
|||
|
|||
$db is a reference to the same variable as $vbulletin->db, so, either one as long as they are in scope.
Are you not getting anything at all when it runs? What happens if you put Code:
echo "Start"; |
#16
|
||||
|
||||
I found the issue. I replaced all instances of:
PHP Code:
PHP Code:
Quote:
Quote:
|
#17
|
|||
|
|||
Well, that's strange. All the cron scripts use $vbulletin->db. Anyway, at least you're past that.
|
#18
|
||||
|
||||
I'll look at the promotions code and see if I can see what I did wrong. T.T
Figured it out. I had to serialize the log info. |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|