在 WordPress 增加 jQuery Script

Go to wordpress.org and find the plugin CSS & JavaScript Toolbox, you can also use this link to access the plugin page.

This plugin is regularly updated and comes from a trustworthy developer.

Download the plugin and install it via WordPress admin panel or manually, you will see a new menu item in your WordPress admin panel.

add-jquery-script-to-wordpress-01

  • Open CSS & JavaScript Toolbox.

When you install a new version of CJT for the first time, or if you upgrade from an old one, a number of processes will happen.

The installation process will create CJT database tables, build-it database records.

  • Click Install on the next screen:

add-jquery-script-to-wordpress-02

As soon as installation is finished, you can start working with the plugin.

  • Click the Add New Code Block button, add your block Name, set the Location Hook and Initial Block Position and click the button Create:

add-jquery-script-to-wordpress-03

Now you can add your code and specify where exactly it should work in Auxiliary tab on the right.

Also you can select specific pages, posts , categories, urls using other tabs on the right.

add-jquery-script-to-wordpress-04

If you follow all steps of this mini-guide you'll be able to add the JS script to your WordPress website.

 

 

原文:http://blog.templatemonster.com/2016/05/30/how-to-add-jquery-script-to-wordpress-website/?utm_campaign=TM+Newsletter+maklaud+2016-05-30&utm_medium=email&utm_source=newsletter