WordPress.org

Support

Support » Plugins and Hacks » [Resolved] Disable hour selection is "all day" chosen

[Resolved] Disable hour selection is "all day" chosen

  • Hello,

    Usability feature request: disable hour fields is “all day” is selected. This could be easily done in JQuery, something in line of:

    $(“#em-time-all-day”).toggle(function (){
    $(“#start-time”).attr(“disabled”,true);
    $(“#end-time”).attr(“disabled”,true);
    };

    (idea code, not final, not tested)

    Steps to reproduce:
    1. open http://demo.wp-events-plugin.com/submit-your-event/
    2. select “all day”
    result: start and end hour fields are available
    expected: these fields should be disabled, since the event is all day and allowing to select meaningless hours is bad usability

    http://wordpress.org/extend/plugins/events-manager/

Viewing 4 replies - 1 through 4 (of 4 total)
  • hi,

    you can try conditional placeholders at http://wp-events-plugin.com/documentation/conditional-placeholders/ e.g. {all_day}content{/all_day} or {has_time}content{/has_time}

    Conditionals are parsed in PHP and affect the event view. I am now talking about a JavaScript feature in the event submission form, please read again my feature request.

    In title “is” whould be “if”, sorry for the typo, don’t know how to edit it anymore.

    I see, you can try to add javascript (as per above js) using template files at wp-content/plugins/events-manager/templates/forms/event/when.php

    using template files

    Using Template Files

    I think this feature should be by default, since it would benefit everybody.

    If Events Manager was in Git it would be easy for me to fork it, code this and make a pull request to get it upstream, but it is in SVN, so distributed development is a bit difficult..

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Resolved] Disable hour selection is "all day" chosen’ is closed to new replies.