I am using a button which displays a like/upvote button. There is an error in the plugin which displays the button on every page of the site. It should only show on blog posts and job listings through WP job manager.
Is there any way to remove this on pages only?
My current solution is:
.vortex-container-vote {text-indent: -9999px;}
But this removes the plugin from every page(including blog posts and job listings)
I wonder if anybody has a solution which keeps blog posts and listings?
Many thanks
WordPress includes a post-type identifier class in the body tag. So something like this should do it:
/* Here you hide it everywhere */
.vortex-container-vote {
display: none;
}
/* Then here you only show it on the post-types you want */
.post .vortex-container-vote {
display: block;
}
Note that this only shows it on posts, as I don't know the post-type for your job listings. But if say the post-type is single-job_listing, then change the second part of the css above to this to include the job listings:
.post .vortex-container-vote, .single-job_listing .vortex-container-vote {
display: block;
}
Related
I’m using Nikkon on Wordpress and would like the shopping icon to show only in shop section and after customer has added an item, kind of like how Squarespace does it. Is it possible? I used the following code in CSS edit but it did nothing:
.home .top-login,
.home .top-cart {
display: none;
}
I use this code to hide a button in css. It works. Is it possible to hide the button in a specific wordpress category posts?
div.screen-reader-text3
{
display:none;
}
any help appreciated
Yes. Wordpress adds class to body element on category page.
If you inspect your code on category page you'll see something like this in body class:
archive category category-skincare category-2.
The skincare it is a slug of my category, in your case it will be different.
You need to copy category-skincare and use it in your CSS like so:
.category-skincare div.screen-reader-text3 {
display: none;
}
Each page in wordpress have personal ID. If you inspect the page source via console, you can see in body this:
<body class="home page-template-default page page-id-58">, where page-id-58 - the unique page id.
In css it's look like that
.page-id-58 div.screen-reader-text3 {display:none;}
Recently I have been working on my WordPress blog website is French https://www.geekparfait.com/.
I am using FlatNews WordPress theme http://demo.sneeit.com/flatnews/
Everything was going pretty well. But now I am facing this issue on my categories pages https://www.geekparfait.com/category/ios/. Its like I am unable to click the posts on category pages. The same issue is on the category pages sidebar as well.
But on the homepage https://www.geekparfait.com/, everything is working fine. I am able to click and open the posts on the homepage.
Hope I can get some insight from you guys.
Thanks
The issue is with the sidebar and the position attribute of it. Please try out the below code in style.css or theme option panel custom css setion.
.category section.fn-primary > strong {
position: inherit;
}
Hope this will work for you.
Screenshot
The problem is the sidebar is generating that can click in that entire div, try changing that position: relative. with
.category strong {
position: inherit!important;
}
Hello I am trying to get rid of the 'leave a comment' or 'n comments' tag which is shown on my wordpress website recent posts without getting rid of Date and Author
Any solution?
First, have a look if your theme 'wordstar' has a configuration option for this meta-data. If not, you could hide what you do not need using custom CSS:
.entry-meta .comment,
.entry-meta .cat-links,
.entry-meta .tag-links {
display: none;
}
Just add whatever you want to hide.
To hide the comments count from your WordPress blog, add a CSS rule to hide the .comments-count class. To do so, go to /wp-admin > Appearance > Customize > Additional CSS and place the following CSS rule:
.comments-count {
display: none;
}
Disable comments. Go to WP Admin -> Settings -> Discussion ->, uncheck Allow people to post comments on new articles checkbox and click Save button.
How to remove post archive posts description/excerpt from wordpress website?
See the screenshot: http://tinypic.com/r/1zq5zc7/8
I already tried this code, but it did not work for me.
.archive .post-content p {
display: none;
}