Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1256242

    Hi

    I like the style of the datepicker in an enfold form but for added functionality I am using gravity forms
    But the default datepicker in gravity forms is not very nice

    How do I apply the style of the Enfold datepicker to the datepicker on Gravity form?

    #1257367

    Hey briandeeney,
    Sorry for the very late reply, and thanks for the links to the two test pages. So to try and make the Gravity Forms datepicker look like the Enfold datepicker we first need to add the Enfold class avia-datepicker-div to the datepicker so the Enfold css will apply.
    You are welcome to try this by adding this code to the end of your functions.php file in Appearance > Editor:

    function custom_datepicker_script(){
      ?>
      <script>
    (function($){
    $('.ginput_container_date').click(function() {
      $('body').find('#ui-datepicker-div').addClass('avia-datepicker-div');
    });
    })(jQuery);
    </script>
    <?php
    }
    add_action('wp_footer', 'custom_datepicker_script');

    You will see that this helps, but your Gravity Forms css is still overriding some of the elements of the datepicker and it also looks like you are using site caching so it’s a little hard to tell.
    Please disable all caching and compression so we can investigate further.
    Please remove the script above after if you test it, I will probably need to adjust it further.

    Best regards,
    Mike

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.