Making your theme widget-aware is not difficult at all. I see your theme is an older theme (pre-WordPress 2.0). First create a new file called functions.php and insert the following …
<?php
if ( function_exists(’register_sidebar’) )
register_sidebar();
?>
Take care not to include any spaces before or after the opening/closing php tags. Upload the file to your theme’s folder. Next, open up sidebar.php and directly after the opening <ul> tag insert the following …
<?php if ( !function_exists(’dynamic_sidebar’)
|| !dynamic_sidebar() ) : ?>
Scroll down further and and just before the closing </ul> tag insert the following …
<?php endif; ?>
Be advised that most themes are designed such that the sidebar is contained within an unordered list. If your theme is not (and I suspect it isn’t) you’ll need to have a look at these instructions …
http://automattic.com/code/widgets/themes/
Scoll down to the heading –> My sidebar isn’t a list. What do I do?
Or, you can get an updated and widget-aware version of that theme here,
http://www.troublezone.net/firefox-v2/
Thank you for help,
It is really unordered list , I do the steps you told me but the problem is when I upload the file Functions.php to the right directory I could not see it in the theme editor. I tried for along time but till now I could not see the file.
ps: I use Fireftp, and when I finish the file transfare I see it in the website folders in the current directory.
Thank you.
functions.php should be start with a small F not capital.
All it needs inside it is this:
<?php
if ( function_exists(’register_sidebar’) )
register_sidebar();
?>
As suggested above.
Then edit your sidebar.php to include the new sidebar as above.
Thank you,
I have just found it, it was already small f.
After I found the file, I continue working with the next step.
After each Unordered List opining tag I added the code:
<?php if ( !function_exists(’dynamic_sidebar’)
|| !dynamic_sidebar() ) : ?>
and before the end tag of the Unordered List I insert the code:
<?php endif; ?>
I save the file sidebar.php. and go to the Widget subtab under the Design tab, but it still says that “No Sidebars Defined”.
Anybody can help please.
ps: I may give the login and the password of my blog if someone is able to do it for me.
Thank you.
Hi Ibrahim.
Got your email. As I said in my reply I’m extremely busy with work the last couple of months (which is why I haven’t been very active here in the forum) but I’ll see what I can do for you. You can contact me off-forum again if you wish.