Welcome to WebmasterWorld Guest from

Forum Moderators: bill & werty

Message Too Old, No Replies

RSS Feed error.Pls Help



10:40 pm on Sep 28, 2005 (gmt 0)

10+ Year Member


I have tried creating a rss.php file for my sit e. I just used the exact model which I found at one site. Ofcourse I used this model also. I got the following error on both cases. Please help me figure our what is wrong. I have been trying for 2 days now. Do I need to ask my web hosting company to add any MIME type?.

Error I got is
Parse error: parse error, unexpected T_STRING in example.com/rss.php on line 1

<?xml version="1.0" encoding="ISO-8859-1"?>
<rss version="2.0">


<title>All Widgets Reviewed</title>
<description>If it's a widget, we review it. Learn what widgets are hot and what's not!</description>

<title>Nokia 3650 Combines Phone And Photos</title>
<description>I've been playing with the new Widget 3650. Finally, someone has got the combination of a cell phone with digital camera capabilities right!</description>


Thanks in advance

[edited by: werty at 4:21 am (utc) on Sep. 29, 2005]
[edit reason] Removed URLS - Please see TOS #13 [/edit]


3:56 pm on Sep 29, 2005 (gmt 0)

WebmasterWorld Senior Member encyclo is a WebmasterWorld Top Contributor of All Time 10+ Year Member

Your problem is probably the XML prolog - it uses a similar syntax to PHP so it can cause a parsing error. You can echo the XML prolog with PHP instead which sould solve the problem:

<?php echo '<?xml version="1.0" encoding="ISO-8859-1"?>'; ?>

from memory - I hope I haven't made an error!


Featured Threads

Hot Threads This Week

Hot Threads This Month