Title: Javascript errors causing booking calendar to break
Last modified: May 21, 2024

---

# Javascript errors causing booking calendar to break

 *  Resolved [stephenevans](https://wordpress.org/support/users/stephenevans/)
 * (@stephenevans)
 * [2 years ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/)
 * Hi there,
 * I am trying to add the booking calendar in to the site but it gives us many JavaScript
   errors with the first one being:
 * Uncaught TypeError: Cannot read properties of undefined (reading ‘_getInst’)
 * **And then you get these on hover:**
 * booking-form-testing-2/:762 Uncaught TypeError: Cannot read properties of undefined(
   reading ‘_doMouseOver’)
 * booking-form-testing-2/:762 Uncaught TypeError: Cannot read properties of undefined(
   reading ‘_doMouseOut’)
 * I’m not sure what is causing the JavaScript to not be found because I have looked
   through our plugins and can’t see any that would be deferring the JavaScript.
 * Thanks,
   Stephen
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fjavascript-errors-causing-booking-calendar-to-break%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 11 replies - 1 through 11 (of 11 total)

 *  Plugin Author [wpdevelop](https://wordpress.org/support/users/wpdevelop/)
 * (@wpdevelop)
 * [2 years ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17770027)
 * Hello.
    1. You are using this cache plugin: “LiteSpeed Cache”. Please deactivate it or 
       add the exception to the page with a booking form for do not cache this page(
       s).
    2. Also if the issue will still exist, please recheck that your theme or some other
       plugin does not load the jQuery library second time, after initial loading. 
       Find more information at this page: [https://wpbookingcalendar.com/faq/loading-jquery-twice/](https://wpbookingcalendar.com/faq/loading-jquery-twice/)
 * Kind Regards.
 *  Thread Starter [stephenevans](https://wordpress.org/support/users/stephenevans/)
 * (@stephenevans)
 * [2 years ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17770069)
 * Thank you for the reply.
 * I have tried disabling Litespeed Cache but that didn’t seem to work so I checked
   the theme files for additional JQuery installations but couldn’t find any.
 * Are there any other possible reasons this could be occurring?
 * Thanks,
   Stephen
 *  Plugin Author [wpdevelop](https://wordpress.org/support/users/wpdevelop/)
 * (@wpdevelop)
 * [2 years ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17770074)
 * Hello.
 * Currently when I try to open and test your webpage, I can see that it still cached.
   Please clear the cache and add the exception to the page with a booking form 
   for do not cache this page. Then I can test more about other issues.
 * Kind Regards.
 *  Thread Starter [stephenevans](https://wordpress.org/support/users/stephenevans/)
 * (@stephenevans)
 * [2 years ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17770084)
 * Okay I have deactivated it again.
 *  Plugin Author [wpdevelop](https://wordpress.org/support/users/wpdevelop/)
 * (@wpdevelop)
 * [2 years ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17770105)
 * Hello.
 * At the bottom of source code of your page, you have this JavaScript loading:
 * `appendChild(t)}e("https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.
   min.js"`
 * Such code make loading the jQuery second time and reset all previously defined
   JavaScript variables. That’s why you see those JavaScript errors.
 * You need to find what exactly (your theme or some other plugin) make such second
   loading of such jQuery library and prevent to do this. More here: [https://wpbookingcalendar.com/faq/loading-jquery-twice/](https://wpbookingcalendar.com/faq/loading-jquery-twice/)
 * Relative to  [WordPress best  practice](https://developer.wordpress.org/themes/basics/including-css-javascript/)
   it is not good idea to load the JS directly in the header or footer.
 * Kind Regards.
 *  Thread Starter [stephenevans](https://wordpress.org/support/users/stephenevans/)
 * (@stephenevans)
 * [2 years ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17770139)
 * Ah I have found the code and have commented it out for now and it seems to work
   fine.
 * Many thanks for the help,
   Stephen
 *  [tutum](https://wordpress.org/support/users/tutum/)
 * (@tutum)
 * [1 year, 12 months ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17823028)
 * Dear,
   Have the same error. According to us, Cach is off and jquery is not loading
   2 times. See [https://www.vakantiehuiscalpe.be/](https://www.vakantiehuiscalpe.be/)
   and then ‘Boek hier’ on the top right.
 *  Plugin Author [wpdevelop](https://wordpress.org/support/users/wpdevelop/)
 * (@wpdevelop)
 * [1 year, 12 months ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17823038)
 * Hello.
 * Please clear the cache of all minimized CSS and JavaScript files. Then test it
   again. 
   Kind Regards.
 *  Plugin Author [wpdevelop](https://wordpress.org/support/users/wpdevelop/)
 * (@wpdevelop)
 * [1 year, 12 months ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17823052)
 * And can you send screenshot of how did you added the Booking Calendar shortcodes
   to the page ?
 * Thank you.
 *  [tutum](https://wordpress.org/support/users/tutum/)
 * (@tutum)
 * [1 year, 12 months ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17823164)
 * Thanks for your quick response.
 * msg 1: we tested it on new pc and also with new private screen, nothing helped.
 * Msg 2: it is hard code in theme. An acquaintance created the site but was hacked
   this weekend. They have now asked to check everything. Did all junk via FTP from
   site, then ran all updates from WP and set PHP to highest version. Also changed
   all passwords.
 *  Plugin Author [wpdevelop](https://wordpress.org/support/users/wpdevelop/)
 * (@wpdevelop)
 * [1 year, 12 months ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17823169)
 * Hello. 
   Probably something wrong in the shortcode in your theme. Just need to
   check how it hard coded into your theme.
 * Kind Regards.

Viewing 11 replies - 1 through 11 (of 11 total)

The topic ‘Javascript errors causing booking calendar to break’ is closed to new
replies.

 * ![](https://ps.w.org/booking/assets/icon-256x256.gif?rev=3335907)
 * [Booking Calendar](https://wordpress.org/plugins/booking/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/booking/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/booking/)
 * [Active Topics](https://wordpress.org/support/plugin/booking/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/booking/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/booking/reviews/)

 * 11 replies
 * 3 participants
 * Last reply from: [wpdevelop](https://wordpress.org/support/users/wpdevelop/)
 * Last activity: [1 year, 12 months ago](https://wordpress.org/support/topic/javascript-errors-causing-booking-calendar-to-break/#post-17823169)
 * Status: resolved