How to change login link in "You must be logged in to post a comment"

  • Prasanna SP

    #31180

    Okay try this,

    <?php
    function graphene_custom_comment_form_args( $args ){

    $args['must_log_in'] = 'You must be <a href="#loginwithajaxwidget-6">logged in</a> to post a comment.';

    return $args;
    }
    add_filter( 'graphene_comment_form_args', 'graphene_custom_comment_form_args' );
    ?>

    Prasanna SP

    #31181

    On homepage, the ID is loginwithajaxwidget-6 but on other pages, it is changed to loginwithajaxwidget-5.

    Are you using alternate frontpage widgets?

    Prasanna SP

    #31182

    Hmm.. The original code you’ve posted should work.. (#LoginWithAjax)

    lateatlantean

    #31183

    The one on the homepage is in the “front page sidebar widget area” the other is in the plain old “sidebar widget area”.

    lateatlantean

    #31184

    Tried 5 and 6…neither worked

    lateatlantean

    #31185

    Can I just take this out <a href="#loginwithajax">logged in</a> to remove the link portion and change the wording to something like “Please register/login above to post a comment” ?

    Prasanna SP

    #31186
    Quote:
    Can I just take this out <a href="#loginwithajax">logged in</a> to remove the link portion and change the wording to something like “Please register/login above to post a comment” ?

    Yeah, sure!

    <?php
    function graphene_custom_comment_form_args( $args ){

    $args['must_log_in'] = 'Please register/login above to post a comment.';

    return $args;
    }
    add_filter( 'graphene_comment_form_args', 'graphene_custom_comment_form_args' );
    ?>

    lateatlantean

    #31187

    Sigh…it did not work. Stayed exactly the same. Well, I must sleep, my hours are long. If you think of something let me know.

    I usually have it in maintenance mode, but I will leave it open for the night just in case you want to look at it. Maybe I need to change something in the settings? Some other conflict?

    I am using a child theme.

    When I tried to test the comments functions by posting a test comment, the submit button was unresponsive and the post would not submit. Just did nothing. Could it be related somehow…a whole comment section thing? Could it be something silly like my settings aren’t correct? I don’t know, just stabbing in the dark.

    Thank you so much for your time and patience. You and your efforts are greatly appreciated!

    Donna

    lateatlantean

    #31188
    Quote:
    When I tried to test the comments functions by posting a test comment, the submit button was unresponsive and the post would not submit. Just did nothing. Could it be related somehow…a whole comment section thing? Could it be something silly like my settings aren’t correct? I don’t know, just stabbing in the dark.

    Managed to get this working again…un-ticked all options in the WP Comment customizimng section and re-ticked one by one. Haven’t found the troublemaker yet, but all is good there for now. 🙂

    Still haven’t been able to make the “log in link issue” work, by any of the above methods. I will keep trying…but please let me know if anyone has any ideas.

    Thanks again for your patience and understanding!

    Donna

Viewing 10 posts - 11 through 20 (of 25 total)

You must be logged in to reply to this topic.