I have managed to set up a different dynamic sidebar for each category on my site using the code below, but I need the individual posts in each category to show that sidebar too which this code doesn’t do.
Can someone please add the necessary syntax so it does just that (and insert it in the snippet where it needs to go)
Here is the code…
$sidebar_id = ( is_category() ) ? sanitize_title( get_cat_name( get_query_var( 'cat' ) ) ) . '-sidebar' :
'sidebar';
dynamic_sidebar( $sidebar_id );
Thanks in advance.
(Theme is 2012 default)
My widgets on my blog are down the bottom of the page rather than further up near the header image. How can I move them up to sit just beneath the header on the right hand side?
https://www.marielledavis.com/blog/
]]>I am not a programmer, nor do I know much code, but I know my way around a computer and will learn what I need to in order to get this fixed. I assume it’s something in the sidebar code – I’m just not sure where to find that or what to change when I get there.
I’m sure it’s really simple – please help! Advice is much appreciated.
]]>I installed the free shaken & Grid template which is brilliant, however there was a couple of things I want to change.
I worked out how to add the comments section to the site by reading this forum, but I want to add the side bar to the main page.
So I added this code to the main template
‘
<?php get_sidebar(); ?>
</div><!– #page –>
</div><!– #wrap –>’
Which made the side bar appear but none of the links or widgets work.
I have spent ages trying to work this out so anyhelp would be really appreciated!
Thanks
Ad
]]>I want to use wordpress for our company website that will have content about our company (services, about, contact, etc) that can be edited by several coworkers using the wp interface as well as typical blog content on a specific page of the site. What I am attempting to do is to have a main content section on each displayed page and a sub content section that is generated by the currently viewed page.
you can view the website that is being converted over here (currently static):
smkazoo.com
and an image of what I am trying to do here:
https://dev.kalkleen.com/V8/explanation.jpg
So in summary I would like a content editor to be able to create a post that will appear on a specific page (i have that part working via setting each link in the navigation to go to a category) but then by creating another post having secondary content show up where the sidebar is (possible by using a loop that gets the category name and then add a post that has a sub category named something else). Finally under the blog page having the normal sidebar content (archives, search, etc).
I hope that makes sense.
Merry Christmas,
Thanks!
]]>If you have a suggestion it would be greatly appreciated.
]]>Here’s what I have right now:
<div id="primary" class="sidebar">
<?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar(1) ) : // begin primary sidebar widgets ?>
<h3><?php _e( 'Pages', 'sandbox' ) ?></h3>
<?php wp_list_pages('title_li=&sort_column=menu_order' ) ?>
<h3><?php _e( 'Categories', 'sandbox' ) ?></h3>
<?php wp_list_categories('title_li=&show_count=0&hierarchical=1') ?>
<h3><?php _e( 'Archives', 'sandbox' ) ?></h3>
<?php wp_get_archives('type=monthly') ?>
<?php endif; // end primary sidebar widgets ?>
</div><!-- #primary .sidebar -->
<div id="secondary" class="sidebar">
<?php if ( !function_exists('dynamic_sidebar') || !dynamic_sidebar(2) ) : // begin secondary sidebar widgets ?>
<h3><label for="s"><?php _e( 'Search', 'sandbox' ) ?></label></h3>
<form id="searchform" class="blog-search" method="get" action="<?php bloginfo('home') ?>">
<div>
<input id="s" name="s" type="text" class="text" value="<?php the_search_query() ?>" size="10" tabindex="1" />
<input type="submit" class="button" value="<?php _e( 'Find', 'sandbox' ) ?>" tabindex="2" />
</div>
</form>
<?php wp_list_bookmarks('title_before=<h3>&title_after=</h3>&show_images=1') ?>
<h3><?php _e( 'RSS Feeds', 'sandbox' ) ?></h3>
<a href="<?php bloginfo('rss2_url') ?>" title="<?php printf( __( '%s latest posts', 'sandbox' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" rel="alternate" type="application/rss+xml"><?php _e( 'All posts', 'sandbox' ) ?></a>
<a href="<?php bloginfo('comments_rss2_url') ?>" title="<?php printf( __( '%s latest comments', 'sandbox' ), wp_specialchars( get_bloginfo('name'), 1 ) ) ?>" rel="alternate" type="application/rss+xml"><?php _e( 'All comments', 'sandbox' ) ?></a>
<h3><?php _e( 'Meta', 'sandbox' ) ?></h3>
<?php wp_register() ?>
<?php wp_loginout() ?>
<?php wp_meta() ?>
<?php endif; // end secondary sidebar widgets ?>
</div><!-- #secondary .sidebar -->
I thought I’d gotten rid of every “ul” and “li” tag and that needed to go, but here’s the result:
https://onethousandseas.org/testpage
So yeah, as I intended some of them don’t have bullet points, namely the headings, and some of them do. What can I do to get rid of them?
Thanks.
]]>