ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

RSS XML Parsing Error

January 19, 2010 4:42pm

Subscribe [1]
  • #1 / Jan 19, 2010 4:42pm

    Roku

    5 posts

    Hey Guys,

        I have been working on this issue for a few hours now and I cant seem to understand why this is breaking. I have a few segments of code that are being used to create an RSS feed for events but when I run that code I receive the error:

    <b>Parse error</b>:  syntax error, unexpected T_STRING in <b>/mnt/stor1-wc1-dfw1/387642/www.eravious.com/web/content/system/core/core.functions.php(637) : eval()'d code</b> on line <b>2</b>
    

    Here is the code that I am using:

    {assign_variable:master_weblog_name="events"}
    {exp:rss:feed weblog="{master_weblog_name}"}
    
    <?xml version="1.0" encoding="{encoding}"?>
    <rss version="2.0"
        xmlns:dc="http://purl.org/dc/elements/1.1/"
        xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
        xmlns:admin="http://webns.net/mvcb/"
        xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
        xmlns:content="http://purl.org/rss/1.0/modules/content/">
    
        <channel>
        <title>{exp:xml_encode}{weblog_name}{/exp:xml_encode}</title>
        <link>{weblog_url}</link>
        <description>{weblog_description}</description>
        <dc:language>{weblog_language}</dc:language>
        <dc:creator>{email}</dc:creator>
        <dc:rights>Copyright {gmt_date format="%Y"}</dc:rights>
        <dc:date>{gmt_date format="%Y-%m-%dT%H:%i:%s%Q"}</dc:date>
        <admin:generatorAgent rdf:resource="http://expressionengine.com/" >
        {exp:weblog:entries weblog="{master_weblog_name}" rdf="off" dynamic_start="on"  limit="12" orderby="date" sort="asc" show_future_entries="yes" status="open" disable="categories|category_fields|member_data|trackbacks"  }
        <item>
          <title>{exp:xml_encode}{title}{/exp:xml_encode}</title>
          <link>{page_url}</link>
          <guid>{exp:xml_encode}{page_url}{/exp:xml_encode}</guid>
          <description>
            <![CDATA[<strong>Date:</strong> {date-time}
    {event_description}
    {if event_link != ""}<a href="http://{event_link}title={title}">{event_link}</a>{/if}]]></description>
          <dc:date>{gmt_entry_date format="%Y-%m-%dT%H:%i:%s%Q"}</dc:date>
        </item>
    {/exp:weblog:entries}
        
        </channel>
    </rss>
    {/exp:rss:feed}

    When I change the variable master_weblog_name to another category name, it generates the XML just fine, but when I change it back to events, I receive the previous error.

    Can someone please help me understand whats going on with this? That would be really appreciated! Thank you!

  • #2 / Jan 19, 2010 9:12pm

    Roku

    5 posts

    Any suggestions anyone?

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases