• Resolved HeadyRules

    (@headyrules)


    Hi there,

    i made my first theme and i have the following problem:
    It seems that my theme does not allow js from any plugin and i am not quite sure how to enable that.

    The exact situation:
    I wanted to use a Lightbox Plugin, it didnt work with my theme (but with others) so i contacted the support and they told me, that my theme would not allow javascript from any plugin. I can’t really find the difference when comparing my theme to downloaded ones, so i ahve to ask here. I use wp_enqueue_script for the scripts my theme needs.

Viewing 5 replies - 16 through 20 (of 20 total)
  • Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    I appreciate that and maybe when the source of the problem is found it can be related to the Simple Lightbox plugin too, but it’s easier to focus debugging one plugin at a time.

    Are you using multiple templates for different pages with the </body> tag in?

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Make sure to apply this code:

    <?php wp_footer(); ?>
    </body>

    Everywhere that’s needed.

    Thread Starter HeadyRules

    (@headyrules)

    Yes, at the moment i only have the Huge-IT Version installed and i am only trying to make that one work.

    Only one template is active.

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    So in my above comment when I said…

    Try putting the ‘wp_footer’ function just above your ‘</body>’ tag and see…

    Can you try adding this code instead:

    <?php wp_footer(); ?>
    <div style="display: none">Don't worry this will be hidden</div>
    </body>

    Thread Starter HeadyRules

    (@headyrules)

    Ok i did that, and i saw that this div did not appear on every site bc i forgot to place the “get_footer” on a page template. I fixed that, and now the lightbox worked.

    The most dumb mistakes cause the most work i guess ?? But thank you very much for your time!

Viewing 5 replies - 16 through 20 (of 20 total)
  • The topic ‘Allow plugins js in theme’ is closed to new replies.