You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Roland Bali <ro...@gmail.com> on 2005/10/28 13:16:20 UTC
[m2] Image link when creating a site?
Hi,
I'm trying to add a image link to my site descriptor but the image is
not added. I've tried the following:
<menu name="Links">
<item name="image1" href="http://maven.apache.org"
img="http://maven.apache.org/images/logos/maven-feather.png"/>
<item name="image2" href="http://maven.apache.org"
src="http://maven.apache.org/images/logos/maven-feather.png"/>
</menu>
I also would like to have a image at the same level as the default
"created by Maven"-image is it possible to add such a image in the
site descriptor so I won't have to modify the generated .html files?
Kind regards,
Roland
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: [m2] Image link when creating a site?
Posted by Roland Bali <ro...@gmail.com>.
Thanks Rohnny, great tip!
/Roland
On 10/28/05, Rohnny Moland <rm...@gmail.com> wrote:
> On 10/28/2005 01:16 PM, Roland Bali wrote:
> > Hi,
> >
> > I'm trying to add a image link to my site descriptor but the image is
> > not added. I've tried the following:
> >
> > <menu name="Links"> <item name="image1"
> > href="http://maven.apache.org"
> > img="http://maven.apache.org/images/logos/maven-feather.png"/> <item
> > name="image2" href="http://maven.apache.org"
> > src="http://maven.apache.org/images/logos/maven-feather.png"/>
> > </menu>
> >
> > I also would like to have a image at the same level as the default
> > "created by Maven"-image is it possible to add such a image in the
> > site descriptor so I won't have to modify the generated .html files?
> >
> >
> >
> > Kind regards,
> >
> > Roland
> >
>
> You can by creating a custom velocity template, and include it in your
> src/site/resources directory. In your pom you also have to add something
> like this:
>
> [..]
> <plugin>
> <groupId>org.apache.maven.plugins</groupId>
> <artifactId>maven-site-plugin</artifactId>
> <configuration>
> <templateDirectory>
> file://${basedir}/src/site/resources/
> </templateDirectory>
> <template>your-site.vm</template>
> </configuration>
> </plugin>
> [..]
>
> Look into the maven-site-plugin.jar for a default maven-site.vm
> template, you can use as a start point.
>
>
> Hope this helps,
>
> --
> Rohnny
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: [m2] Image link when creating a site?
Posted by Rohnny Moland <rm...@gmail.com>.
On 10/28/2005 01:16 PM, Roland Bali wrote:
> Hi,
>
> I'm trying to add a image link to my site descriptor but the image is
> not added. I've tried the following:
>
> <menu name="Links"> <item name="image1"
> href="http://maven.apache.org"
> img="http://maven.apache.org/images/logos/maven-feather.png"/> <item
> name="image2" href="http://maven.apache.org"
> src="http://maven.apache.org/images/logos/maven-feather.png"/>
> </menu>
>
> I also would like to have a image at the same level as the default
> "created by Maven"-image is it possible to add such a image in the
> site descriptor so I won't have to modify the generated .html files?
>
>
>
> Kind regards,
>
> Roland
>
You can by creating a custom velocity template, and include it in your
src/site/resources directory. In your pom you also have to add something
like this:
[..]
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<configuration>
<templateDirectory>
file://${basedir}/src/site/resources/
</templateDirectory>
<template>your-site.vm</template>
</configuration>
</plugin>
[..]
Look into the maven-site-plugin.jar for a default maven-site.vm
template, you can use as a start point.
Hope this helps,
--
Rohnny
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org