SitePoint Sponsor

User Tag List

Results 1 to 9 of 9
  1. #1
    SitePoint Member
    Join Date
    Oct 2012
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Help with widget headings

    Hi all,

    I'm new to wordpress and work in SEO where I am also fairly new, so I'm still getting used to the ropes. I have a issue which I can't seem to find a solution too and the wordpress support forums seem pretty poor. So hopefully someone can help me out, I'm also likely to come back for more advice in the future if this is the case

    I have several widgets active on the right side of my website, and they are appearing as h2 something I don't want them to be, hes a picture showing what I mean. As I am aware having too many headings can be bad for SEO.

    http://postimage.org/image/cqu5amfxx/
    My website is, www.home24.co.uk

    I hope this is not breaking any rules I'm just really struggerling with finding some basic help for a poor intern, if I am indeed breaking the rules I apologise in advance!

  2. #2
    From Italy with love silver trophybronze trophy
    guido2004's Avatar
    Join Date
    Sep 2004
    Posts
    9,495
    Mentioned
    161 Post(s)
    Tagged
    4 Thread(s)
    Welcome to the SP forums.

    I googled a bit and found this: http://wordpress.org/support/topic/c...rapper-to-span
    It is 4 years old, so some things might have changed in the current WP version, but it's a start

  3. #3
    SitePoint Member
    Join Date
    Oct 2012
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    So I still can't get i to work, I can't find the widget coding in the editor anywhere.
    Any ideas?

    Here is an example of the code for one of the headings on the right hand side, this was seen using a chrome extension.

    Code:
    <li id="text-4" class="widget widget_text">
    <h2 class="widgettitle">Everything you need to know about online shopping</h2>

  4. #4
    From Italy with love silver trophybronze trophy
    guido2004's Avatar
    Join Date
    Sep 2004
    Posts
    9,495
    Mentioned
    161 Post(s)
    Tagged
    4 Thread(s)
    Quote Originally Posted by chris-at-HOME View Post
    I can't find the widget coding in the editor anywhere.
    What editor?

  5. #5
    SitePoint Member
    Join Date
    Oct 2012
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Wordpress Appearance editor? I'm sure its an easy fix I'm just quite poor when it comes to this.

  6. #6
    From Italy with love silver trophybronze trophy
    guido2004's Avatar
    Join Date
    Sep 2004
    Posts
    9,495
    Mentioned
    161 Post(s)
    Tagged
    4 Thread(s)
    Open the editor.
    In the list of template files on the right choose Theme Functions (functions.php).
    Inside the code, do a search for register_sidebar, and change the code in the lines
    PHP Code:
    'before_title' => '<h4 class="widget-title">',
    'after_title' => '</h4>'
    Then update the file.
    Done.

    I had h3 there, and changed it to h4. It works perfectly fine.

    Edit: you will loose the change if you ever update the theme you're using, unless you created a child theme and made the change there.
    Start here if you want to know more about child themes: http://codex.wordpress.org/Child_Themes

  7. #7
    SitePoint Member
    Join Date
    Oct 2012
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi, so I only have this in my theme funtions template file, strange?

    Code:
    <?php
    if ( function_exists('register_sidebars') )
        register_sidebars(3);
    ?>

  8. #8
    From Italy with love silver trophybronze trophy
    guido2004's Avatar
    Join Date
    Sep 2004
    Posts
    9,495
    Mentioned
    161 Post(s)
    Tagged
    4 Thread(s)
    Ok, change that in
    PHP Code:
    <?php
    if ( function_exists('register_sidebars') )
        
    register_sidebars(3, array('before_title'=>'<h4>','after_title'=>'</h4>'));
    ?>
    Change h4 in whatever you want it to be.

    Of course, you might have to add something to your css file to style the new widget titles.

    Edit: take a look at the manual: http://codex.wordpress.org/Function_...ister_sidebars
    Last edited by guido2004; Oct 11, 2012 at 05:54. Reason: added link

  9. #9
    SitePoint Member
    Join Date
    Oct 2012
    Posts
    5
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks guido! It worked

    I'm sure you will be seeing more of me on here as time goes by, hopefully i'll be an expert one day...


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
  •