Support » Themes and Templates » Delete the html message in comments

Viewing 15 replies - 1 through 15 (of 16 total)
  • you can see what i´m talking about at the end of this web

    http://www.ntalberto.com/?p=463

    regards

    You could try editing the comments.php file

    <div id="form-allowed-tags" class="form-section">
    	              <p><span><?php _e('You may use these <abbr title="HyperText Markup Language">HTML</abbr> tags and attributes:', 'your-theme') ?></span> <code><?php echo allowed_tags(); ?></code></p>
                  </div>

    this is all my comments php file. Y don´t know which part i need to modify.

    thanks!!

    [Code moderated as per the Forum Rules. Please use the pastebin]

    Delete the following as it appears to only echo the html info.
    <p><span><?php _e('You may use these <abbr title="HyperText Markup Language">HTML</abbr> tags and attributes:', 'your-theme') ?></span> <?php echo allowed_tags(); ?></p>
    I tried it and it worked.

    i have done it but the footer has been moved to the left side.

    It doesn´t works. I would like to hide the hmtl message insted of delete it. Do you know the code for hide it?

    thanks another time

    can anybody help me?

    For WP3;

    You have to filter the arguments from the function function comment_form (wp-includes/comment-template.php)

    I did it like this, addind this code in the functions.php of my theme :

    function mytheme_init() {
    	add_filter('comment_form_defaults','mytheme_comments_form_defaults');
    }
    add_action('after_setup_theme','mytheme_init');
    
    function mytheme_comments_form_defaults($default) {
    	unset($default['comment_notes_after']);
    	return $default;
    }
    WP Voyager

    (@mindblender-3d)

    I would like to hide the hmtl message insted of delete it. Do you know the code for hide it?

    To hide the code, comment it out. To do this, put an opening <!-- and a closing --!> around the parts that you want to remove.

    In your case, it would look something like this:

    <!-- <p><span><?php _e('You may use these <abbr title="HyperText Markup Language">HTML</abbr> tags and attributes:', 'your-theme') ?></span> <?php echo allowed_tags(); ?></p> --!>

    See if that works,
    MindBlender 3D

    thanks but now doing this the buttom of POST A COMMENT has been moved, i´dont know what to do for hide the text wothoutmoving the buttom

    thankyou very much!!!

    Thanks grosbouff for your solution!

    To hide it, just modify your theme’s CSS stylesheet and add:

    .form-allowed-tags { display: none; }

    Otherwise grosbouff’s method is good. You want to avoid editing the original WordPress files.

    Elio Rivero

    (@ilovecolors)

    Just set ‘comment_notes_after‘ to ” when you call comment_form

    <?php comment_form(array('comment_notes_after' => '')); ?>

    Go to the style sheet (style.css) & look for the following piece of code:

    #respond .form-allowed-tags {
    color: #888;
    font-size: 12px;
    line-height: 18px;
    }

    Now add the following towards the end:
    display: none;

    So that the final code looks like this:

    #respond .form-allowed-tags {
    color: #888;
    font-size: 12px;
    line-height: 18px;
    display: none;
    }

    Let me know if this works.

    The content of a plugin to erase any thing in ‘comment_notes_after’ can be this:

    function mytheme_init() {
    add_filter('comment_form_defaults','mytheme_comments_form_defaults');
    }
    add_action('after_setup_theme','mytheme_init');
    function mytheme_comments_form_defaults($default) {
    	unset($default['comment_notes_after']);
    	return $default;
    }

    But don’t works on any theme. In the default theme “Twenty Ten”, works fine, but in the Suffusion don’t works. The theme overwrite this filter. What can I do to override the choices of the theme?
    What hook can I use to overwrite options of the theme?

    @marq_za Thanks your trick work for me 🙂

Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘Delete the html message in comments’ is closed to new replies.