Title: calling wp_loging
Last modified: August 19, 2016

---

# calling wp_loging

 *  [blackc2004](https://wordpress.org/support/users/blackc2004/)
 * (@blackc2004)
 * [18 years, 1 month ago](https://wordpress.org/support/topic/calling-wp_loging/)
 * Hi there. I am trying to integrate with ZenCart so that when someone logs into
   Zencart it also logs them into WordPress. I have made it so that registration
   between the two work, but I cannot get the wp_login to work.
 * It seems to just die without an error. Here’s my code:
    `function update (&$callingClass,
   $notifier, $paramsArray) { global $db;
 *  $email = $_POST[’email_address’];
    $user_id = username_exists($email); if (!
   $user_id) { $user_id = email_exists($email); } if (!$user_id) { if ($_POST[‘password’]
   == ”) { $user_pass = wp_generate_password(); } else { $user_pass = $_POST[‘password’];}
   $user_id = wp_create_user( $email, $user_pass, $email ); update_usermeta($user_id,’
   first_name’,$_POST[‘firstname’]); update_usermeta($user_id,’last_name’,$_POST[‘
   lastname’]); wp_new_user_notification($user_id, $user_pass);
 *  $user = wp_authenticate($email, $user_pass);
 *  if ( !is_wp_error($user) )
    return true; } }`

The topic ‘calling wp_loging’ is closed to new replies.

## Tags

 * [integrate](https://wordpress.org/support/topic-tag/integrate/)
 * [wp_login](https://wordpress.org/support/topic-tag/wp_login/)
 * [zencart](https://wordpress.org/support/topic-tag/zencart/)

 * 0 replies
 * 1 participant
 * Last reply from: [blackc2004](https://wordpress.org/support/users/blackc2004/)
 * Last activity: [18 years, 1 month ago](https://wordpress.org/support/topic/calling-wp_loging/)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
