Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Date transformation

Status
Not open for further replies.

ddrillich

Technical User
Jun 11, 2003
546
US
Good Day,

We have dates stored as '18-Nov-2009 03:00:00 pm'.

We would like to present them in the front end as, let's say '2 hours, 51 minutes ago'.

Is it possible?

Regards,
Dan
 
Thank you Dian - do you have, by any chance, any more information to share?

Regards,
Dan
 



He DID answer your question.

Skip,

[glasses]Just traded in my old subtlety...
for a NUANCE![tongue]
 
You're welcome, Dan. Do you have, by any chance, any information to share?

Where is it stored? Where do you want to show it? What technology are you using? If not, I'm afraid that was the only possible answer I will be able to have

Cheers,
Dian
 
Sorry, I thought it was clear :) - I'm speaking about XSLT. we read the date field from an xml document and would like to transform it to this '2 hours, 51 minutes ago' format.

Thank You,
Dan
 
Dan,

You would need to pass the current date-time as a global parameter from the outside world. Check out the examples from XSL Cookbook which has a chapter on date and time arithmetic.

Tom Morrison
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top