This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| let result = Array.from( document.querySelectorAll("h3.section-title") ) | |
| .map( (title) => title.textContent.trim()).join("\n"); | |
| copy( result ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Paste this code in a file inside your child theme's folder: /js/custom.js | |
| jQuery(function($) { | |
| alert( php_data.message ); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // Place this code in your child theme's functions.php file | |
| function myprefix_enqueue_scripts() { | |
| wp_enqueue_script( | |
| 'custom-script', | |
| get_stylesheet_directory_uri() . '/js/custom.js' | |
| ); | |
| wp_localize_script( 'custom-script', 'php_data', array( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function(){ | |
| window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)};ga.l=+new Date; | |
| ga('create', 'UA-XXXXX-Y', 'auto'); | |
| ga('send', 'pageview'); | |
| var s = document.createElement('script'); | |
| s.setAttribute('async', true); | |
| s.setAttribute('src', 'https://www.google-analytics.com/analytics.js'); | |
| var $head = document.getElementsByTagName('head'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ | |
| (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), | |
| m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) | |
| })(window,document,'script','https://www.google-analytics.com/analytics.js','ga'); | |
| ga('create', 'UA-XXXXX-Y', 'auto'); | |
| ga('send', 'pageview'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!-- Google Analytics --> | |
| <script> | |
| window.ga=window.ga||function(){(ga.q=ga.q||[]).push(arguments)};ga.l=+new Date; | |
| ga('create', 'UA-XXXXX-Y', 'auto'); | |
| ga('send', 'pageview'); | |
| </script> | |
| <script async src='https://www.google-analytics.com/analytics.js'></script> | |
| <!-- End Google Analytics --> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!-- Google Analytics --> | |
| <script> | |
| (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ | |
| (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), | |
| m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) | |
| })(window,document,'script','https://www.google-analytics.com/analytics.js','ga'); | |
| ga('create', 'UA-XXXXX-Y', 'auto'); | |
| ga('send', 'pageview'); |