If I understand correctly, you’re trying to turn off the ability for users to add new comments on a single blog post. Is that right?
If so, instead of using CSS, I’d recommend using the built-in WordPress feature to turn off commenting for a single blog post. You’ll find it within the “Discussion” section when editing the post. The option is called “Allow Comments”. Uncheck that option, save the post, and you should be all set. Also, don’t worry, you’re existing comments should still appear.
Here’s a screenshot of where the setting is in case you need it:
Related Posts:
- Making a
- CSS to make HTML page footer stay at bottom of the page with a minimum height, but not overlap the page
- How to get these two divs side-by-side?
- What is the difference between the selectors “.class.class” and “.class .class”?
- Bootstrap 4, How do I center-align a button?
- How do I horizontally center a span element inside a div
- Is background-color:none valid CSS?
- Float a div above page content
- Text not wrapping inside a div element
- How to make padding:auto work in CSS?
- How to vertically center inside the parent element with CSS?
- How can I horizontally align my divs?
- background-size: cover not working?
- CSS not working in Chrome
- Pure CSS to make font-size responsive based on dynamic amount of characters
- CSS – display: none; not working
- How to enqueue style before style.css
- wp_enqueue_scripts, wp_register_scripts, wp_print_scripts: i’m confused
- What is the correct way to enqueue multiple CSS files?
- Which Details Are Required For Style.css File Header?
- How to implement different color schemes in your themes
- @font-face doesn’t work
- wp_enqueue_script + how to load JS or CSS in one URL merge call?
- How to target first img in every wordpress post with CSS [closed]
- How to change Parent Themes in Child Theme CSS
- hSite has no css on mobile [closed]
- How to set different font family based on text language?
- Relative path in wp_register_style not working
- Enable specific CSS Code for Visitors and specific Roles
- WordPress on localhost working, when sharing IP to connect receive err_connection_refused on .js and .css files
- How to Add Custom CSS Buttons to WordPress as a Shortcode?
- Can’t remove WordPress post image height/width attributes?
- How do I add an indicator to my .menu-item if it contains a .sub-menu?
- How do you customize the admin bar for buddypress?
- Load in wp admin assets from child theme
- Enqueue styles in new site editor in WordPress 5.9
- Two column Dropdown for WordPress Toolbar
- Code working just in specific time period
- Images loaded as background-image are shown but s aren’t
- Moving button on Online Consulting theme
- Style WP_Debug?
- How can I get the search form to be selected automatically?
- Is there a way to add additional CSS styles to the styles css file dynamically?
- Is it safe to use WordPress generated classes?
- CSS styling of native (inbuilt) wordpress thumbnails [closed]
- Search Bar in Thesis WordPress Site
- Unstable handling of CSS under WordPress/Elementor
- Add core style in theme
- How to sync the style in the visual editor with the style of a child theme?
- Update wordpress causes white space on admin
- Add Custom Alignment Option to WordPress Blocks/Gutenberg
- Responsive issue with secondary logo – not sticking in position [closed]
- How would one set or override a Fallback font for characters in second language?
- why has this element moved despite css being the same as other pages?
- Custom css author role
- Test wrapping cutting words in half on my WP site [closed]
- WordPress aggressively caching CSS
- Font styling in embedded Twitter feed
- WordPress backend is loading as a list
- Embed widget from external source (Zendesk)
- Custom CSS in Widget editor (Gutenberg) gets stripped out
- Dynamically populated scss values or how to change styles by user choice
- Save custom option in CSS file
- broken internal JavaScript and CSS files
- avada woocommerce product details in grid
- WordPress login using a completely custom page and no plugins?
- Modifications on css file are not visible
- How to display image on WordPress homepage
- My sites mobile view design is different when not logged in – how do I ensure it’s all the same?
- How to change specific menu tab from left to right in My Home Theme?
- WP Admin Bar transparent on some pages (.screen-reader-shortcut)
- Admin bar default color scheme for nonregistered/nonlogged users
- Lines of CSS only being delivered while logged in
- How to Compress Css/js code in wordpress and increase loading speed?
- How to Take Logo Out of Navigation Menu? [closed]
- @media applying globally and not separately for each screen width [closed]
- Make different border color gallery items
- How remove the white space between my menu and slider?
- WordPress site using unknown overriding css
- Move both sidebars more to their sides [closed]
- Header formatting works for safari but not chrome @media screen size technique on iphone
- Style Switching
- Adding a css style to the main nav menu in child pages
- Adding custom css to a theme depending on whether the admin user is logged in or not
- Adjusting post width according to the image size
- Theme looks ugly – FOUC – stylesheets loaded in footer
- Converting Static HTML pages to WordPress
- Background tiles not working in iPad2 but ok everywhere else
- To override CSS of parent theme
- How to target only one element if more elements share the same CSS class
- Can’t override CSS with child theme
- [class*=”content”]:before css styles in TwentyThirteen [closed]
- How to change the CSS in one file?
- Why doesn’t media(max-width) work on h2 title?
- How to use WordPress 3.8 back-end CSS in front-end?
- Enqueue MCE Editor CSS in admin page
- Remove / Disable default custom.css?ver=1.0.0
- How to remove class=”wp-block-heading” from Heading tags?
- Website is not showing updated CSS
- How to hide button with CSS class?