Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

Dboor war-How to set no activation

Status
Not open for further replies.
Newbie Spellweaver
Joined
Dec 4, 2011
Messages
10
Reaction score
0
Hi,please.Me don´t want come activation e-mail.Please help me.How I may set no activation.
 
Working in iZariam v0.1.0
Loyal Member
Joined
Feb 3, 2011
Messages
772
Reaction score
74
One user posted it in other post, please use the search
 
Upvote 0
Newbie Spellweaver
Joined
Sep 12, 2012
Messages
43
Reaction score
0
i have been looking for this post and i never found it.
i have this problem too. how can i disable the activation mail after registeration?
 
Upvote 0
Joined
Sep 25, 2011
Messages
710
Reaction score
318
go to register.php file.

There you need to find where the player is inserted into the database

find the "activated" row and make it to be "1"

So when anybody register his account will be activated automatically


BUT... He will still receive email for activations. it's just not needed
 
Upvote 0
Newbie Spellweaver
Joined
Sep 12, 2012
Messages
43
Reaction score
0
go to register.php file.

There you need to find where the player is inserted into the database

find the "activated" row and make it to be "1"

So when anybody register his account will be activated automatically


BUT... He will still receive email for activations. it's just not needed

Where can i find it here?

<?php
/*********************/
/* */
/* Version : 5.1.0 */
/* Author : RM */
/* Comment : 071223 */
/* */
/*********************/
require( ".".DIRECTORY_SEPARATOR."app".DIRECTORY_SEPARATOR."boot.php" );
require_once( MODEL_PATH."register.php" );


class GPage extends gamepage
{


public $err = array
(
0 => "",
1 => "",
2 => "",
3 => ""
);
public $success = NULL;
public $SNdata = NULL;
public $UserID = 0;


public function GPage( )
{
parent::gamepage( );
$this->viewFile = "register.phtml";
$this->contentCssClass = "signup";
}


public function load( )
{
parent::load( );
$this->SNdata = 0;
$this->success = FALSE;
if ( $this->isPost( ) )
{
if ( $this->globalModel->isGameOver( ) )
{
$this->redirect( "over.php" );
}
else
{
$name = trim( $_POST['name'] );
$email = trim( $_POST['email'] );
$pwd = trim( $_POST['pwd'] );
$this->err[0] = strlen( $name ) < 3 ? register_player_txt_notless3 : "";
if ( $this->err[0] == "" )
{
$this->err[0] = preg_match( "/[:,\\. \\n\\r\\t\\s]+/", $name ) ? register_player_txt_invalidchar : "";
}
if ( $name == "[ally]" || $name == "admin" || $name == "administrator" || $name == "مدير" || $name == "تتار" || $name == "التتار" || $name == "دعم" || $name == "الدعم" || $name == $this->appConfig['system']['adminName'] || $name == tatar_tribe_player )
{
$this->err[0] = register_player_txt_reserved;
}
$this->err[1] = !preg_match( "/^[^@]+@[a-zA-Z0-9._-]+\\.[a-zA-Z]+\$/", $email ) ? register_player_txt_invalidemail : "";
$this->err[2] = strlen( $pwd ) < 4 ? register_player_txt_notless4 : "";
$this->err[3] = !isset( $_POST['tid'] ) || $_POST['tid'] != 1 && $_POST['tid'] != 2 && $_POST['tid'] != 3 && $_POST['tid'] != 6 && $_POST['tid'] != 7 ? "<li>".register_player_txt_choosetribe."</li>" : "";
$this->err[3] .= !isset( $_POST['kid'] ) || !is_numeric( $_POST['kid'] ) || $_POST['kid'] < 0 || 4 < $_POST['kid'] ? "<li>".register_player_txt_choosestart."</li>" : "";
if ( 0 < strlen( $this->err[0] ) || 0 < strlen( $this->err[1] ) || 0 < strlen( $this->err[2] ) || 0 < strlen( $this->err[3] ) )
{
return;
}
$m = new RegisterModel( );
$this->err[0] = $m->isPlayerNameExists( $name ) ? register_player_txt_usedname : "";
$this->err[1] = $m->isPlayerEmailExists( $email ) ? register_player_txt_usedemail : "";
if ( 0 < strlen( $this->err[0] ) || 0 < strlen( $this->err[1] ) )
{
$m->dispose( );
}
else
{
$villageName = new_village_name_prefix." ".$name;
#removed 'PLAYERTYPE_NORMAL' right after map_size thing. Dunno why it doesnt make him player_type = 1 but owke.
$result = $m->createNewPlayer( $name, $email, $pwd, $_POST['tid'], $_POST['kid'], $villageName, $this->setupMetadata['map_size'], 1, 1, $this->SNdata );
if ( $result['hasErrors'] )
{
$this->err[3] = register_player_txt_fullserver;
$m->dispose( );
}
else
{
$m->dispose( );
$link = WebHelper::getbaseurl( )."activate.php?id=".$result['activationCode'];
$to = $email;
$from = $this->appConfig['system']['email'];
$subject = register_player_txt_regmail_sub;
$message = sprintf( register_player_txt_regmail_body, $name, $name, $pwd, $link, $link );
WebHelper::sendmail( $to, $from, $subject, $message );
$this->success = TRUE;
}
}
}
}
}


}




$p = new GPage( );
$p->run( );
?>
 
Upvote 0
Joined
Sep 25, 2011
Messages
710
Reaction score
318
Sorry, I write wrong file

The file that is needed is app/model/register.php

Find the function

public function createNewPlayer
and edit it

or just replace the whole file with the attached file


and then say Thanks
 

Attachments

You must be registered for see attachments list
Upvote 0
Newbie Spellweaver
Joined
Sep 12, 2012
Messages
43
Reaction score
0
Sorry, I write wrong file

The file that is needed is app/model/register.php

Find the function

public function createNewPlayer
and edit it

or just replace the whole file with the attached file


and then say Thanks

Big Massive thanks Mr Dzoki :DD
 
Upvote 0
Status
Not open for further replies.
Back
Top