GD Post Meta – business_hours does not apply the date format

This topic contains 9 replies, has 2 voices, and was last updated by  directoryfan 4 years, 2 months ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #527836

    directoryfan
    Expired Member
    Post count: 157

    Hello Support Team,

    how can I change the date format for the business_hours? This field does not apply the format under WP:Settings or under GD:Events (d.m.y)

    This is the shortcode that I use on the archive item page:

    [gd_post_meta key='business_hours' location='listing' list_hide_secondary='2']

    And it applies this format: j. F Y

    Greetings, Marius

    #527848

    Alex Rollin
    Moderator
    Post count: 27815

    That is the event date, not the business hours.

    Business hours does not have a date. Words for days, but not a date.

    What are you using to show that event date? Have you reviewed the settings in:

    GD – Settings – Events (tab) – Show advanced

    #527854

    directoryfan
    Expired Member
    Post count: 157

    Hi Alex and thank you for your help!

    You have right, there is no key for business_hours, I thin I have this from the docs, I’m not sure.

    Yes, under WP:Settings and GD:Settings:Events is the format what I want to have: d.m.y

    I have changed the code to:

    [gd_post_meta key="event_dates" location='listing' ]

    And now I have twice the dates, see attachements. Why?

    I want to output the date and the time of the event.

    #527865

    directoryfan
    Expired Member
    Post count: 157

    And now I have tried with the key timing and it is without double dates, but the format is still the wrong one.

    [gd_post_meta key="timing" location='listing']

    So is this a bug, why it does not apply the standard date format?

    #527868

    directoryfan
    Expired Member
    Post count: 157
    This reply has been marked as private.
    #527930

    Alex Rollin
    Moderator
    Post count: 27815

    In your archive item template you are using

    [gd_output_location location='listing']

    This will show all the fields marked in Custom Fields. For each field like date check the “Show in extra locations” for the value of ‘listings’ and remove that value from items you want to exclude from the listings.

    Other shortcodes like GD Event Schedules or GD Post Meta will give you different display options, but the date format is most flexible with GD Event Schedules. Check it out and let us know.

    #527932

    Alex Rollin
    Moderator
    Post count: 27815

    ex.

    
    
    
    [geodir_event_schedules type="upcoming" number="1" date_format="d/m/Y" template="{start_date} @ {start_time} - {end_date} @ {end_time}" use_current="1"]
    
    #529957

    directoryfan
    Expired Member
    Post count: 157

    Hi Alex, and thank you for explaining this! This helped me a lot.

    Under the place settings the timing field and under the event settings the event_dates field are both selected to display on the listings output location. And this works great, just that the event_dates field does not use the WP date format (under WP:Settings GD:Settings:Events is the format what I want to have: d.m.y)

    For me this should be enough without using some extra shortcode for the archive item template, but the event_dates field does not apply the date format.

    Do you think this is a bug?

    Greetings, Marius

    #530033

    Alex Rollin
    Moderator
    Post count: 27815

    Using the GD Output Location will use only the default display format.

    If you want to control it, edit the GD Archive template and use GD Event Schedules

    #533355

    directoryfan
    Expired Member
    Post count: 157

    Hi Alex and thank you four your help.

    After the last update the event_dates field displays the default WP date format. I`ll consider your alternative for another task, thx.

    Greetings

Viewing 10 posts - 1 through 10 (of 10 total)

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket