|
|
Choosing A Webhost: |
svn commit: r532267 - in /lenya/trunk/src/modules/svg: config/module.xml xs: msg#00171cms.lenya.cvs
Author: nettings Date: Wed Apr 25 01:53:20 2007 New Revision: 532267 URL: http://svn.apache.org/viewvc?view=rev&rev=532267 Log: added check for existing query string to avoid duplicate parameters and an invalid uri. this fixes bug http://issues.apache.org/bugzilla/show_bug.cgi?id=42229 Modified: lenya/trunk/src/modules/svg/config/module.xml lenya/trunk/src/modules/svg/xslt/image2svg.xsl Modified: lenya/trunk/src/modules/svg/config/module.xml URL: http://svn.apache.org/viewvc/lenya/trunk/src/modules/svg/config/module.xml?view=diff&rev=532267&r1=532266&r2=532267 ============================================================================== --- lenya/trunk/src/modules/svg/config/module.xml (original) +++ lenya/trunk/src/modules/svg/config/module.xml Wed Apr 25 01:53:20 2007 @@ -22,7 +22,9 @@ <id>org.apache.lenya.modules.svg</id> <package>org.apache.lenya.modules</package> <version>0.1-dev</version> - <name>SVG</name> + <name>SVG image rendering</name> <lenya-version>@lenya.version@</lenya-version> - <description>SVG-based image rendering</description> + <description>The SVG module generates the rounded corners for + the Lenya dialogs, and re-scales pixel-based GIF, JPG and PNG images on the + fly, depending on height and width query parameters. It uses Batik.</description> </module> Modified: lenya/trunk/src/modules/svg/xslt/image2svg.xsl URL: http://svn.apache.org/viewvc/lenya/trunk/src/modules/svg/xslt/image2svg.xsl?view=diff&rev=532267&r1=532266&r2=532267 ============================================================================== --- lenya/trunk/src/modules/svg/xslt/image2svg.xsl (original) +++ lenya/trunk/src/modules/svg/xslt/image2svg.xsl Wed Apr 25 01:53:20 2007 @@ -21,7 +21,18 @@ <xsl:template match="xhtml:img[@height and @width]/@src"> <xsl:attribute name="src"> - <xsl:value-of select="."/> + <!-- if the src attribute already contains a querystring, cut it off. otherwise, multiple + querystrings can accumulate! + NB: substring-before returns the empty string if the needle is not found. + --> + <xsl:choose> + <xsl:when test="contains(.,'?')"> + <xsl:value-of select="substring-before(.,'?')"/> + </xsl:when> + <xsl:otherwise> + <xsl:value-of select="."/> + </xsl:otherwise> + </xsl:choose> <xsl:text>?</xsl:text> <xsl:text>lenya.module=svg&</xsl:text> <xsl:if test="string(../@height)">
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | svn commit: r532255 - /lenya/trunk/src/webapp/lenya/resources/menu/menu.js, nettings |
|---|---|
| Next by Date: | svn commit: r532284 - /lenya/trunk/src/resources/dev/eclipse/project, andreas |
| Previous by Thread: | svn commit: r532255 - /lenya/trunk/src/webapp/lenya/resources/menu/menu.js, nettings |
| Next by Thread: | svn commit: r532284 - /lenya/trunk/src/resources/dev/eclipse/project, andreas |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |