Search

I include the base tag, <base href="{$root}/"/>, in my master.xsl file so that my URLs will be portable between my development site and my public site. This worked well until I added an RSS feed. The links inside entries in the feed are incorrect. It makes them relative to the RSS page instead of the site root.

I found two threads in this forum that discuss this issue but they both conclude that the base tag can’t be used in an RSS feed. Does anyone know of another way to handle this?

The threads are here and here.

In entries I almost always use relative URLs beginning with a forward slash (so they are relative to the domain). In RSS feeds I use ninja XSLT to look for anchor href attributes beginning with a slash and I append the root string to them, making them absolute.

Thanks. I’ll give it a try.

Create an account or sign in to comment.

Symphony • Open Source XSLT CMS

Server Requirements

  • PHP 5.3-5.6 or 7.0-7.3
  • PHP's LibXML module, with the XSLT extension enabled (--with-xsl)
  • MySQL 5.5 or above
  • An Apache or Litespeed webserver
  • Apache's mod_rewrite module or equivalent

Compatible Hosts

Sign in

Login details