}
}
- $xsl = $registry->get('themesuri') . '/feed-rss.xsl';
+ $xsl = Horde_Themes::getFeedXsl();
$stream_name = htmlspecialchars($params['name']);
$stream_desc = htmlspecialchars($params['desc']);
$stream_updated = htmlspecialchars(date('r', $params['last_modified']));
+++ /dev/null
-<?xml version="1.0"?>
-
-<xsl:stylesheet version="1.0"
- xmlns="http://www.w3.org/1999/xhtml"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:rss="http://purl.org/rss/1.0/"
- xmlns:atom="http://www.w3.org/2005/Atom">
-
- <xsl:output indent="yes" encoding="UTF-8"/>
-
- <xsl:template match="/rss|/atom:feed">
- <html>
- <head>
- <title>
- <xsl:value-of select="/rss/channel/title"/>
- </title>
- <style type="text/css">
- img {
- border: 0;
- padding: 5px;
- }
- </style>
- </head>
- <body>
- <p>
- You're viewing an XML content feed which is
- intended to be viewed within a feed aggregator.
- </p>
-
- <xsl:variable name="link" select="/rss/channel/link"/>
- <h3>Subscribe to <a href="{$link}"><xsl:value-of select="/rss/channel/title"/></a></h3>
- <xsl:variable name="cimage" select="/rss/channel/image/url"/>
- <div style="float:right;"><img src="{$cimage}"/></div>
-
- <p>
- Subscribe now in your favorite RSS aggregator:
- </p>
-
- <xsl:variable name="resource" select="/rss/channel/atom:link"/>
-
- <div>
- <a href="http://www.rojo.com/add-subscription?resource={$resource}">
- <img src="http://www.rojo.com/skins/static/images/add-to-rojo.gif" alt="Subscribe in Rojo"/>
- </a>
-
- <a href="http://add.my.yahoo.com/rss?url={$resource}">
- <img src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif" alt="Add to My yahoo" />
- </a>
-
- <a href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url={$resource}">
- <img src="http://www.newsgator.com/images/ngsub1.gif" alt="Subscribe in NewsGator Online"/>
- </a>
-
- <a href="http://www.bloglines.com/sub/{$resource}">
- <img src="http://www.bloglines.com/images/sub_modern5.gif" alt="Subscribe with Bloglines"/>
- </a>
-
- <a href="http://fusion.google.com/add?feedurl={$resource}">
- <img src="http://buttons.googlesyndication.com/fusion/add.gif" alt="Subscribe with Google Reader"/>
- </a>
- </div>
-
- <p>
- <h3>Preview</h3>
- </p>
-
- <xsl:apply-templates select="/rss/channel/item" />
-
- </body>
- </html>
- </xsl:template>
-
- <xsl:template match="item">
- <xsl:variable name="link" select="link"/>
- <p>
- <a href="{$link}">
- <xsl:value-of select="title"/>
- </a>
- <br />
- <xsl:value-of select="description"/>
- </p>
- </xsl:template>
-
-</xsl:stylesheet>
return $sounds;
}
+ /**
+ * Return the location of the feed XSL file.
+ *
+ * As of now, this file MUST live in horde/themes/default/feed-rss.xsl.
+ *
+ * @return string Path to the feed file.
+ */
+ static public function getFeedXsl()
+ {
+ return $GLOBALS['registry']->get('themesuri', 'horde') . '/default/feed-rss.xsl';
+ }
+
}
--- /dev/null
+<?xml version="1.0"?>
+
+<xsl:stylesheet version="1.0"
+ xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
+ xmlns:rss="http://purl.org/rss/1.0/"
+ xmlns:atom="http://www.w3.org/2005/Atom">
+
+ <xsl:output indent="yes" encoding="UTF-8"/>
+
+ <xsl:template match="/rss|/atom:feed">
+ <html>
+ <head>
+ <title>
+ <xsl:value-of select="/rss/channel/title"/>
+ </title>
+ <style type="text/css">
+ img {
+ border: 0;
+ padding: 5px;
+ }
+ </style>
+ </head>
+ <body>
+ <p>
+ You're viewing an XML content feed which is
+ intended to be viewed within a feed aggregator.
+ </p>
+
+ <xsl:variable name="link" select="/rss/channel/link"/>
+ <h3>Subscribe to <a href="{$link}"><xsl:value-of select="/rss/channel/title"/></a></h3>
+ <xsl:variable name="cimage" select="/rss/channel/image/url"/>
+ <div style="float:right;"><img src="{$cimage}"/></div>
+
+ <p>
+ Subscribe now in your favorite RSS aggregator:
+ </p>
+
+ <xsl:variable name="resource" select="/rss/channel/atom:link"/>
+
+ <div>
+ <a href="http://www.rojo.com/add-subscription?resource={$resource}">
+ <img src="http://www.rojo.com/skins/static/images/add-to-rojo.gif" alt="Subscribe in Rojo"/>
+ </a>
+
+ <a href="http://add.my.yahoo.com/rss?url={$resource}">
+ <img src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif" alt="Add to My yahoo" />
+ </a>
+
+ <a href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url={$resource}">
+ <img src="http://www.newsgator.com/images/ngsub1.gif" alt="Subscribe in NewsGator Online"/>
+ </a>
+
+ <a href="http://www.bloglines.com/sub/{$resource}">
+ <img src="http://www.bloglines.com/images/sub_modern5.gif" alt="Subscribe with Bloglines"/>
+ </a>
+
+ <a href="http://fusion.google.com/add?feedurl={$resource}">
+ <img src="http://buttons.googlesyndication.com/fusion/add.gif" alt="Subscribe with Google Reader"/>
+ </a>
+ </div>
+
+ <p>
+ <h3>Preview</h3>
+ </p>
+
+ <xsl:apply-templates select="/rss/channel/item" />
+
+ </body>
+ </html>
+ </xsl:template>
+
+ <xsl:template match="item">
+ <xsl:variable name="link" select="link"/>
+ <p>
+ <a href="{$link}">
+ <xsl:value-of select="title"/>
+ </a>
+ <br />
+ <xsl:value-of select="description"/>
+ </p>
+ </xsl:template>
+
+</xsl:stylesheet>
$t = $injector->createInstance('Horde_Template');
$t->set('charset', 'UTF-8');
-$t->set('xsl', $registry->get('themesuri') . '/feed-rss.xsl');
+$t->set('xsl', Horde_Themes::getFeedXsl());
$t->set('pubDate', htmlspecialchars(date('r')));
$t->set('desc', htmlspecialchars($description));
$t->set('title', htmlspecialchars($registry->get('name') . ' - ' . IMP::getLabel($mailbox)));
+++ /dev/null
-<?xml version="1.0"?>
-
-<xsl:stylesheet version="1.0"
- xmlns="http://www.w3.org/1999/xhtml"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:rss="http://purl.org/rss/1.0/"
- xmlns:atom="http://www.w3.org/2005/Atom">
-
- <xsl:output indent="yes" encoding="UTF-8"/>
-
- <xsl:template match="/rss|/atom:feed">
- <html>
- <head>
- <title>
- <xsl:value-of select="/rss/channel/title"/>
- </title>
- <style type="text/css">
- img {
- border: 0;
- padding: 5px;
- }
- </style>
- </head>
- <body>
- <p>
- You're viewing an XML content feed which is
- intended to be viewed within a feed aggregator.
- </p>
-
- <h3>Subscribe to <xsl:value-of select="/rss/channel/title"/></h3>
-
- <p>
- Subscribe now in your favorite RSS aggregator:
- </p>
-
- <xsl:variable name="resource" select="/rss/channel/atom:link"/>
-
- <div>
- <a href="http://www.rojo.com/add-subscription?resource={$resource}">
- <img src="http://www.rojo.com/skins/static/images/add-to-rojo.gif" alt="Subscribe in Rojo"/>
- </a>
-
- <a href="http://add.my.yahoo.com/rss?url={$resource}">
- <img src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif" alt="Add to My yahoo" />
- </a>
-
- <a href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url={$resource}">
- <img src="http://www.newsgator.com/images/ngsub1.gif" alt="Subscribe in NewsGator Online"/>
- </a>
-
- <a href="http://www.bloglines.com/sub/{$resource}">
- <img src="http://www.bloglines.com/images/sub_modern5.gif" alt="Subscribe with Bloglines"/>
- </a>
-
- <a href="http://fusion.google.com/add?feedurl={$resource}">
- <img src="http://buttons.googlesyndication.com/fusion/add.gif" alt="Subscribe with Google Reader"/>
- </a>
- </div>
-
- <p>
- <h3>Preview</h3>
- </p>
-
- <xsl:apply-templates select="/rss/channel/item" />
-
- </body>
- </html>
- </xsl:template>
-
- <xsl:template match="item">
- <xsl:variable name="link" select="link"/>
- <p>
- <a href="{$link}">
- <xsl:value-of select="title"/>
- </a>
- </p>
- </xsl:template>
-
-</xsl:stylesheet>
// Build the template (@TODO: Use Horde_View)
$template = new Horde_Template();
$template->set('jonah', 'Jonah ' . $registry->getVersion() . ' (http://www.horde.org/jonah/)');
-$template->set('xsl', $registry->get('themesuri') . '/feed-rss.xsl');
+$template->set('xsl', Horde_Themes::getFeedXsl());
if (!empty($criteria['tag_id'])) {
$template->set('channel_name', sprintf(_("Stories tagged with %s in %s"), $tag_name, htmlspecialchars($channel['channel_name'])));
} else {
+++ /dev/null
-<?xml version="1.0"?>
-
-<xsl:stylesheet version="1.0"
- xmlns="http://www.w3.org/1999/xhtml"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:rss="http://purl.org/rss/1.0/"
- xmlns:atom="http://www.w3.org/2005/Atom">
-
- <xsl:output indent="yes" encoding="UTF-8"/>
-
- <xsl:template match="/rss|/atom:feed">
- <html>
- <head>
- <title>
- <xsl:value-of select="/rss/channel/title"/>
- </title>
- <style type="text/css">
- img {
- border: 0;
- padding: 5px;
- }
- </style>
- </head>
- <body>
- <p>
- You're viewing an XML content feed which is
- intended to be viewed within a feed aggregator.
- </p>
-
- <xsl:variable name="link" select="/rss/channel/link"/>
- <h3>Subscribe to <a href="{$link}"><xsl:value-of select="/rss/channel/title"/></a></h3>
- <xsl:variable name="cimage" select="/rss/channel/image/url"/>
- <div style="float:right;"><img src="{$cimage}"/></div>
- <p>
- Subscribe now in your favorite RSS aggregator:
- </p>
-
- <xsl:variable name="resource" select="/rss/channel/atom:link"/>
-
- <div>
- <a href="http://add.my.yahoo.com/rss?url={$resource}">
- <img src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif" alt="Add to My yahoo" />
- </a>
-
- <a href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url={$resource}">
- <img src="http://www.newsgator.com/images/ngsub1.gif" alt="Subscribe in NewsGator Online"/>
- </a>
-
- <a href="http://www.bloglines.com/sub/{$resource}">
- <img src="http://www.bloglines.com/images/sub_modern5.gif" alt="Subscribe with Bloglines"/>
- </a>
-
- <a href="http://fusion.google.com/add?feedurl={$resource}">
- <img src="http://buttons.googlesyndication.com/fusion/add.gif" alt="Subscribe with Google Reader"/>
- </a>
- </div>
-
- <p>
- <h3>Preview</h3>
- </p>
-
- <xsl:apply-templates select="/rss/channel/item" />
-
- </body>
- </html>
- </xsl:template>
-
- <xsl:template match="item">
- <xsl:variable name="link" select="link"/>
- <p>
- <a href="{$link}">
- <xsl:value-of select="title"/>
- </a>
- <br />
- <xsl:value-of select="description"/>
- </p>
- </xsl:template>
-
-</xsl:stylesheet>
$template->set('kronolith_version', $registry->getVersion());
$template->set('kronolith_uri', 'http://www.horde.org/kronolith/');
$template->set('kronolith_icon', Horde::url(Horde_Themes::img('kronolith.png'), true, -1));
-$template->set('xsl', $registry->get('themesuri') . '/feed-rss.xsl');
+$template->set('xsl', Horde_Themes::getFeedXsl());
$template->set('calendar_name', htmlspecialchars($share->get('name')));
$template->set('calendar_desc', htmlspecialchars($share->get('desc')), true);
$template->set('calendar_owner', htmlspecialchars($identity->getValue('fullname')));
+++ /dev/null
-<?xml version="1.0"?>
-
-<xsl:stylesheet version="1.0"
- xmlns="http://www.w3.org/1999/xhtml"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:rss="http://purl.org/rss/1.0/"
- xmlns:atom="http://www.w3.org/2005/Atom">
-
- <xsl:output indent="yes" encoding="UTF-8"/>
-
- <xsl:template match="/rss|/atom:feed">
- <html>
- <head>
- <title>
- <xsl:value-of select="/rss/channel/title"/>
- </title>
- <style type="text/css">
- img {
- border: 0;
- padding: 5px;
- }
- </style>
- </head>
- <body>
- <p>
- You're viewing an XML content feed which is
- intended to be viewed within a feed aggregator.
- </p>
-
- <xsl:variable name="link" select="/rss/channel/link"/>
- <h3>Subscribe to <a href="{$link}"><xsl:value-of select="/rss/channel/title"/></a></h3>
- <xsl:variable name="cimage" select="/rss/channel/image/url"/>
- <div style="float:right;"><img src="{$cimage}"/></div>
- <p>
- Subscribe now in your favorite RSS aggregator:
- </p>
-
- <xsl:variable name="resource" select="/rss/channel/atom:link"/>
-
- <div>
- <a href="http://www.rojo.com/add-subscription?resource={$resource}">
- <img src="http://www.rojo.com/skins/static/images/add-to-rojo.gif" alt="Subscribe in Rojo"/>
- </a>
-
- <a href="http://add.my.yahoo.com/rss?url={$resource}">
- <img src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif" alt="Add to My yahoo" />
- </a>
-
- <a href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url={$resource}">
- <img src="http://www.newsgator.com/images/ngsub1.gif" alt="Subscribe in NewsGator Online"/>
- </a>
-
- <a href="http://www.bloglines.com/sub/{$resource}">
- <img src="http://www.bloglines.com/images/sub_modern5.gif" alt="Subscribe with Bloglines"/>
- </a>
-
- <a href="http://fusion.google.com/add?feedurl={$resource}">
- <img src="http://buttons.googlesyndication.com/fusion/add.gif" alt="Subscribe with Google Reader"/>
- </a>
- </div>
-
- <p>
- <h3>Preview</h3>
- </p>
-
- <xsl:apply-templates select="/rss/channel/item" />
-
- </body>
- </html>
- </xsl:template>
-
- <xsl:template match="item">
- <xsl:variable name="link" select="link"/>
- <p>
- <a href="{$link}">
- <xsl:value-of select="title"/>
- </a>
- <br />
- <xsl:value-of select="description"/>
- </p>
- </xsl:template>
-
-</xsl:stylesheet>
}
$template = $injector->createInstance('Horde_Template');
-$template->set('xsl', $registry->get('themesuri') . '/feed-rss.xsl');
+$template->set('xsl', Horde_Themes::getFeedXsl());
$template->set('pubDate', htmlspecialchars(date('r')));
$template->set('title', htmlspecialchars($whups_query->name ? $whups_query->name : _("Query Results")));
$template->set('items', $items, true);
}
$template = $injector->createInstance('Horde_Template');
-$template->set('xsl', $registry->get('themesuri') . '/feed-rss.xsl');
+$template->set('xsl', Horde_Themes::getFeedXsl());
$template->set('pubDate', htmlspecialchars(date('r')));
if (isset($type) && isset($queue['name'])) {
$rss_title = sprintf(_("%s %s tickets in %s"),
}
$template = $injector->createInstance('Horde_Template');
-$template->set('xsl', $registry->get('themesuri') . '/feed-rss.xsl');
+$template->set('xsl', Horde_Themes::getFeedXsl());
$template->set('pubDate', htmlspecialchars(date('r')));
$template->set('title', _("Search Results"));
$template->set('items', $items, true);
+++ /dev/null
-<?xml version="1.0"?>
-
-<xsl:stylesheet version="1.0"
- xmlns="http://www.w3.org/1999/xhtml"
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns:rss="http://purl.org/rss/1.0/"
- xmlns:atom="http://www.w3.org/2005/Atom">
-
- <xsl:output indent="yes" encoding="UTF-8"/>
-
- <xsl:template match="/rss|/atom:feed">
- <html>
- <head>
- <title>
- <xsl:value-of select="/rss/channel/title"/>
- </title>
- <style type="text/css">
- img {
- border: 0;
- padding: 5px;
- }
- </style>
- </head>
- <body>
- <p>
- You're viewing an XML content feed which is
- intended to be viewed within a feed aggregator.
- </p>
-
- <h3>Subscribe to <xsl:value-of select="/rss/channel/title"/></h3>
-
- <p>
- Subscribe now in your favorite RSS aggregator:
- </p>
-
- <xsl:variable name="resource" select="/rss/channel/atom:link"/>
-
- <div>
- <a href="http://www.rojo.com/add-subscription?resource={$resource}">
- <img src="http://www.rojo.com/skins/static/images/add-to-rojo.gif" alt="Subscribe in Rojo"/>
- </a>
-
- <a href="http://add.my.yahoo.com/rss?url={$resource}">
- <img src="http://us.i1.yimg.com/us.yimg.com/i/us/my/addtomyyahoo4.gif" alt="Add to My yahoo" />
- </a>
-
- <a href="http://www.newsgator.com/ngs/subscriber/subext.aspx?url={$resource}">
- <img src="http://www.newsgator.com/images/ngsub1.gif" alt="Subscribe in NewsGator Online"/>
- </a>
-
- <a href="http://www.bloglines.com/sub/{$resource}">
- <img src="http://www.bloglines.com/images/sub_modern5.gif" alt="Subscribe with Bloglines"/>
- </a>
-
- <a href="http://fusion.google.com/add?feedurl={$resource}">
- <img src="http://buttons.googlesyndication.com/fusion/add.gif" alt="Subscribe with Google Reader"/>
- </a>
- </div>
-
- <p>
- <h3>Preview</h3>
- </p>
-
- <xsl:apply-templates select="/rss/channel/item" />
-
- </body>
- </html>
- </xsl:template>
-
- <xsl:template match="item">
- <xsl:variable name="link" select="link"/>
- <p>
- <a href="{$link}">
- <xsl:value-of select="title"/>
- </a>
- </p>
- </xsl:template>
-
-</xsl:stylesheet>
}
$template = $injector->createInstance('Horde_Template');
-$template->set('xsl', $registry->get('themesuri') . '/feed-rss.xsl');
+$template->set('xsl', Horde_Themes::getFeedXsl());
$template->set('pubDate', htmlspecialchars(date('r')));
$template->set('title', htmlspecialchars($details['summary']));
$template->set('items', $items, true);