Home Forums WoodMart support forum Hide Comments status (format metadata) on blog posts

Hide Comments status (format metadata) on blog posts

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #642701

    churchworks
    Participant

    Hello, a few months ago, Woodmart updated how the metadata appears at the top of blog posts. This is not a very polished look, in my opinion. Are there CSS hooks that I can play with to format this better? (see attached screenshot)

    At the very least, I would like to hide the Comments status (“Comments Off”) from the top metadata on all posts.

    Thanks!

    Attachments:
    You must be logged in to view attached files.
    #642902

    Hung Pham
    Participant

    Hi churchworks,

    Thanks for reaching to us.

    1. Please add the below Custom CSS code to Theme Settings > Custom CSS > Global Custom CSS:

    .single-post .wd-meta-reply{
        display: none;
    }
    
    :is(.wd-single-post-header,.post-title-large-image) .wd-post-meta {
        --wd-link-color: var(--color-gray-400);
        --wd-link-color-hover: var(--color-gray-500);
        display: flex;
        flex-direction: column;
        align-items: var(--wd-align); /* Changed from center to use the variable */
        gap: 10px;
        color: var(--color-gray-400);
    }
    
    .wd-meta-author {
        display: flex;
        align-items: center;
        gap: 5px;
        color: var(--color-gray-400);
    }

    2. Remove On

    Please add the below Custom CSS code to Theme Settings > Custom JS:

    $(document).ready(function() {
        // Find the wd-meta-date div and remove "On" from its text
        $('.wd-meta-date').each(function() {
            let currentText = $(this).text().trim();
            let newText = currentText.replace('On ', '');
            $(this).text(newText);
        });
    });

    Regards,

    #649559

    churchworks
    Participant

    Hello, thank you for the code! The custom CSS worked. Nice!
    The custom JS, however, did not work to remove “On” before the date. (see screenshot)

    Attachments:
    You must be logged in to view attached files.
    #649736

    Hung Pham
    Participant

    Hi churchworks,

    To assist you in the best possible manner, I kindly ask that you please provide me temporary wp-admin info (wp-admin URL, username, password) to the Private Content area, this will allow me to thoroughly investigate and address your concerns more efficiently.

    Regards,

    #650889

    churchworks
    Participant

    Temp admin login credentials added to private content. Thanks.

    #651007

    Hung Pham
    Participant

    Hi churchworks,

    Please double check your site.

    Regards,

    #651479

    churchworks
    Participant

    Hi, the date still shows “On [date]” for the blog posts, but I’ve decided I don’t mind. 🙂
    We can call this resolved. Thank you!

    #651484

    Hung Pham
    Participant

    Hi churchworks,

    Somehow it didn’t save the code. Please remove above JS code and use below one and put in On ready section:

    I tested on my local and it worked.

    // Find the wd-meta-date div and remove "On" from its text
        jQuery('.wd-meta-date').each(function() {
            let currentText = jQuery(this).text().trim();
            let newText = currentText.replace('On ', '');
            jQuery(this).text(newText);
        });

    Regards,

Viewing 8 posts - 1 through 8 (of 8 total)