|
#1
Sep 23, 2009, 06:08 AM
|
|
|
|
1,333 posts · Feb 2009
Wordpress 3.4.1, Atahualpa 3.7.7
|
|
In my right sidebar, I tried to create a widget area. 3 were created (I know about the reason now, from another thread). I decided not to use any of them, and now they just sit there. How can I remove them?
|
#2
Sep 23, 2009, 07:08 AM
|
|
|
|
3,768 posts · Oct 2008
Munich, Germany
|
|
Do you have access to PHPMyAdmin? If so you could delete the row "bfa_widget_areas" in the table "wp_options" of the database of your Wordpress installation.
Or put this at the bottom of functions.php
<?php delete_option("bfa_widget_areas"); ?>
(without <?php and ?> if you put it somewhere between existing <?php and ?>)
surf to one page of your site to have the functions.php be called and processed at least once, then see if the widget areas are gone, then remove that code from functions.php again
After you surf to a blog page again, the widget areas that you have defined somewhere with bfa_widget_areas(...) will be created again, but the old ones that aren't defined anywhere anymore should be gone
|
#3
Sep 23, 2009, 08:40 AM
|
|
|
|
1,333 posts · Feb 2009
Wordpress 3.4.1, Atahualpa 3.7.7
|
|
OK, thank you. I was able to use phpmyadmin and got rid of the row.
Is this going to be fixed in the next version of the theme? I really, really, really need to be able to easily add widget areas in different spots!
|
#4
Sep 23, 2009, 10:48 AM
|
|
|
|
3,768 posts · Oct 2008
Munich, Germany
|
|
I've added a link "Reset Widget Areas" at the top of Theme Options -> Add new widget areas, which when clicked will delete the option "bfa_widget_areas".
With the next front end page view the currently active widget areas are re-created. Basically what you did now by going through PHPMyAdmin (which of course is too much hassle on a daily basis, I agree)
This should be it for the widget area function unless I missed something.
|
#5
Sep 23, 2009, 10:51 AM
|
|
|
|
1,333 posts · Feb 2009
Wordpress 3.4.1, Atahualpa 3.7.7
|
|
Would this reset button remove all of the new widget areas? That seems a bad idea! I might want to remove only one. Or am I not understanding you?
|
#6
Sep 23, 2009, 08:52 PM
|
|
|
|
3,768 posts · Oct 2008
Munich, Germany
|
|
It would delete all but with the very next page view on any of your pages the widget areas that are supposed to be active (because you've put <?php bfa_widget_area(...); ?> in one of the theme option text areas) will be immediately created again, whereas the old ones will not because you're not using the <?php bfa_widget_area(...); ?> code for those anymore.
So effectively it deletes only those that you wanted to delete
It is like a "Refresh or Update Widgets Areas" function
All custom widget areas disappear for 1 single page view and appear again after that. The widgets inside are still there.
Note this is not 1 page view for every visitor, just the 1st pageview after you've hit the "Delete unused custom widgets" link. You could be the one doing that page view, by refreshing one of your pages.
|
#7
Sep 23, 2009, 09:02 PM
|
|
|
|
1,333 posts · Feb 2009
Wordpress 3.4.1, Atahualpa 3.7.7
|
|
Ah. I get it now. Cool!
|
Thread Tools |
Search this Thread |
|
|
Display Modes |
Linear Mode
|
|