The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Some help needed with rss-feed and scheduled task
Hey,
I'm hoping someone could help me obtain a little bit less noobishness in the more NOT out of the box stuff for vB. First of all, I'm trying to create a new RSS feed post. The URL for the rss ishere: http://afterworld.ru/rss.xml That works fine in the browser and an XML validator also couldn't find anything wrong with it, but apparently vB decided there's a mismatched tag on line 5. I googled, but did not really find anything helpful, so I figured I'd give it a shot here. Then I also have a problem with a scheduled task I tried setting up. I followed instructions I found somewhere, and created my php file in notepad, added a simple SQL UPDATE query as the only task to perform, and dumped it in the /includes/cron folder. The code for the page is really simple: Code:
<?php /*======================================================================*\ || #################################################################### || || # Update signature posts for users who added their signatures later || || #################################################################### || \*======================================================================*/ // --------------------------------------------------- // Start Set PHP Environment // --------------------------------------------------- error_reporting(E_ALL & ~E_NOTICE); if (!is_object($vbulletin->db)) { exit; } // --------------------------------------------------- // Start Cronjob // --------------------------------------------------- global $vbulletin; $vbulletin->db->query("UPDATE post SET showsignature = 1"); // --------------------------------------------------- // Log action // --------------------------------------------------- log_cron_action('Signature posts have been updated', $nextitem); // --------------------------------------------------- // End Cronjob // --------------------------------------------------- ?> Thanks in advance for any pointers. Regards, Peter |
#2
|
||||
|
||||
I get redirected to your site with this url - http://afterworld.ru/rss.xml
I don't think you need to globalize $vbulletin there, I know I don't on the couple of cron jobs I've written. Do you have a table prefix? You should probably write the query as? PHP Code:
|
#3
|
|||
|
|||
Quote:
You get redirected? That's strange. For me, it links to the RSS file I want to pull news from. I've been trying to play around with it for a bit, but keep getting the darn error. Would I be better off asking over at the official vB.com site, you think? Update: I just played with some other RSS feeds I want to grab, and all of those seem to work. There must be something wrong with this particular one, but for the life of me, I cannot seem to pinpoint it. It works in a browser, and when I add it to IE rss. Just vB doesn't seem to eat it. As for the scheduled task, I found what was wrong. The filename field apparently has a 50 character limit, which cut off the last two characters of the path to the cron job. I renamed my file to something a bit shorter, and now that works, at least In the words of Homer: "D'OH". Thanks for your time Peter |
#4
|
||||
|
||||
I just tried the link again and I didn't get redirected. I definitely did the first time though. You may want to compare your output (page source) from the RSS feed to the output from the vbulletin feed (page source) and see the differences. Maybe modify yours to be more along the line of theirs.
|
#5
|
|||
|
|||
Quote:
What do you mean by comparing the output? The link provided is the RSS feed I wish to consume. I right-clicked the page, grabbed the source, and ran that through an XML parser to ensure the syntax is working. I cannot even seem to be able to generate the RSS feed to my site, as I see the parsing error as soon as I try and test the feed. Thanks. Peter |
#6
|
||||
|
||||
I am talking about comparing the output - the page source. I can see that in a browser. Compare your page source to the page source of one that works fine in your rss manager. See what sort of differences there are and see if you modify it in yours, if that helps.
i'm not some rss expert, so I can't really give any specifics, all I can do is tell you how I would approach the problem. |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|