Rss Feed Absolute Paths

I am wokring on Rss feeds across several sites and have run into an issue with relative URL’s. I need the Rss page template to use absolute url’s for a mobile aplpication we are implmenting. I have combed the forum and found some suggestions (although some what outdated) and have had no luck.

I currently have a variable setup $pagelink in the page template/ with binding:

<link href="${pagelink}" rel="self" type="application/atom+xml" />
$rx.location.generate($sys.assemblyItem, "erauPgRssFeed")

All works perfectly with the exception of the relative paths.

Any help would be greatly appreciated.
Thanks,
MJW

We have done the following in the template that generates the RSS 2 feed. Note that we have a link to the HTML version of the page as well as the RSS 2, (depending on what you want, you may only need one)


#set($pageSiteID = $rx.asmhelper.getSingleParamValue($sys.params,'sys_siteid'))##
#if($pageSiteID)##
#set($pageSiteBase = $rx.location.siteBase($pageSiteID,"no"))##
#else##
#set($pageSiteBase = '')##
#end##
#set($fullHTMLPageURL= $rx.location.generate($sys.assemblyItem, "myHTMLPage"))##
##prepend site url if it does not exist
#if($fullHTMLPageURL.indexOf("http")!=0)##
#set($fullHTMLPageURL= "${pageSiteBase}${fullHTMLPageURL}")
#end##
#set($fullRSSPageURL= $rx.location.generate($sys.assemblyItem, "myRSS2Page"))##
##prepend site url for RSS page if it does not exist
#if($fullRSSPageURL.indexOf("http")!=0)##
#set($fullRSSPageURL= "${pageSiteBase}${fullRSSPageURL}")
#end##
##
 <atom:link href="${fullRSSPageURL}" rel="self" type="application/rss+xml" />


Thank you for the quick response, let me take a look.

I REALLY appreciate it!
MJW

No problem. Just to clarify, you most likely want all the links in the rss page to point to the html version (ie for the items). The reason we had the RSS link (back to itself) was for the atom self reference (w3c recommends it).