-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TTimeDelta for showing how long ago something was posted (eg 10 seconds, 39 minutes, 6 hours, etc) #777
Comments
I'm thinking about how this should work. I have a prototype for comment here: https://github.com/belisoful/prado/blob/master/framework/Web/UI/WebControls/TTimeAgo.php I'm thinking of removing the "ago" part and just focus on the timing, both count down to a time, and how long ago a time was. I'm also waiting on fixing my computer code so php ICU-units works. I'm just focusing on these other changes first. |
The environment I was in before didn't have the PHP resources built in for I18N. when I have a moment, I'll re-look at this again. |
Maybe php 8 (and the OS) has these I8N resources on my dev system now |
You can use php's DateInterval to calculate the "time delta" and format it. |
I was trying to access the ICU Data but in the prior php system it was not found. It just wasn't there. So. It was delayed. |
imagining: `"2023-05-31 13:11:11+800" web component? and having the TTimeAgo for the template? Prado doesn't have any architecture for WebComponents. #963 |
this is an interactive interface control for displaying how long ago something was done/posted/submitted/etc.
Many websites now have the "10 minutes ago" that updates in real time for how long ago something was posted.
PRADO needs a component for displaying how long ago something was done. I propose that clicking on the "xx minutes/hours ago" would change to the date and time of the event.
This is developed here:
https://github.com/belisoful/prado/blob/master/framework/Web/UI/WebControls/TTimeAgo.php
There is a javascript aspect to this component so Prado JS map is updated.
The major challenge is I18N of this component as the interface is driven by javascript rather than server side.
The text was updated successfully, but these errors were encountered: