This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$username = "your_username"; | |
$password = "your_pass"; | |
$url = 'your_stp_server_url'; | |
// Make our connection | |
$connection = ssh2_connect($url); | |
// Authenticate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action('wp_ajax_register_user_front_end', 'register_user_front_end', 0); | |
add_action('wp_ajax_nopriv_register_user_front_end', 'register_user_front_end'); | |
function register_user_front_end() { | |
$new_user_name = stripcslashes($_POST['new_user_name']); | |
$new_user_email = stripcslashes($_POST['new_user_email']); | |
$new_user_password = $_POST['new_user_password']; | |
$user_nice_name = strtolower($_POST['new_user_email']); | |
$user_data = array( | |
'user_login' => $new_user_name, |