End of time for event?

This topic contains 6 replies, has 2 voices, and was last updated by  Handelsplats Norsjö 6 years, 9 months ago.

Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #18422

    Hello
    In FES my visitors can write the end of the event. Where is that suppose to appear live?
    Right now only the start of the event is coming up live.
    What to do?
    /Anna

    Handelsplats Norsjö
    #18426

    At present Event Organiser only displays start dates – this will change in 3.0.0 when it will display events as a range.

    Until Event Organiser 3.0.0 is released you can edit event-meta-single-event.php to include the end date. Please see these threads for examples:

    Stephen Harris
    #18431

    Hello, thank´s. In these examples you refer to http://www.harriswebsolutions.co.uk, and those links does not work. I make it work in single events with:

     <!-- Single event --> 
     <?php _e('Start', 'eventorganiser') ;?>: <?php eo_the_start($date_format); ?> 
     End:<?php eo_the_end( $date_format ); ?> 
    

    But then the word “End” is not translated. How do I do this? And how do I show it in archive? Anna

    Handelsplats Norsjö
    #18436

    The end text isn’t translated because it’s hardcoded. Even if you used the _e function there might not be a translation available for it.

    Could you just use the translated text rather than English?

    The other templates can be found in /event-organiser/templates (see http://docs.wp-event-organiser.com/theme-integration/

    The codex linked to in the threads above can be found at http://www.codex.wp-event-organiser.com/

    Stephen Harris
    #18456

    Hello
    I do not understand what you mean because I am not comfortable with code/codex. I dont know what _e funktion is.
    I dont know what you mean with “Could you just use the translated text rather than English?” What translated text?

    Sorry for this but I need “step-by-step”. Or do you have any explanation how to do with the codex?

    Anna

    Handelsplats Norsjö
    #18460

    Hi Anna,

    “Could you just use the translated text rather than English?” What translated text

    So to recap – the snippet you added shows the event end date, but the text next to it appears as ‘End’ and you wanted that text to translated to something else? I’m guessing Swedish based on the site, and google translate tells me that you might want “Slutdatum” instead of “End”.

    In which case, simply replace “End:” in the above snippet with “Slutdatum:”.

    Using run-time translation (which is what _e( 'End:', 'eventorganiser' ) would effectively do) is needlessly convulted and complicated if you simply need the Swedish for ‘End:’.

    So I would suggest just is replacing:

    <!-- Single event -->
    <li><strong><?php _e('Start', 'eventorganiser') ;?>:</strong> <?php eo_the_start($date_format); ?> </li>
    

    with

     <!-- Single event -->
     <li><strong>Startdatum: <?php eo_the_start($date_format); ?></strong></li>
     <li><strong>Slutdatum: <?php eo_the_end( $date_format ); ?></strong></li>
    

    (apologies for any incorrect Swedish translations!)

    Stephen Harris
    #18474

    Thank you very very much!
    This works good and I´m very pleased!
    /Anna

    Handelsplats Norsjö
Viewing 7 posts - 1 through 7 (of 7 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.