Include Facebook Javascript SDK In WordPress

I’m assuming you’re referring to the header.php file of your theme. In that case, it’s as easy as just enqueueing the script by appending this function to your theme’s functions.php file: function enqueue_facebook_javascript_sdk(): void { wp_enqueue_script( ‘facebook-javascript-sdk-initializer’, get_template_directory_uri() . ‘/path/to/your/initializer.js’ ); wp_enqueue_script( ‘facebook-javascript-sdk’, ‘https://connect.facebook.net/en_US/sdk.js’, array(), null ); return; } add_action( ‘wp_enqueue_scripts’, ‘enqueue_facebook_javascript_sdk’ ); The first … Read more

Embed Kajabi into WP

Welcome to WPSE. When asking a question it is recommended to include your research and what you’ve already tried in your question. One option would be to turn the script into a shortcode with add_shortcode(). With a custom shortcode you can have any Kajabi form anywhere on your site as long as the shortcode takes … Read more

List unused javascript for easy removal

Is there a list somewhere of what each of these WordPress related javascripts do? There is no comprehensive list that does this, and many of those items would not appear on it as they’re not WordPress internal files or may be required by non-WordPress files to function. Those files may be built to require them … Read more

Loading 2 Different Version of JS files [closed]

My only question is will this (loading 2 JS files of different versions) create any problem in any other pages? Likely. WP loads jQuery in noConflict mode, meaning it doesn’t occupy typical $ variable, but only jQuery one. However another copy of jQuery can very well get in a fight over jQuery one with the … Read more

How to implement custom URL handler to access JS modal content? [closed]

You could try with javascript, the following logic: On page load check if a hash exist in the url with something like: var hash = decodeURIComponent(location.hash.substr(1)); Then you would have two tables (one for team and one for advisors) with names matching the urls of your modals (e.g.: https://greentec-capital.com/team/peter-grouev/) like: var teamHashes = [‘peter-grouev’, ‘erick-yong’]; … Read more

Custom JS doesn’t work after 4.9.9 update [closed]

you do have your menu JS code currently 2 times on the page. in https://www.manufakturamocy.pl/mm/wp-content/cache/minify/b6a70.default.include-body.8cc603.js and in https://www.manufakturamocy.pl/mm/wp-content/themes/mmocy/js/script.js?ver=4.9.9 which causes your menu open and close in the same time. maybe a problem with your cache and JS minify plugin.

How to keep close a sub-menu under homepage? [closed]

To do that, you have to set hidden attribute to the sub menu. CSS #wrapper .fusion-vertical-menu-widget.left .menu .sub-menu { display: none; } to toggle display on the menu on hover over servizi, you can add jQuery hover to the menu item. jQuery var subMenu = jQuery(“#wrapper .fusion-vertical-menu-widget.left .menu .sub-menu”); jQuery(“#menu-item-12049”).hover(function(){ subMenu.show(); }, function(){ subMenu.hide(); }); … Read more