velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nathan Bubna" <nbu...@gmail.com>
Subject Re: Velocity date function??
Date Thu, 09 Aug 2007 16:25:25 GMT
Velocity doesn't provide access to the current date automatically.
However, the VelocityTools project does have a DateTool which can do
that and much more for you.  You can just add an instance of it to the
context.

http://velocity.apache.org/tools/devel/generic/

On 8/9/07, Thomas Foster <THOMFOST@uk.ibm.com> wrote:
> Hi,
>
> I am wanting to write a macro to use in Atlassian Confluence. It basically
> provides a list of links to the past 12 months of news (each month having
> its own link).
> E.g.
>
> August 2007
> July 2007
> June 2007
> May 2007
> ...
>
> However I want the macro to be automated so that when, for example, it
> turns to september 2007, it will automatically add the link for that month
> and remove the previous september 2006 link. I've never used Velocity
> before but I have had a quick look at the documentation. But what i was
> wondering is, is there a function in Velocity which provides the current
> date?? If not, are there any tips or features which could help me create
> this macro?
>
> Thank you for your time,
>
> Tom
>
>
>
>
>
> Unless stated otherwise above:
> IBM United Kingdom Limited - Registered in England and Wales with number
> 741598.
> Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
>
>
>
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@velocity.apache.org
For additional commands, e-mail: user-help@velocity.apache.org


Mime
View raw message