We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 21635
    • 81 Posts
    Quote from: OpenGeek at Aug 19, 2010, 03:40 PM

    So if you reload the edit page on the Resource, does it still show your RSS content type or HTML?

    well, i just tried to find some logic behind the bug, but i clearly can’t see it. i have 4 feed-documents in the tree .
    i just opened up the manager and of 3 displayed as RSS, 1 as HTML.
    i changed the HTML to RSS, saved, and it stayed RSS.

    Then i clicked around the other documents and suddenly one resource that was displayed RSS a minute before now displayed as HTML. I continued loading the documents and there is definetely some ranomness at work. Sometimes they get displayed as RSS, sometimes as HTML. huh
    As the links in the frontend still work as expected, i guess it’s a display-bug.
      • 36830
      • 140 Posts
      can't seem to include a template variable for the image. perhaps the syntax is being stripped? where do i start?
        • 22303 MODX Staff
        • 10,725 Posts
        Quote from: pjldesign at Sep 13, 2011, 02:14 PM
        can't seem to include a template variable for the image. perhaps the syntax is being stripped? where do i start?
        Start by providing your getResource call so we know where to start. wink
          • 36830
          • 140 Posts
          sure. here's template:

          <rss version="2.0">
          <channel>
          <title>[[*pagetitle]]</title>
          <link>[[++site_url]]</link>
          <image>
            <url>[[++site_url]][[*article-image]]</url>
            <title>img</title>
            <link>[[++site_url]]</link>
          </image>
          <description>[[*content]]</description>
          <lastBuildDate>[[!getTime?format=`%a, %d %b %Y %H:%M:%S %z`]]</lastBuildDate>
          <language>en-gb</language>
          [[!getResources? 
             &parents=`3`
             &limit=`0`
             &sortby=`createdon`
             &sortdir=`DESC`
             &tvPrefix=``
             &includeTVs=`1`
             &processTVs=`1`
             &includeContent=`1`
             &tpl=`rssListing`]]
          </channel>
          </rss>
          


          and tpl:

          <item>
          <image>
          <url>[[++site_url]][[+article-image]]</url>
          <title>img</title>
          <link>[[++site_url]]</link>
          </image>
          <title>[[+pagetitle:toCDATA]]</title>
          <link>[[!++site_url]][[~[[+id]]]]</link>
          <guid>[[~[[+id]]]]</guid>
          <pubDate>[[+createdon:strtotime:date=`%a, %d %b %Y %H:%M:%S %z`]]</pubDate>
          <description>[[+content:toCDATA]]</description>
          </item>
          


          thanks for any insights

          P