Let's say I'm doing a site about cars, and in the main content area there are a few paragraphs about a particular car.
In the sidebar, are several standard widgets. But I also want a widget with an 'info panel' about the particular car.
So what's the sanest way of putting in a per-page widget in Wordpress? I guess ideally the info-panel could be entered via the standard page editing in Wordpress. (or is this something a plug-in already covers?)
Widget Logic plugin:
http://wordpress.org/extend/plugins/widget-logic/
Another Option would be to download and install the Graceful Sidebar Widget. This plugin enables you to create a sidebar that with content specific to each page or post. You specify the sidebar content right inside the post edit screen. Hope this helps!
Enjoy!
Mike
Related
I have created one website by WordPress. I have one sidebar that I want apply to several pages. I read a lot of tutorials but I could not find any solutions? How can I do this??
Solution 1
Modify your theme - create custom page template and register new sidebar. It's pretty well documented on WordPress.org
Page templates
Sidebars
Solution 2
If you are not WP developer, this is simper and more user friendly solution for you.
Install Widget Logic plugin.
Add widgets to sidebar via WordPress administration.
Click on widget and specify conditions. For example you can restrict displaying of widget for pages in specific category: is_category(array(5,9,10,11))
For more condition examples read Widget Logic - Other notes section
If you are using avada theme you don't need to do anything, there is already option available for selecting sidebar on any page, so you can choose one sidebar for many page you wish.
If you didn't find Fusion Page Options in edit page screen than you have check your screen options.
I'm in the process of trying to create a custom theme for Wordpress and managed to create a working widget area. But for the purpose of this theme, I would like to allow only one "Text-Widget" to be used. How would I go about limiting this?
Be specific about what you want to ask. Wordpress don't limit widgets you can use as much text widget.
Can you provide urls so we could advice a solution to you?
I'll update the code below to be compatible with your theme if you can give a url to your blog.
WordPress don't allow you to limit the number of widgets but you can use javascript to hide the next sidebar items.
$('.sidebar li:gt(0)').hide();
the 2nd list item onwards will be hidden.
and yeah, this is a bit of cheating though.
SEO wise the next widgets are still visible.
I am a newbie in wordpress and I was given the opportunity to edit a certain plugin which is MarketPress, but then I had hard times dealing with it since I'm new to this thing and I don't know where exactly to go, I would want to edit an included dynamic_sidebar but I can't the file on where to edit this. Please help me. :(
Thanks.
Not sure of your level of understanding so forgive me if this is over-simplistic.
The sidebar content is driven by widgets, which is controlled from the Widgets admin panel. The only thing about a sidebar that you should be able to edit by messing with its definition are the wrapping markup for the whole widget and for the title, along with the sidebars name and description. The last two only effect text that shows up in the admin Widgets panel.
However what I describe above is not found with the dynamic_sidebar() method, rather with the register_sidebar() or register_sidebars() methods. These 'define' the name and settings for a sidebar. The dynamic_sidebar() method is the used to implement the sidebar by passing it that sidebars name.
The sidebar is then populated with widgets via the admin Widgets panel.
Typically sidebars are registered from within the functions.php file of a theme, but if a plugin contains templates there no reason why it couldn't also have its own sidebars. As for where the register_sidebar() function is being used in your plugin specifically, I couldn't say. Just search through it using whatever IDE you like, or grep if your comfortable with it.
Hope this helps.
I want to add a widget in to my theme and it should display only home page. Also user can add different page URL's to the widget through admin panel and added page should be display in home page. Please help me.....
Just register two separate widget areas. One for the home and one for the test of the site. This way you can add different widgets to each section of your site.
http://codex.wordpress.org/Function_Reference/register_sidebars
JohnP's solution works great if you are comfortable getting into the code. If you would rather work only within the Widget admin page, I would recommend using the Widget Logic plugin which allows you to specify where widgets should and shouldn't be displayed. You can find it here: http://wordpress.org/extend/plugins/widget-logic/. For your setup, simply drag the widget into the widget area and in the widget logic text input place the following:
is_home()
By doing so, the widget will only show on the home page. Like I said, JohnP's solution will work, but might be more involved than simply doing this.
I'm making a Wordpress 2.9.2 theme, and I'd like each page to have its own sidebar than can be edited as easily as the page's content. It would be cumbersome to make a different template file for each sidebar. It would also be weird to add a "custom field" containing all the sidebar text, since I wouldn't be able to use the Visual/HTML editor. What I'd like is to have a tag similar to the tag, but instead of delimiting the content to be shown on the front page, it would split the post's content and sidebar. Is this possible? Or is there a better solution?
Make the sidebars widgetized and than use the widget logic plugin, so you can conditionally include widgets on any and all pages.
Doing this lets you utilize the out of the box widgets, which are awesome, and even integrated third party widgets that are just as great.
Also consider this: You widgetize other areas of your site, like your header, which can now use widgets and widget logic. This makes for a more flexible theme.