Using wp_localize_script with jQuery variables including strings, booleans and integers

set a jquery value via wp-localize-script

The use of wp_localize_script is an API in WordPress is to retrieve PHP values from the database to use in javascript/jquery scripts, it can also be utilized to make string values language translatable if required, but also used to pass user defined variables/settings say from a plugin to load via a jQuery init file for a jQuery plugin. By…

Read More