Q. display date only for reivew postedDateTime

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Q. display date only for reivew postedDateTime

HyunWoo Jo
hello users!

this could be very simple, i just dont know how to do.

in product review, it displays date and time, but how i can make it  
shows only date only?

i am working with ecommerce/webapp/ecommerce/catalog/productdetail.ftl
and this is the line that i am trying to figure out.

${uiLabelMap.CommonAt}: ${productReview.postedDateTime?if_exists)

how do make this to display date only in web browser?

thank you in advance.



Reply | Threaded
Open this post in threaded view
|

Re: Q. display date only for reivew postedDateTime

Adrian Crum
http://www.freemarker.org/docs/ref_builtins_date.html

-Adrian

On 6/7/2010 2:19 PM, HyunWoo Jo wrote:

> hello users!
>
> this could be very simple, i just dont know how to do.
>
> in product review, it displays date and time, but how i can make it
> shows only date only?
>
> i am working with ecommerce/webapp/ecommerce/catalog/productdetail.ftl
> and this is the line that i am trying to figure out.
>
> ${uiLabelMap.CommonAt}: ${productReview.postedDateTime?if_exists)
>
> how do make this to display date only in web browser?
>
> thank you in advance.
>
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Q. display date only for reivew postedDateTime

Patrick-4
In reply to this post by HyunWoo Jo
I would make a java function to trim the string there might be other ways

<#assign dateOnly= someStaticJavaFunction(productReview.postedDateTime) />

On Mon, Jun 7, 2010 at 4:19 PM, HyunWoo Jo <[hidden email]> wrote:

> hello users!
>
> this could be very simple, i just dont know how to do.
>
> in product review, it displays date and time, but how i can make it shows
> only date only?
>
> i am working with ecommerce/webapp/ecommerce/catalog/productdetail.ftl
> and this is the line that i am trying to figure out.
>
> ${uiLabelMap.CommonAt}: ${productReview.postedDateTime?if_exists)
>
> how do make this to display date only in web browser?
>
> thank you in advance.
>
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: Q. display date only for reivew postedDateTime

HyunWoo Jo
Patrick,

thanks for the advice.
i tried your suggested code below, but it didn't work out.
i guess i had to make a java too in conjunction with the code you  
provided, hadn't i?
if it's the case, i don't know how to.

however, Adrian's link works for me

thank you though.

hyun




On Jun 7, 2010, at 5:55 PM, Patrick wrote:

> I would make a java function to trim the string there might be other  
> ways
>
> <#assign dateOnly=  
> someStaticJavaFunction(productReview.postedDateTime) />
>
> On Mon, Jun 7, 2010 at 4:19 PM, HyunWoo Jo <[hidden email]>  
> wrote:
>> hello users!
>>
>> this could be very simple, i just dont know how to do.
>>
>> in product review, it displays date and time, but how i can make it  
>> shows
>> only date only?
>>
>> i am working with ecommerce/webapp/ecommerce/catalog/
>> productdetail.ftl
>> and this is the line that i am trying to figure out.
>>
>> ${uiLabelMap.CommonAt}: ${productReview.postedDateTime?if_exists)
>>
>> how do make this to display date only in web browser?
>>
>> thank you in advance.
>>
>>
>>
>>

Reply | Threaded
Open this post in threaded view
|

Re: Q. display date only for reivew postedDateTime

HyunWoo Jo
In reply to this post by Adrian Crum
Adrian,

thank you very much. it works for me.

again, thank you.

hyun




On Jun 7, 2010, at 5:54 PM, Adrian Crum wrote:

> http://www.freemarker.org/docs/ref_builtins_date.html
>
> -Adrian
>
> On 6/7/2010 2:19 PM, HyunWoo Jo wrote:
>> hello users!
>>
>> this could be very simple, i just dont know how to do.
>>
>> in product review, it displays date and time, but how i can make it
>> shows only date only?
>>
>> i am working with ecommerce/webapp/ecommerce/catalog/
>> productdetail.ftl
>> and this is the line that i am trying to figure out.
>>
>> ${uiLabelMap.CommonAt}: ${productReview.postedDateTime?if_exists)
>>
>> how do make this to display date only in web browser?
>>
>> thank you in advance.
>>
>>
>>
>>