SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Member
    Join Date
    Sep 2007
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Wordpress Blogs SEO - Please Help

    I recently got some advice on how to optimize my wordpres blog, as I'm not very technical there are some things I'm not sure about, could you guy's help me please?

    Here's what I need to know...

    Something called the excerpt function, this is to stop the same content appearing on two pages, I was told to "Replace the_content with the_excerpt in archives, categories, and index. "thecontent" should only exist on single and page"

    I don't have a clue on how to do this, I use cpanel file manager, can anyone tell me how to do it in non-tech speak?

    I was also told to ditch my standard archives system and replace it with the clean archives plugin, however, the link does not work (http://sporadicnonsense.com/index.ph...chives-plug-in) is there another way to get it?

    I created a google sitemap using the sitemap generator plugin, do I need to place a link to the map on my homepage or is it ok just as it is?

    Also, a couple of other things while I'm here, I installed adsense-deluxe plugin but for some reason the adsense is not displaying correctly - look here - homeremedyto.com
    Anyone know why?

    Plus, if you click on the archives link at the top of the blog, it returns an error msg, that is the way it was from when I installed it, not sure if there's a problem with the theme or if I need to do something?

    Thanks a lot

  2. #2
    Programming Team silver trophybronze trophy
    Mittineague's Avatar
    Join Date
    Jul 2005
    Location
    West Springfield, Massachusetts
    Posts
    17,250
    Mentioned
    196 Post(s)
    Tagged
    2 Thread(s)

    hacking WordPress

    It can be relatively easy to hack WordPress files. And easy to mess up.
    What I do is never remove exiting code, but comment it out and add any replacement code.
    1. Go to the cPanel's file manager
    2. navigate to the blogs folder
    3. You should see at least 3 folders and several files
    4. Inside the wp-content folder find a folder named themes
    5. Inside this folder are at least your blog's theme folder. Hopefullly it will be named something recognizable as your blog's theme.
    6. Inside this folder are several files, including the 3 you mentioned
    7. Save a copy of each file you alter, possibly rename it too. eg. OLD index
    8. Open each file iin a plain text editor (notepad OK, Word is asking for troubles) You wil see HTML and PHP code.
    9. look for instances of the string "<?php the_content(); ?>"
    10. Comment that out and add replacement line. ie
      <!--
      <?php the_content(); ?>
      -->
      <?php the_excerpt; ?>
    11. Save the new file in the same folder.
    12. You're done

    I don't know if this will do what you hope. Test the pages and see. If you're happy, then great, if not, rename the new files eg. BADindex.php and change OLDindex.php back to index.php
    If you look there might be a plugin that does this without requiring hacking the pages.

    Plugins can be tricky. Some work with certain versions of WordPress, some are icompatable with certain themes or other plugins.

    AFAIK Google can find the file (like it finds robots.txt ?) but you might want to submit it too.

    Would the link problem have to do with your permalink settings?

  3. #3
    SitePoint Member
    Join Date
    Sep 2007
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey,

    Thanks for your reply, I think I know what you mean about "commenting out" the code, is the <!-- and --> the part that comments it out?

    That's good about google finding the map, I'll just leave it as is then.

    The link problem might be to do with my permalink settings, I did change them and don't think I tested out the archives link, the thing is thought that the other two links still work fine.

    Thanks for your help

  4. #4
    Programming Team silver trophybronze trophy
    Mittineague's Avatar
    Join Date
    Jul 2005
    Location
    West Springfield, Massachusetts
    Posts
    17,250
    Mentioned
    196 Post(s)
    Tagged
    2 Thread(s)

    comments

    There are different ways to add comments to files. For HTML, when the browser sees "<!--" it considers everything up to "-->" as a comment (still visible in view-source but not rendered). For PHP you can comment several ways. When the PHP parser sees either "//" or "#" it considers everything after that up to the end of the line as a comment. It also considers everything between "/*" and "*/" as a comment. PHP comments are not parsed, and so will not be visible in view-source or be rendered. Depending on your preference you could use something like
    HTML Code:
    <!-- Original line
    <?php the_content(); ?>
    -->
    <?php the_excerpt; ?>
    HTML Code:
    <!-- Original line -->
    <?php # the_content(); ?>
    <!-- New line -->
    <?php the_excerpt; ?>
    HTML Code:
    <!-- Original line -->
    <?php // the_content(); ?>
    <!-- New line -->
    <?php the_excerpt; ?>
    or
    HTML Code:
    <!-- Original line -->
    <?php /* the_content(); */ ?>
    <!-- New line -->
    <?php the_excerpt; ?>


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •