pdxsherpa — 2013-02-15T11:06:14-05:00 — #1
I am working on a wp theme. first time really, rather than to start from absolute nothing (that'd be the next try)...
Grabbed a very simple super minimalist template (thanks to zenhabits.org). And for example, wanted to add a sidebar to it.
so in the index.php I added.
the get_sidebar(); function
I do have a sidebar.php in the correct directory.
but get this error msg.
"Fatal error: Call to undefined function responsive_widgets() in C:\xampp\htdocs\wordpress\wp-content\ hemes\zh2\sidebar.php on line 5"
where do I add/specify functions? is the wp-includes>functions.php the best place?
deadmix — 2013-02-15T16:01:59-05:00 — #2
you have to add it on functions.php
but my question do you have already a sidebar on this theme and you want to add another Extra one !?
pdxsherpa — 2013-02-15T19:08:29-05:00 — #3
Hi deadmix, thanks for the pointer!
actually there wasn't i was trying to add it. But about after 1/2 an hour gave up that theme & template and startead from even nearer scratch using a series of tutorials on youtube.
much better. Got the sidebar.
would like eventually to find out how to add more than two columns, rigth now just have the main body & the sidebar. that can be the next project & am open to advice.
is there a diff tag for that?
deadmix — 2013-02-17T11:52:59-05:00 — #4
You can add another sidebar by creating a new sidebar2.php file and add it to the theme, find the <?php include("sidebar.php"); ?> and just under it add : <?php include("sidebar2.php"); ?>
if ( function_exists('register_sidebar') )
We are adding another sidebar so change the (2) to a (3)...
pdxsherpa — 2013-02-18T11:11:35-05:00 — #5
thank you will go try it out today!