Hide sidebar on one post category only

Hi,

I am trying to hide sidebar only on one post category. To be exact - this category is handled by WP Event Manager plugin, but I guess this does not make any difference in the approach to the solution.

The issue is that I am able to hide the sidebar and also make the rest of the content full width, but only on Cornerstone preview mode. Once I switch to the front-end view (as typical user), the content is still full width (as it should be), but the sidebar is located UNDER the content despite being hidden via CSS.

I use this code:

/*hide sidebar on 1 category only*/
.single-event_listing  .x-sidebar {
	display: none !important;
}
.single-event_listing .x-main.left {
width: 100%;
}

Do you have any idea why is this happening?

Thanks

Hi @nezzazvoni,

Thank you for reaching out to us. Your code seems correct, upon checking your site it looks like the content of your site is being served by the cache so you could only be seeing the cached content. Please clear all caches including the browser’s cache to see the changes on the front-end as well.

Let us know how this goes!

Clearing the cache didn’t work, unfortunately :frowning: After thorough inspection and chat with two IT guys I was told, that the cache is not causing the issue.

Is there a way how to do this?

Hi @nezzazvoni,

Where did you place your custom CSS? Please check all your custom CSS here and resolve all found errors.

If the issue persists, please provide us login credentials in a secure note so we can take a closer look.

Thanks,

Well, it works now… I don’t know why. But thanks anyway :slight_smile:

Hi @nezzazvoni,

More likely a cache related, glad things sorted out on your end now.

Cheers!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.