public function create( $password = null, $email = null, $mailpassword = false, $reason = null, $realname = null, $language = null, $domain = null ) {
		global $pgNotag, $pgTag;
		pecho( "Creating user account " . $this->username . "...\n\n", PECHO_NOTICE );

		try{
			$this->preEditChecks( "Create" );
		} catch( EditError $e ){
			pecho( "Error: $e\n\n", PECHO_FATAL );
			return false;
		}

		$token = $this->wiki->apiQuery(
			array(
				'action' => 'createaccount',
				'name'   => $this->username
			), true
		);

		$token = $token['createaccount']['token'];

		$apiArray = array(
			'action' => 'createaccount',
			'token'  => $token,
			'name'   => $this->username
		);

		if( !$password == null ) $apiArray['password'] = $password;
		if( !$email == null ) $apiArray['email'] = $email;
		if( !$realname == null ) $apiArray['realname'] = $realname;
		if( !$domain == null ) $apiArray['domain'] = $domain;
		if( !$reason == null ) {
			if( !$pgNotag ) $reason .= $pgTag;
			$apiArray['reason'] = $reason;
		}
		if( !$language == null ) $apiArray['language'] = $language;

		if( $this->exists() ) {
			pecho( "Error: User account already exists.\n\n", PECHO_ERROR );
			return false;
		}
		if( $password == null && !$mailpassword ) {
			pecho( "Error: neither a password or the mailpassword have been set.\n\n", PECHO_ERROR );
			return false;
		}
		if( $mailpassword ) {
			if( $email == null ) {
				pecho( "Error: Email not specified.\n\n", PECHO_ERROR );
				return false;
			} else $apiArray['mailpassword'] = 'yes';
		} else {
			if( is_null( $password ) ) {
				pecho( "Error: No password specified.\n\n", PECHO_ERROR );
				return false;
			}
		}

		$result = $this->wiki->apiQuery( $apiArray, true );

		$this->__construct( $this->wiki, $this->username );

		if( isset( $result['createaccount']['result'] ) ) {
			if( $result['createaccount']['result'] == 'success' ) {
				return true;
			} else {
				pecho( "Create error...\n\n" . print_r( $result['createaccount'], true ), PECHO_FATAL );
				return false;
			}
		} else {
			pecho( "Create error...\n\n" . print_r( $result['createaccount'], true ), PECHO_FATAL );
			return false;
		}
	}