Welcome! To use this support forum, please Login or Join Today!

   

Manually set siderbar in template?

{name}
RankRank

Total Posts: 49

Joined 2012-01-06

PM

 

I am using a plugin that uses a custom post type but it does not allow setting the features that can normally be set for a post or category. It is all hidden.

I can create an template file and have copied the single post file into my child theme but it is showing the sidebar on the left and I need it on the right. I would set it in the theme options but the rest of the site is full width and I would then have to change a ton of those pages manually.

Is it possible to set a template file with the sidebar forced on the right?

Thanks,

M Aronoff

{name}
RankRankRankRank

Total Posts: 3667

Joined 2011-04-27

PM

 

Hi, yes however you may need to add a snippet to your child theme with your post type, but it may be something you can easily achieve via CSS such as:

body.single-POSTTYPE #sidebar {
 float: right !important;
 margin-right: 0;
}
body.single-POSTTYPE #content {
 float: left !important;
 margin-left: 0;
}


You should be able to view the page source to determine the exact body class. If you have a problem getting that to work, you can post or PM me a link as well as the plugin your using and I’ll be glad to take a closer look.

{name}
RankRank

Total Posts: 49

Joined 2012-01-06

PM

 

That did the trick! Thanks so much.

In case other run into it, the plugin is WP Awesome-Tickets.

It is a GREAT new support ticket system really built into WordPress. It makes a post type called tickets but hides any of the traditional methods to apply a template.

Your CSS did the trick perfectly.

Thanks as always!