WordPress.org

Forums

Yoast SEO, non-standard theme (7 posts)

  1. figure8
    Member
    Posted 2 years ago #

    Hello,

    We created a very basic WordPress theme from the client's pre-existing static Dreamweaver site. Now the client wants SEO, and we're thinking of using Yoast's SEO plugin to streamline things.

    I read Yoast's documentation on integrating the plugin with a theme and found it to be not what I was looking for. I need to code the theme so that the plugin will fit into it like a puzzle piece. Has anyone ever taken their non-standard theme and made the WordPress SEO plugin to work with it? How did you do it?

    Thank you in advance.

  2. esmi
    Forum Moderator
    Posted 2 years ago #

    Can you define what you mean by a "non-standard WordPress theme"?

    Most plugins - including Yoast's as far ss I know - hook into specific functions that have to be present in the theme's template files - such as wp_title(), wp_head() and wp_footer(). If you don't incorporate these functions in your theme in a standard manner, the plugins simply won't work.

  3. figure8
    Member
    Posted 2 years ago #

    Thanks for your quick response - by non-standard WordPress theme I just mean it was not created to be a versatile theme; it was a patchwork that involved taking their old site and allowing WordPress to be used as the CMS for editing page content, adding pages, etc. There's no functionality for Posts or widgetized sidebars.

    Has anyone ever been able to use Yoast's WordPress SEO successfully on a custom theme like this?

    Does anyone know, from experience or theory, the specific functions that I need to be able to hook into for this plugin to work properly?

  4. Requirements for WordPress SEO to work properly.

    1. Calling wp_head() in header.php
    2. Calling wp_footer() in footer.php
    3. Using wp_title() in the title tag. ex: <title><?php wp_title(); ?></title>
  5. figure8
    Member
    Posted 2 years ago #

    Hello, my apologies for being a doubting Thomas, but is that really all that's needed? I'm cautious because (a) I have very little knowledge of PHP and (b) I read someone's horror story about WordPress SEO taking down their site somehow. Thank you for the help, I truly appreciate it.

  6. figure8
    Member
    Posted 2 years ago #

    Update: I have activated WordPress SEO with my custom non-standard theme, and the meta tag function and title functions work well.

    However, the XML sitemap feature appears to be broken. Where it says "You can find your XML Sitemap here," I click the button and get this error:

    "This page contains the following errors:
    error on line 2 at column 6: XML declaration allowed only at the start of the document
    Below is a rendering of the page up to the first error."

    Why would this be occurring?

  7. figure8
    Member
    Posted 2 years ago #

    Does anyone know why the XML sitemap function of WordPress SEO wouldn't work, as described above? That seems, to me, to be one of the more theme-indifferent features; has anyone else had this problem?

Topic Closed

This topic has been closed to new replies.

About this Topic