How to find which plugin is outputting Open Graph tags to
Do a search inside: var_dump( $GLOBALS[‘wp_filter’][‘wp_head’] ); Then just do a crossfile search for the attached callbacks.
Do a search inside: var_dump( $GLOBALS[‘wp_filter’][‘wp_head’] ); Then just do a crossfile search for the attached callbacks.
This is a wild guess, because you didn’t provide (parts of) your template. Anyway, most probably (if lessons.php is a full template) there is get_header(); somewhere at the beginning of your template file. If you put the very code you posted in your question before this it will render, as the wp_head action is still … Read more
The blank lines are probably being generated by code that is hooked to the wp_head action. Generally speaking this is not a big deal as it won’t affect the way your page is displayed in a browser. There are some downsides like the size of the HTML document that is transmitted, but this can be … Read more
You can use first few lines of post content and add these to meta description tags to website head section automatically. Here is how you do that. // add meta description tag function wcs_add_meta_description_tag() { global $post; if ( is_single() ) { $meta = strip_tags( $post->post_content ); $meta = strip_shortcodes( $post->post_content ); $meta = str_replace( … Read more
Your code does seem ok, so it is hard to guess why are you not getting expected result. One thing to note is that WordPress ships with its own copies of Backbone and Underscore, it is considered a good practice to use its copies in such case. The scripts you don’t “need” are likely coming … Read more
Looks like the source of my problem is a function called admin_bar_bumpin wp-includes>admin-bar.php. It’s for the admin bar and when I log out it goes away so it wasn’t effecting the style of the site for logged out users. I was able to filter it out in my functions.php file. That’s actually no better than … Read more
The title is probably placed within the header.php file. So openup and find something like: <h1><a href=”https://wordpress.stackexchange.com/questions/187487/<?php bloginfo(“url’);?>”><?php bloginfo(‘name’);?></a></h1> This is what displays Abraham & Co on your website. Now first of you need your image uploaded to you images folder in the theme folder.Add the following code BEFORE the code above: <img src=”https://wordpress.stackexchange.com/questions/187487/<?php bloginfo(“template_directory’);?>/images/your-logo.png”> … Read more
How can I make this code to display the meta tags at the top of the header section right after ? You probably can’t. Typically wp_head() is called at the end of the </head> section, but that is theme dependent. You don’t have any control. How can I put each meta tag on a separate … Read more
Can we think litter bit different way: add_action(‘wp_head’,’new_wp_head’); function new_wp_head() { echo “calling wp_head”; global $civicrm_root; if ( empty( $civicrm_root ) ) { return; } $region = CRM_Core_Region::instance(‘html-header’, FALSE); if ( $region ) { echo ‘<!– CiviCRM html header –>’; echo $region->render( ” ); } } Make sure in which file you put this and … Read more
I have this code within a plugin and I want to grab the ID of the custom post being showed: … “here” is in the same file that classes are created in the main file of the plugin: class Product { } $x = new Product($id); //here You can’t do that. The “custom post being … Read more