how to embed a crop feature for cropping images uploaded by the user
how to embed a crop feature for cropping images uploaded by the user
how to embed a crop feature for cropping images uploaded by the user
Losing Session ID and sessionStorage when navigating to other domains on Multisite
WordPress Ajax send response on every iteration of a loop
Removing ‘woocommerce-no-js’ class from body
In theme options there is usually an area to put that as well. Maybe under advanced. Look around in the theme options section, not just wordpress options.
To get the editor content as a string in the classic editor use this: content = tinymce.activeEditor.getContent(); Taken from https://stackoverflow.com/a/5843951/57482 Note that you should use the APIs provided rather than directly modifying the DOM if you want to modify the content. If you don’t, you won’t update plugins local states in javascript causing problems. Modifying … Read more
Just in case someone with the same problem faces this question; the best solution I’ve currently found is the use of the @type doc tag instead, so you would write something like: /** * @param word – Word used as the greeting * @return {void} * @type {(word : string) => void} */ function sayHiThere( … Read more
The answer for me was setting the X-WP-Nonce with the wpApiSettings.nonce in the headers.
Rather than trying to include jquery with your javascript, you should use wordpress to define jQuery as a dependency to your custom script. function custom_js_script_enqueue(){ wp_enqueue_script( ‘mycustomjs’, CHILD_THEME_URI . ‘/assets/js/my-custom-js.js’, array(‘jquery’), ‘1.0.0’ ); } add_action(‘wp_enqueue_scripts’, ‘custom_js_script_enqueue’); you can read about all of the libraries available in wordpress here. Your script should not include the jquery … Read more
I don’t want Ajax request to be sent every 2 seconds. Is there a way to send me a notification only if the database changes in a certain meta? You can’t watch the database for changes like this. The most you could do is add filters on post meta changes on the PHP side to … Read more