![](https://beanscommunity.wpenginepowered.com/wp-content/uploads/beans/images/cfe6ee37e00932086a25788aaa7c4472-87a1c39.jpg)
Hi thierry,
I'm newbie wp developer. I wanted the line (field Name, Email, Website) is above (field Comment), not as now. How do I change it safely?
Thanks,
![](https://beanscommunity.wpenginepowered.com/wp-content/uploads/beans/images/c70294be72623e3f8995ee4832f8d065-87a1c39.jpg)
Hey Rico, welcome to the forum 🙂
The comment fields order is handle on the WP Core side but you may use the comment_form_fields
filter to re-order them. Here is the code snippet I would suggest.
add_filter( 'comment_form_fields', 'example_order_comment_form_fields' );
function example_order_comment_form_fields( $fields ) {
// Move comment field last.
$fields['comment'] = array_shift( $fields );
return $fields;
}
A less "elegant" way but faster would be as follow:
add_filter( 'comment_form_fields', 'example_order_comment_form_fields' );
function example_order_comment_form_fields( $fields ) {
$comment = $fields['comment'];
unset( $fields['comment'] );
$fields['comment'] = $comment;
return $fields;
}
Note that both examples do exactly the same, the first one is a bit shorter and more elegant while the second one is faster PHP wise.
Hope that helps,
![](https://beanscommunity.wpenginepowered.com/wp-content/uploads/beans/images/cfe6ee37e00932086a25788aaa7c4472-87a1c39.jpg)
Yes! it worked perfectly as I wanted.
Thanks!