Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Offline
Re: [solved] Date posted puzzlement
Wow, that’s a huge alteration, but fabulous it’s now compartmentalised. Should.make it far easier to make changes if there’s any tweaks needed. Nice work.
Is there any mileage in making our own DateTime (for example) class that encapsulates the new functions and safe_strftime(), etc? Or is it better to keep it as a function for speed?
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Hire Txp Builders – finely-crafted code, design and Txp
Offline
#18 Today 11:43:35
Re: [solved] Date posted puzzlement
Bloke wrote #343496:
Is there any mileage in making our own DateTime (for example) class that encapsulates the new functions and safe_strftime(), etc? Or is it better to keep it as a function for speed?
I do not think this would make a big difference. One of the advantages of the classes is loading on demand, thus sparing some memory when a class is not required (we do it for some less-used tags). But date/time functions are used on almost all pages, so we would not improve anything performance-wise by implementing a new class.
The main question atm is whether everything date-related works ok now, in each db version.
Offline