This topic has 7 replies, 2 voices, and was last updated 10 years by Catalin.

  • Author
  • #27078
     Jeremy14
    Participant

    Hello hope all is well,

    I am trying to fix my comments under my news (post) page. I’ve attached a screenshot. It says that comments are required and instead of “Post Comment” it says “Send Message”. Thank you

    Attachments:
    You must be logged in to view attached files.
    #27617
     Catalin
    Moderator

    Hello,

    Please send me a link to your website.

    Thank you,
    Catalin

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #27626
     Jeremy14
    Participant
    This reply has been set as private.
    #27684
     Catalin
    Moderator

    Hello,

    Please add this code in your functions.php filde from your child theme:

    COPY CODE
    
    
    function kleo_comment_changes($arg) {
        $arg['label_submit'] =  __( 'Post Comment', 'kleo_framework' );
        $arg['comment_notes_before'] = '';
        $arg['comment_notes_after'] = '';
        $arg['comment_field'] = '<div class="row"><div class="twelve columns"><label for="comment">' . _x( 'Comment', 'noun', 'kleo_framework' ) . ' ('.__("required", 'kleo_framework').')</label><textarea id="comment" name="comment" cols="45" rows="8" required aria-required="true"></textarea></div></div>';
        return $arg;
    }
    
    

    Let me know if this works.

    Thank you,
    Catalin

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #28073
     Jeremy14
    Participant

    Sorry for the lag. The code worked for the comment button. But it is still saying that comments are required.

    #28088
     Catalin
    Moderator

    replace the code I provided with this:

    COPY CODE
    
    
    function kleo_comment_changes($arg) {
        $arg['label_submit'] =  __( 'Post Comment', 'kleo_framework' );
        $arg['comment_notes_before'] = '';
        $arg['comment_notes_after'] = '';
        $arg['comment_field'] = '<div class="row"><div class="twelve columns"><label for="comment">' . _x( 'Comment', 'noun', 'kleo_framework' )</label><textarea id="comment" name="comment" cols="45" rows="8" required aria-required="true"></textarea></div></div>';
        return $arg;
    }
    
    
    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #28711
     Jeremy14
    Participant
    This reply has been set as private.
    #28759
     Catalin
    Moderator

    Hello Jeremy,

    Please compaire your code with the original function:

    COPY CODE
    
    
    
    function kleo_comment_changes($arg) {
        $arg['label_submit'] =  __( 'Send Message', 'kleo_framework' );
        $arg['comment_notes_before'] = '';
        $arg['comment_notes_after'] = '';
        $arg['comment_field'] = '<div class="row"><div class="twelve columns"><label for="comment">' . _x( 'Comment', 'noun', 'kleo_framework' ) . ' ('.__("required", 'kleo_framework').')</label><textarea id="comment" name="comment" cols="45" rows="8" required aria-required="true"></textarea></div></div>';
        return $arg;
    }
    
    

    take a look at syntax and punctuation. I tested the code on my server and it works.

    Thank you,
    Catalin

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
Viewing 8 posts - 1 through 8 (of 8 total)

The forum ‘Sweetdate – WordPress’ is closed to new topics and replies.

Log in with your credentials

Forgot your details?