Data decorating and Symfony2 -
Data decorating and Symfony2 -
abstract question. there "data decorator" bundle symfony2? or how solve elegantly info localization/formatting problems?
for example:
float - decimals formatting, monetary info needs monetary formatting integers - formatting - 1'000'000 vs 1.000.000 dates, times etci know symfony1 had kind decorating going on in templates suit exactly. wasn't perfect, though , arised other problems.
anybody knows, there something? or "correct" way solving problem?
your question stands vague , answers can considered opinion-based, you're aware native php functions you're asking for, right?
float, integer formatting:number_format
date/time formatting: datetime
class , subsequent format
functions twig uses equivalent functions accomplish you're asking for: number_format
, date
filters.
this right standard - , although have literally no experience symfony1, haven't had issue deploying dozen symfony2 projects using these 2 functions accomplish info decorating desire.
symfony2
Comments
Post a Comment