Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #1297224

    Hello! Thank you in advance for any help you can provide.
    I have followed this tutorial, https://www.youtube.com/watch?v=ezR27jB7zL8 as well as read about this in the form, but have not been successful. When I set it up, nothing happens.

    Here is what I’ve tried:

    1. I added this to my child theme:

    function inline_popup_enabler(){
    ?>
    <script>
    (function($){
    $(window).load(function() {
    $(‘.inline_popup’).magnificPopup({
    type:’inline’,
    midClick: true
    });
    });
    })(jQuery);
    </script>
    <?php
    }
    add_action(‘wp_footer’, ‘inline_popup_enabler’);

    2. and this is what I put on the page itself:

    A. This is my text link to the anchor:
    Sherry Bonanno
    (This gets lost when I submit, so here it is without the a, /a :)
    class=”inline_popup” href=”#sherry-bonanno”>Sherry Bonanno

    B. These are my color section Developer Settings for the anchor itself:
    Custom ID Attribute: sherry-bonnano
    Custom CSS Class: mfp-hide

    Details: Within this color section I have a special heading, and two columns containing a text block and image. this should display in the lightbox popup, but it simply remains hidden.

    Kind Regards,
    Doug

    • This topic was modified 3 years, 7 months ago by doug123. Reason: added some details
    #1297648

    Hi – just thought I’d check in to see if you have any thoughts about the above?

    Thank you!

    #1297929

    Hi,

    Thank you for the inquiry.

    We may need to actually inspect the page in order to check if there is any causing the lightbox to not fire correctly. Please post the URL in the private field.

    Have you tried adding a priority number to the wp_footer hook?

    add_action("wp_footer", "inline_popup_enabler", 9999);
    

    Best regards,
    Ismael

    #1298083

    Thank you Ismael!

    no, that didn’t work. when I add your line to the child theme’s functions.php, the 9999 becomes dashes, and doesn’t make it work.

    #1298399

    Hi,

    Thanks for the update.

    We cannot find the inline popup in the home page. Where did you add it? Please provide a direct link to the page.

    the 9999 becomes dashes

    That is new. Would you mind providing a screenshot? Please use imgur or dropbox.

    Best regards,
    Ismael

    #1298401

    Hi,

    UPDATE: We edited the code in the functions.php file a bit and created a test page. (see private field)

    Best regards,
    Ismael

    #1298402

    Hi,

    UPDATE: We edited the code in the functions.php file a bit and created a test page. (see private field)

    Best regards,
    Ismael

    #1298684

    Hey Ismael! Thank you – the popup has no margins though, Whereas a normal gallery image popup does have left, right, top, bottom margins. Can margins be added just like those on an image lightbox?
    The problem is that the color section popup covers the entire browser screen, so I might as well be using a separate page instead of a lightbox.

    Please see the test page you created. I have added some test content for example of what I mean. It just really needs margins like those on image lightboxes.

    I’d really like to use the Enfold popup solution rather than a plugin.

    thank you again for all your efforts! I really appreciate it.

    #1298892

    Hi,

    Thank you for the update.

    You can adjust the style of lightbox container so that it only takes a percentage of the screen instead of depending on the content. Try to use this css code.

    .mfp-inline-holder .mfp-content, .mfp-ajax-holder .mfp-content {
        width: 80%;
        margin: 50px;
    
    }

    We also added a 50px margin around the lightbox container.

    Best regards,
    Ismael

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