williamZanelli Posted May 3, 2009 Share Posted May 3, 2009 Hey guys, I'm trying to create a RSS file using PHP. I have URL links, for some reason, the "=" sign seems to be messing up the whole thing, See sample below, I get the error, which says it expects a ";" after the "=" - Does anyone know a way round this? <item> <title> <![CDATA[Lee rejects arrogance claims]]></title> <link>http://www.rivals.net/news/pgarticle.aspx?artid=13482_5216124&id=46</link> <comments></comments> <pubDate>Tue, 21 Apr 2009 16:15:26 BST</pubDate> <description><![CDATA[sammy Lee has rejected suggestions that Rafael Benitez made any gesture which could be considered as dismissive while on the touchline and said the Liverpool boss is far from arrogant.]]></description> </item> It's become soo irratating, that now I'd happily settle for a simple XML file, rather than a RSS - If anyone can point me in the right direction of a tutorial that will show me how to create an XML file, with items, such as above, please do so. Thanks for your thoughts. Will Quote Link to comment https://forums.phpfreaks.com/topic/156700-solved-creating-rssxml-in-php/ Share on other sites More sharing options...
Axeia Posted May 3, 2009 Share Posted May 3, 2009 isn't that your & sign messing up things with the second = ? Try using & Or better yet, use url encode . Quote Link to comment https://forums.phpfreaks.com/topic/156700-solved-creating-rssxml-in-php/#findComment-825157 Share on other sites More sharing options...
williamZanelli Posted May 4, 2009 Author Share Posted May 4, 2009 Thanks for the reply. urlncode doesnt work in this instance, as I wnat to print the link in my doc, So I used str_replace("&","&",$url); This works like a charm!! Thanks for your posts. Quote Link to comment https://forums.phpfreaks.com/topic/156700-solved-creating-rssxml-in-php/#findComment-826223 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.