Support » Themes and Templates » Removed code from header, now no keywords showing

  • Hi,

    I use the Academica theme for my site I also have Yoast WordPress SEO installed.

    A few days ago I posted a request for what code to remove from my header to avoid duplicate meta descriptions from appearing in search engine listing.

    After some advice, the following code was removed

    <title><?php wp_title(''); ?><?php if(wp_title('', false)) { echo ' | '; } ?><?php bloginfo('name'); if(is_home()) { echo ' | '; bloginfo('description'); } ?></title>
    <?php if (is_single() || is_page() ) : if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
    <meta name="description" content="<?php the_excerpt_rss(); ?>" />
    <?php csv_tags(); ?>
    <?php endwhile; endif; elseif(is_home()) : ?>
    <meta name="description" content="<?php bloginfo('description'); ?>" />
    <?php endif; ?>

    and replaced with

    <title><?php wp_title(''); ?></title>

    This resolved the issue, but now I find that I have no keywords appearing in the header information. While I am aware that Google does not pay too much attention to keywords, I believe that other search engines do. Therefore, I am wondering if I can reinstate a line or several lines of the original code to return the keyword information to the header.

Viewing 2 replies - 1 through 2 (of 2 total)
  • <?php csv_tags(); ?> is what you need to put back in for the keywords. Read here for more info.

    Many thanks for your response. I’ve read the linked article in your reply, and am aware that I shouldn’t get too hung up on keywords, but I still would like to reinstate them as I feel the code needed to enable the same information in tags is beyond me at this point.

    So, I placed the line you recommended back into the header as below.

    <title><?php wp_title(''); ?></title>
    <?php csv_tags(); ?>

    The meta tags are still not showing up, I either see nothing or a comma “,” as the keyword on each page. I’ve tried deleting the cache on the browser and WordPress, and reloading sample webpages, but the original keywords that are still found in each page’s Yoast SEO section are not showing up.

    Site is

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Removed code from header, now no keywords showing’ is closed to new replies.