I purpose we need to make the date range separator (currently 'to') more dynamic. I had to go into date.theme and change this to a dash. I will have to redo this every time the module updates now.
Here is what I purpose. A new field found at '/admin/config/regional/date-time/formats/[format_id]/edit' that allows user input. That way each format that is applied can have a unique separator? If I get some free time this week I can look into building this but I want to make sure this commit could work its way into the Date module or if I should create an additional module to tie into Date for this functionality. Seems pretty universal to me.
Comments
Comment #1
HeathN CreditAttribution: HeathN commentedComment #2
pacome CreditAttribution: pacome commentedHello,
a simple solution is to copy the date_display_range function from date.theme to your theme template.php,
then rename with your theme name, and change the separator as you like :
(do not forget to flush all your cache ;)
This way you are not going to have any trouble while updating modules and so..
regards
P-
Comment #3
miromarchi CreditAttribution: miromarchi commentedThanks, copying date_display_range function in my theme template.php worked perfectly! Now I can update date module without loosing my start - end date separator customization.
Thanks
Comment #4
maxplus CreditAttribution: maxplus commentedThanks,
#2 helped me out, I also added a div around my separator this way, handy for styling!
Comment #5
Taliesin84 CreditAttribution: Taliesin84 commentedHi there, and I hope someone sees this.
I tested pacome's solution and it works great, but I need to apply it to a specific content type I created.
I have no idea where to start, and I want to learn how to do this.
Can I get a few pointers?
Thanks a bunch