How to Save Different Usermeta Fields According to User Role?

Observation: following the guidelines suggested in this article, I’m trying to improve the quality both of the Q and the A. It’s a learning process… In your original code, you were displaying different input fields according to the user role and other conditionals. add_action( ‘show_user_profile’, ‘user_fields_for_admin’, 10); add_action( ‘edit_user_profile’, ‘user_fields_for_admin’, 10); function user_fields_for_admin( $user ){ … Read more

How to change submit button value in comment from “Post Comment” to “Send”

Open comments.php file inside your theme’s folder <?php if ( comments_open() ) : ?> <?php $fields = array( ‘author’ => ‘<p class=”comment-form-author”>’ . ‘<label for=”author”>’ . __( ‘Name’, ‘responsive’ ) . ‘</label> ‘ . ( $req ? ‘<span class=”required”>*</span>’ : ” ) . ‘<input id=”author” name=”author” type=”text” value=”‘ . esc_attr( $commenter[‘comment_author’] ) . ‘” size=”30″ … Read more

How to remove Profile Picture section or the message “You can change your profile picture on Gravatar.”

To remove the profile picture row of the table (which includes the gravatar link): jQuery( “tr.user-profile-picture” ).remove(); To remove that entire “about yourself” table: jQuery( “tr.user-profile-picture” ).parents(“table:first”).remove(); Use this type of jQuery call, don’t try to get fancy with the loop. This is on WP 4.4; earlier versions may have different HTML class names for … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)