The script is being added incorrectly, causing a Javascript error (1 post)

  1. Chris Jean
    Posted 4 years ago #

    This plugin has not been updated in a long time and could really use some updates. It seems that the externally loaded Javascript code was modified at some point, breaking this plugin.

    Activating the plugin and loading the site results in the following error:

    document.body is null

    This is because the script is being printed in the head of the site, before the body tag is rendered and the Javascript attempts to immediately run appendChild on the body.

    A quick and dirty fix is to change the following line:

    add_action('wp_head', 'includeJSHeader', 40);


    add_action('wp_footer', 'includeJSHeader', 40);

    While this fixes the issue, the plugin really should be updated to properly enqueue the script and stylesheet using wp_enqueue_script and wp_enqueue_style, respetively; to properly use capabilities for adding to the menu rather than a number; and to update the editor to more closely match the UI design of WordPress.


Topic Closed

This topic has been closed to new replies.

About this Plugin

  • eBible
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic