WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] making sidebar widget-ready (finestripes theme) (8 posts)

  1. zszalbot
    Member
    Posted 6 years ago #

    Hello,

    I'd like to ask for your help in customizing finestripes theme (from themes section) which I really like and would like to continue using it. WordPress tells me it is not widget-aware theme.

    Here's the theme source. How do I make it widget-ready?

    <div id="right">
    <div id="sidebar">
     <ul>
    
      <li><h2><?php _e('Pages'); ?></h2>
      <ul>
        <?php wp_list_pages('sort_column=menu_order&title_li='); ?>
      </ul>
      </li>
    
      <li><h2><?php _e('Categories'); ?></h2>
       <ul>
        <?php list_cats() ?>
       </ul>
      </li>
    
     <li><h2><?php _e('Archives'); ?></h2>
     	<ul>
    	 <?php wp_get_archives('type=monthly'); ?>
     	</ul>
     </li>
    
    <li><h2><?php _e('Links'); ?></h2>
    <ul>
    <?php get_links('-1', '<li>', '</li>', ' ', TRUE, 'url', FALSE); ?>
    </ul>
    </li>
    
    <li><h2>Search</h2>
    <form id="searchform" method="get" action="<?php echo $PHP_SELF; ?>">
    <input type="text" name="s" id="search" size="15" maxlength="20"/><input type="submit" name="submit" id="searchbut" value="Go" />
    </form>
    </li>
    
      <?php /* If this is the frontpage */ if (is_home()) { ?>
      <li><h2><?php _e('Meta'); ?></h2>
       <ul>
        <li><?php wp_loginout(); ?></li>
        <li><a href="http://wordpress.org/" title="<?php _e('Powered by WordPress, state-of-the-art semantic personal publishing platform.'); ?>"><abbr title="WordPress">WordPress</abbr></a></li>
    <li><a href="<?php bloginfo('rss2_url'); ?>" title="<?php _e('Syndicate this site using RSS'); ?>"><?php _e('<abbr title="Really Simple Syndication">RSS Feed</abbr>'); ?></a></li>
        <li><?php wp_meta(); ?></li>
       </ul>
      </li>
    <?php } ?>
    
     </ul>
    </div><!-- Closes the sidebar div-->
    </div><!-- Closes the rightcolumn div-->

    Many thanks in advance!

    zbigniew szalbot

  2. Jeremy Clark
    Moderator
    Posted 6 years ago #

    You need to edit your side bar. Here are some instructions on how to edit it.

  3. zszalbot
    Member
    Posted 6 years ago #

    Thank you Jeremy - I did see that page before. let me show what I did.

    I added this to the bottom of functions.php

    <?php
    if ( function_exists('register_sidebar') )
        register_sidebar();
    ?>

    and also modified finestripes theme like this:

    <div id="right">
    <div id="sidebar">
    <ul id="sidebar">
    <?php if ( !function_exists('dynamic_sidebar')
            || !dynamic_sidebar() ) : ?>
      <li id="about"><h2><?php _e('Pages'); ?></h2>
      <ul>
        <?php wp_list_pages('sort_column=menu_order&title_li='); ?>
      </ul>
      </li>
    
      <li id="links"><h2><?php _e('Categories'); ?></h2>
       <ul>
        <?php list_cats() ?>
       </ul>
      </li>
    
     <li id="links"><h2><?php _e('Archives'); ?></h2>
     	<ul>
    	 <?php wp_get_archives('type=monthly'); ?>
     	</ul>
     </li>
    
    <li id="links"><h2><?php _e('Blogrolls'); ?></h2>
    <ul>
    <?php get_links('-1', '<li>', '</li>', ' ', TRUE, 'url', FALSE); ?>
    </ul>
    </li>
    
    <li id="search"><h2>Search</h2>
    <form id="searchform" method="get" action="<?php echo $PHP_SELF; ?>">
    <input type="text" name="s" id="search" size="15" maxlength="20"/><input type="submit" name="submit" id="searchbut" value="Go" />
    </form>
    </li>
    <li id="tags"><h2>Tags</h2>
    <?php STP_Tagcloud(); ?>
    </li>
    
      <?php /* If this is the frontpage */ if (is_home()) { ?>
      <li id="links"><h2><?php _e('Meta'); ?></h2>
       <ul>
        <li><?php wp_loginout(); ?></li>
        <li><a href="http://wordpress.org/" title="<?php _e('Powered by WordPress, state-of-the-art semantic personal publishing platform.'); ?>"><abbr title="WordPress">WordPress</abbr></a></li>
    <li><a href="<?php bloginfo('rss2_url'); ?>" title="<?php _e('Syndicate this site using RSS'); ?>"><?php _e('<abbr title="Really Simple Syndication">RSS Feed</abbr>'); ?></a></li>
        <li><?php wp_meta(); ?></li>
       </ul>
      </li>
    
    <?php } ?>
    
    <?php endif; ?>
    
     </ul>
    </div><!-- Closes the sidebar div-->
    </div><!-- Closes the rightcolumn div-->

    but when I click Presentation > Widgets, I get:
    You are seeing this message because the theme you are currently using isn’t widget-aware, meaning that it has no sidebars that you are able to change. For information on making your theme widget-aware, please follow these instructions.

    Where did I go wrong?

    Thank you!

    zbigniew szalbot

  4. Jeremy Clark
    Moderator
    Posted 6 years ago #

    Try swithing this

    <?php } ?>
    
    <?php endif; ?>

    To this

    <?php endif; ?>
    
    <?php } ?>
  5. zszalbot
    Member
    Posted 6 years ago #

    Thank you for your post. I did change the order of the two entries but to no avail. Any other suggestion? Thank you!

    Actually I was wrong. When I changed the order, I had no more sidebar in the theme. Changing it back to the previous order restores the sidebar.

    zbigniew szalbot

  6. zszalbot
    Member
    Posted 6 years ago #

    Maybe this Finepress theme is not one that can be converted to being widget-aware? I pasted a default sidebar code from the newest 2.3 WP and it still said that the theme is not widget-aware.

    I got the theme from http://themes.wordpress.net/columns/2-columns/1930/finestripes-10/

    Thank you!

    zbigniew szalbot

  7. Jeremy Clark
    Moderator
    Posted 6 years ago #

    I don't know I just downloaded it and added the same code you did and I can add widgets now. I'm going to zip up the theme again and you can download it from here and try it out.

  8. zszalbot
    Member
    Posted 6 years ago #

    Dear Jeremy,

    How shall I thank you? My mistake was that I hacked functions.php in wp-includes and only having downloaded your zip have I realized that functions.php needs to be created within the theme folder. Well, I really appreciate and thank you very much for your help!!!

    zbigniew szalbot

Topic Closed

This topic has been closed to new replies.

About this Topic