Wordpres password as plain text in email

No, WordPress passwords are not stored in plain text. They’re stored as hashes generated by an old version of PHPass, which I think does multiple rounds of salted MD5 hashes. You cannot extract the original password from this, by design. See Why shouldn’t I store passwords in plain text? on Information Security StackExchange. If you … Read more

Undefined Function Fatal Error with Shortcode [closed]

Well, the AI didn’t do THAT bad of a job. But either you or the AI didn’t deliver code for the functions get_users_who_commented or get_number_of_comments_by_user which are not wordpress functions but have to be coded seperatly. Also, i would change the code a bit to use wordpress-internal functions like the comment query: function my_custom_shortcode( $atts … Read more

User Query Multiple Orderby Clause

Try using: ‘orderby’=>’distribution_list last_name’, ‘order’=>’ASC’ Instead of: ‘orderby’ => array( ‘distribution_list’ => ‘ASC’, ‘last_name’ => ‘ASC’, ), So: $users = new WP_User_Query( array( ‘meta_query’ => array( ‘relation’ => ‘AND’, ‘lastname’ => array( ‘key’ => ‘last_name’, ‘compare’ => ‘EXISTS’, ‘type’ => ‘CHAR’, ), ‘list’ => array( ‘distribution_list’ => array( ‘key’ => ‘distribution_list’, ‘value’ => ‘”72″‘, ‘compare’ … Read more

Set a minimal number for next user_id

You can access via phpMyAdmin and change the Auto Increment number to be your next user ID number. Open phpMyAdmin Go to SQL tab at the top. Enter the following: ALTER TABLE ‘wp_users’ AUTO_INCREMENT=32200906; Now create a new user and the ID should be 32200906

Send email to user if their role is changed to Author

Check for the value of $new_role before sending the email, if it isn’t author then do nothing function user_role_update( $user_id, $new_role ) { if ( $new_role == ‘author’ ) { $site_url = get_bloginfo( ‘wpurl’ ); $user_info = get_userdata( $user_id ); $to = $user_info->user_email; $subject=”Role changed: ” . $site_url . ”; $message=”Hello ” . $user_info->display_name . … Read more

Add a user to edit the layout of a site

We may need a little more information on the version of WordPress you are running, or at least the interface you are seeing that the new admin is not seeing. Typically, when I troubleshoot WordPress installations and I have to add an administrator, I have full access just like an admin. So, it shouldn’t be … Read more

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