adding google event tracking to links in posts

Have a look at this article -> http://www.optimum7.com/internet-marketing/web-development/dynamic-google-analytics-event-tracking-for-wordpress.html Also to get the post title of the particular page. You could use the following jQuery ( Assuming you post title is wrapped in tag ). outbound_post_name = jQuery(‘h1’).html();

jQuery Tree View and wp_list_pages

EDIT: After chatting with AlxVallejo, we came to a solution. Here’s what we talked about: You were not properly using the wp_enqueue_scripts hook and the functions that go along with it, as I informed you these hooks and actions need to be done in functions.php. You also discovered yourself that you were not initializing the … Read more

WordPress 3.6 and Accordion UI issues?

I’m not sure if it’s because “accordion” all of the sudden became a reserved word in wordpress. But once I switched my wp_enqueue_script/wp_register_script handle from accordion to myaccordion – everything worked.

Using multiple versions of jQuery while still calling it like WP likes

I found that it was better for me to use the latest jQuery version (which WordPress loads by default) and to treat the incompatibility issue by modifying the JS plugin files that were incompatible with the latest jQuery version. Note: The reason I chose this solution is because in most cases, JS plugin incompatibility with … Read more

Using jQuery to retrieve customizer value

Use that JQuery code from your question in customizer preview for real time update. Your transport should be set to ‘postMessage’. In your website you can add body class in function.php: function theme_prefix_body_class( $classes ) { if ( get_theme_mod(‘header_fixed’, 0 ) == true ) { $classes[] = ‘fixed-header’; } return $classes; } add_filter( ‘body_class’, ‘theme_prefix_body_class’ … Read more

Change header image loaded by jQuery to use HTTPS

Have you considered Protocol Rewriting? The code below will convert all http: and https: to // for each script, link, base, and image. Place this in your functions.php: add_action( ‘plugins_loaded’, ‘wpse_232287_init’ ); function wpse_232287_init() { // Initiate the function ob_start( ‘wpse_232287_remove_http’ ); } function wpse_232287_remove_http( $buffer ) { // Check for a Content-Type header, only … Read more