Customise Comments HTML5

Community Forums Forums Design Tips and Tricks Customise Comments HTML5

This topic is: not resolved


This topic contains 1 reply, has 2 voices, and was last updated by  braddalton 2 years, 2 months ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #64124



    Wonder if you could point me in the right direction. When I moved to Genesis/Wordpress a while back I imported my comments from another system. The other system didn’t have dates on the comments. So I basically gave them all the same comment date (May 5 2012).

    Obviously I didn’t want all the comments showing with the same date so I got help from some folks and managed to come up with a function that wouldn’t show the comment date if it was before a certain date (set in Advanced Custom Fields – Options Page).

    I’m now converting my site to Genesis2 HTML5.

    The function I have still works with Genesis 2 but doesn’t make use of the HTML5 functionality. (Comments don’t have all the schema info etc.).

    How can I call/filter/modify (or whatever) it so I can make use of my own (adapted?) comments function with HTML5.

    What I did before was:

    1) In custom post template: add_filter(‘genesis_comment_list_args’, ‘child_comment_list_args’);

    2) In functions.php

    function child_comment_callback( $comment, $args, $depth ) {

    $GLOBALS[‘comment’] = $comment; ?>

    <li id=”comment-”>

    <?php printf( __( ‘%s %s:’, ‘genesis’ ), get_comment_author(), apply_filters( ‘comment_author_says_text’, __( ‘says’, ‘genesis’ ) ) ); ?>

    $dbm_comment_date_cutoff) && ($dbm_comment_dates_on))

    echo get_comment_date();


    comment_approved == ’0′) : ?>

    $depth, ‘max_depth’ => $args[‘max_depth’] ) ) ); ?>

    <?php do_action( ‘genesis_after_comment’ );

    /** No ending tag because of comment threading */


    function child_comment_list_args($args) {
    $args[‘callback’] = ‘child_comment_callback’;

    return $args;

    I don’t need the script rewriting in detail. Just need some help with how to call the HTML5 comments form and replace it with my own. I know enough php to amend a script.




    You can use the WordPress filter hooks.

    I wrote several posts about it a while ago and it works fine.

    You’ll find 5 links at the end of this post with more tutorials using the WordPress filters to customize comment form.

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

You must be logged in to reply to this topic.