You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by sebb AT ASF <se...@apache.org> on 2011/03/07 02:37:49 UTC
Re: svn commit: r1078638 - /commons/proper/commons-parent/trunk/src/site/site.xml
On 7 March 2011 00:38, <se...@apache.org> wrote:
> Author: sebb
> Date: Mon Mar 7 00:38:32 2011
> New Revision: 1078638
>
> URL: http://svn.apache.org/viewvc?rev=1078638&view=rev
> Log:
> Add trademark markers
> Allow relative URL for Commons logo, but absolute URL for link
>
> Modified:
> commons/proper/commons-parent/trunk/src/site/site.xml
>
> Modified: commons/proper/commons-parent/trunk/src/site/site.xml
> URL: http://svn.apache.org/viewvc/commons/proper/commons-parent/trunk/src/site/site.xml?rev=1078638&r1=1078637&r2=1078638&view=diff
> ==============================================================================
> --- commons/proper/commons-parent/trunk/src/site/site.xml (original)
> +++ commons/proper/commons-parent/trunk/src/site/site.xml Mon Mar 7 00:38:32 2011
> @@ -24,8 +24,23 @@
>
> <bannerLeft>
> <name>Apache Commons</name>
> - <src>http://commons.apache.org/images/logo.png</src>
> - <href>http://commons.apache.org/</href>
> + <!--
> + ! Even though the default site.vm template contains code to convert relative links, this is
> + ! actually done before the content is passed to the template.
> + ! Unfortunately, this means that the conversion is done in the context of commons-parent, which
> + ! contains the site.xml, rather than in the context of the project being built.
> + ! This means that relative URLs are created with an additional ../ prefix.
> + ! The work-round is to use a dummy absolute URL that can never be used, and then remove this
> + ! as part of the template processing.
> + -->
> + <src>http://dummy.invalid/$relativePath/images/commons-logo.png</src>
> + <alt>Apache Commons logo</alt>
> + <!--
> + ! Similarly href entries are converted before they are passed to the template.
> + ! In this case, we want the URL to remain absolute.
> + ! The work-round is to use a dummy suffix that is removed by the template.
> + -->
It looks like this behaviour changes when using site:stage, so perhaps
the fixes were not needed after all...
I need to do some more testing and will revert the site.xml changes if
they aren't needed.
[Might be worth keeping the template changes in case they are still useful]
BTW, does anyone know why site:site relativises the parent directory
(i.e. commons.apache.org) and site:stage does not?
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org