__  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

[email protected]: ~ $
<?php

namespace Templately\API;

use Templately\Utils\Helper;
use Templately\Utils\Options;
use WP_REST_Request;

class SignUp extends API {
	public function permission_check( WP_REST_Request $request )  {
		$this->request = $request;
		return true;
	}

	public function register_routes() {
		$this->post('signup', [ $this, 'create_account' ] );
	}

	public function create_account() {
		$errors    = [];
		$_ip       = Helper::get_ip();
		$_site_url = home_url( '/' );

		$first_name       = $this->get_param( 'first_name' );
		$last_name        = $this->get_param( 'last_name' );
		$email            = $this->get_param( 'email', '', 'sanitize_email' );
		$password         = $this->get_param( 'password' );
		$confirm_password = $this->get_param( 'confirm_password' );

		if ( empty( $first_name ) ) {
			$errors['first_name'] = __( 'First name cannot be empty.', 'templately' );
		}
		if ( empty( $last_name ) ) {
			$errors['last_name'] = __( 'Last name cannot be empty.', 'templately' );
		}
		if ( empty( $email ) ) {
			$errors['email'] = __( 'Email cannot be empty.', 'templately' );
		}
		if ( $email && ! filter_var( $email, FILTER_VALIDATE_EMAIL ) ) {
			$errors['email'] = __( 'Make sure you have given a valid email address.', 'templately' );
		}
		if ( empty( $password ) ) {
			$errors['password'] = __( 'Password cannot be empty.', 'templately' );
		}
		if ( empty( $confirm_password ) ) {
			$errors['confirm_password'] = __( 'Confirm password cannot be empty.', 'templately' );
		}

		if ( ! empty( $password ) && ! empty( $confirm_password ) && $password !== $confirm_password ) {
			$errors['password_mismatched'] = __( 'Password and confirm password should be matched.', 'templately' );
		}

		if ( ! empty( $errors ) ) {
			return $this->error( 'signup_errors', $errors, 'signup', '400' );
		}

		$query = 'status, message, user{ id, name, first_name, last_name, display_name, email, profile_photo, joined, is_verified, api_key, plan, plan_expire_at, my_cloud{ limit, usages, last_pushed }, show_notice }';

		$response = $this->http()->mutation(
			'createUser',
			$query,
			[
				'first_name' => $first_name,
				'last_name'  => $last_name,
				'email'      => $email,
				'password'   => $password,
				'site_url'   => $_site_url,
				'ip'         => $_ip
			]
		)->post();

		if( is_wp_error( $response ) ) {
			return $response;
		}

		if ( ! Login::is_globally_signed() ) {
			Options::set_global_login();
		}

		if ( ! empty( $response['user']['api_key'] ) ) {
			$this->utils('options')->set( 'api_key', $response['user']['api_key'] );
			unset( $response['user']['api_key'] );
		}

		$this->utils('options')->set( 'user', $response['user'] );

		return $response;
	}
}

Filemanager

Name Type Size Permission Actions
AIContent.php File 25.11 KB 0640
API.php File 6.33 KB 0640
Categories.php File 1.06 KB 0640
Conditions.php File 3.87 KB 0640
Dependencies.php File 12.41 KB 0640
FullSiteImport.php File 252 B 0640
Import.php File 6.81 KB 0640
Items.php File 14.25 KB 0640
Login.php File 8.08 KB 0640
MyClouds.php File 7.71 KB 0640
Profile.php File 5.42 KB 0640
SavedTemplates.php File 1.73 KB 0640
SignUp.php File 2.64 KB 0640
Tags.php File 866 B 0640
TemplateTypes.php File 1.85 KB 0640
ThemeBuilderApi.php File 1.82 KB 0640
WorkSpaces.php File 9.79 KB 0640
Filemanager