How do I change the description of the same image which is to be found in multiple instances?

Plugin idea #1 When we insert an image into the editor, the plugin automatically modifies the caption and the alt attribute to: Then on the front-end the image caption is fetched for the corresponding image attachment, based on the attachment_729 string and replaces the ###ALT### and ###CAPTION### dummy values. So when we want to modify … Read more

How to solve a conflict between a plugin and a theme?

If the theme was coded using Theme Development Standards, then you can use the function wp_deregister_script to remove conflicting scripts from the page where the slider is being used. [update] The original solution (at the bottom) worked in a specific plugin situation (with WP Touch). I think this is the proper one: add_action( ‘wp_enqueue_scripts’, ‘wpse_77772_remove_theme_enqueues’, … Read more

W3 Total Cache active but not working [closed]

mod_deflate: Not detected (required for Page Cache (enhanced mode) and Browser Cache) mod_env: Not detected (required for Page Cache (enhanced mode) and Browser Cache) mod_expires: Not detected (required for Page Cache (enhanced mode) and Browser Cache) mod_headers: Not detected (required for Page Cache (enhanced mode) and Browser Cache) mod_mime: Not detected (required for Page Cache … Read more

get_template_directory_uri() and other URL tags not working in theme

What you have: <link rel=”stylesheet” href=”https://wordpress.stackexchange.com/questions/46261/<?php echo get_template_directory_uri(); ?>/css/style.css”> should work fine. I’ve copied and pasted into my header.php and it worked. But this is not how you should be including css or javascript files. The proper way is to use the wp_enqueue_scripts hook. For instance, say you have javascript file you wish to load … Read more

Easy code troubleshooting in wordpress

The best way to troubleshoot/debug your PHP code for WordPress is to use the XDEBUG debugger for PHP coupled with an IDE/editor that can leverage XDEBUG. By far my favorite IDE for PHP/XDEBUG is PhpStorm (best money I have ever spent), but you can use for free on the bleeding edge with their EAP (Early … Read more