Add back partial support for twitter.com using the old twitter mobile UI
[tweeper.git] / src / rss_converter_pump.io.xsl
index 61f4f7f..42f8ac0 100644 (file)
@@ -24,6 +24,9 @@
     xmlns:php="http://php.net/xsl"
     exclude-result-prefixes="php">
 
+    <xsl:param name="generate-enclosure"/>
+    <xsl:param name="show-usernames"/>
+
     <xsl:output method="xml" indent="yes"/>
 
     <xsl:variable name="domain-name" select="substring-after(//div[@id='profile-block']/@data-profile-id, '@')"/>
         <xsl:variable name="item-permalink" select=".//p[@class='muted']/small/a/@href"/>
         <item>
             <title>
-                <xsl:value-of select="concat($user-name, ': ', normalize-space($item-content))"/>
+                <xsl:if test="$show-usernames = 1">
+                    <xsl:value-of select="concat($user-name, ': ')"/>
+                </xsl:if>
+                <xsl:value-of select="normalize-space($item-content)"/>
             </title>
             <link>
                 <xsl:value-of select="$item-permalink"/>
                 <xsl:value-of select="php:functionString('Tweeper\Tweeper::strToRssDate', .//abbr[@class='easydate']/@title)"/>
             </pubDate>
             <description>
-                <xsl:value-of select="concat($user-name, ': ')"/>
                 <xsl:text disable-output-escaping="yes">&lt;![CDATA[</xsl:text>
+                <xsl:if test="$show-usernames = 1">
+                    <xsl:value-of select="concat($user-name, ': ')"/>
+                </xsl:if>
                 <xsl:copy-of select="$item-content/node()"/>
                 <xsl:text disable-output-escaping="yes">]]&gt;</xsl:text>
             </description>