Ir para conteúdo
  • Cadastre-se
  • 0

Criação de contas pelo site


stiv

Pergunta

Bom estou usando esse site por axei ele aqui e considerei o mais facil de eu mexer nele pois n intendo quase nda de site

Meu server esta num dedicado e meu site em um host

 

apos muitas tentativas consegui conectar o site ao meu dedicado

mas ao criar uma acc pelo site a mesma n e criada no server

apenas da a mensagem q foi criada no site mas no banco de dados ela n consta.

utilizando esse eite aqui

 

http://www.l2jbrasil.com/index.php?/topic/31138-web-sit-em-html-muito-bom/

 

Então no resumo total eu crio a conta no site mas ela n conta no banco de dados aenas diz q cria no site..

 

se alguem poder me dar um help ai ficarei muito grato

 

Obrigado.

Link para o comentário
Compartilhar em outros sites

13 respostass a esta questão

Posts recomendados

Poste o script e a estrutura da tabela 'accounts' da sua REV.

"In a way, the supernatural is what's behind the curtain. Normally, you only need to see what's happening on stage. That's how reality works. If you don't know then it's for the best. Actually, learning about the supernatural only increases the number of things you don't know."'

Link para o comentário
Compartilhar em outros sites


O conteúdo está oculto, favor efetuar login ou se cadastrar!

 

Uploaded with

O conteúdo está oculto, favor efetuar login ou se cadastrar!

agora a estrutura da tabela accounts isso n intendi direito.

espero ter sido isso oq pedio.

 

Uso a rev teon 650

Editado por stiv
Link para o comentário
Compartilhar em outros sites

Se você usa o navicat, clique com o botão direito na tabela 'accounts' e clique em 'Dump SQL File' e cole o conteudo do arquivo aqui no tópico.

Poste o código do registro em forma de texto também que facilita.

"In a way, the supernatural is what's behind the curtain. Normally, you only need to see what's happening on stage. That's how reality works. If you don't know then it's for the best. Actually, learning about the supernatural only increases the number of things you don't know."'

Link para o comentário
Compartilhar em outros sites

Ta ae

 

 

/*

Navicat MySQL Data Transfer

 

Source Server : localhost

Source Server Version : 50142

Source Host : localhost:3306

Source Database : l2jdb

 

Target Server Type : MYSQL

Target Server Version : 50142

File Encoding : 65001

 

Date: 2011-01-16 16:37:57

*/

 

SET FOREIGN_KEY_CHECKS=0;

 

-- ----------------------------

-- Table structure for `accounts`

-- ----------------------------

DROP TABLE IF EXISTS `accounts`;

CREATE TABLE `accounts` (

`login` varchar(45) NOT NULL DEFAULT '',

`password` varchar(45) DEFAULT NULL,

`lastactive` decimal(20,0) DEFAULT NULL,

`access_level` int(11) DEFAULT NULL,

`lastIP` varchar(20) DEFAULT NULL,

`email` varchar(150) NOT NULL,

`question` varchar(20) NOT NULL,

`answer` varchar(20) NOT NULL,

`lastServer` int(4) DEFAULT '1',

PRIMARY KEY (`login`)

) ENGINE=InnoDB DEFAULT CHARSET=latin1;

 

-- ----------------------------

-- Records of accounts

-- ----------------------------

REG.

 

<?php

$L2JBS_config["mysql_host"]="meuip"; // MySQL IP

$L2JBS_config["mysql_port"]=3306; // MySQP port

$L2JBS_config["mysql_db"]="l2jdb"; // l2jnet_db or your lineage 2 server database name

$L2JBS_config["mysql_login"]="root"; // MySQL Login name

$L2JBS_config["mysql_password"]="minha senha"; // MySQL Password

 

error_reporting(0);

?>

<?php

$L2JBS_config["javascript_sort_method"]="bubble";

$link = mysql_connect($L2JBS_config['mysql_host'].":".$L2JBS_config['mysql_port'], $L2JBS_config['mysql_login'], $L2JBS_config['mysql_password']);

if (!$link)

die("Couldn't connect to MySQL");

@mysql_select_db($L2JBS_config['mysql_db'], $link)

or die ('Error '.mysql_errno().': '.mysql_error());

 

?><style type="text/css">

<!--

body {

background-image: url(images/bg1.gif);

}

a:link {

color: #FF9900;

font-weight: bold;

text-decoration: none;

}

a:visited {

color: #CCCCCC;

text-decoration: none;

}

body,td,th {

font-family: Verdana, Arial, Helvetica, sans-serif;

color: #FFFFFF;

}

a:hover {

color: #FF9933;

text-decoration: none;

}

a:active {

color: #FF6600;

text-decoration: none;

}

.style11 {font-size: 12px}

.style12 {

color: #FFFFFF;

font-size: 36px;

}

-->

</style>

<script type="text/JavaScript">

<div align="center"><strong><font size="7" face="Verdana, Arial, Helvetica, sans-serif"><blink>Criar Conta Altomatica </blink></font></strong>

<br />

<br />

 

</div>

<div align="center">

<script type="text/javascript">//<![CDATA[

function isAlphaNumeric(value)

{

if (value.match(/^[a-zA-Z0-9]+$/))

return true;

else

return false;

}

function checkform(f)

{

if (f.account.value=="")

{

alert("Preencha todos os campos!");

return false;

}

if (!isAlphaNumeric(f.account.value))

{

alert("Preencha todos os campos!");

return false;

}

if (f.password.value=="")

{

alert("Sem Senha ");

return false;

}

if (!isAlphaNumeric(f.password.value))

{

alert("444444");

return false;

}

if (f.password2.value=="")

{

alert("Você não repetiu a senha");

return false;

}

if (f.password.value!=f.password2.value)

{

alert("Senhas não são iguais ");

return false;

}

return true;

}

//]]></script>

<font size="3"><span class="style18"><br />

</span></font><span class="style18"><span class="style16 style11"></span></span><span class="style11"></strong>

</h4>

</span></font><span class="style11">

</span></div>

<center><B>Cadastrar Conta</B></head></center><br>

<form method="post" action="reg.php" onsubmit="return checkform(this)">

<center><table>

<tr>

<td><div align="right"><span class="style11"><b><font face="Trebuchet MS">Login - </font></b></span></div></td>

<td><font face="Trebuchet MS" size="1"><b>

<input type="text" name="account" maxlength="15" size="20" /></b></font></td>

</tr>

<tr>

<td><div align="right"><span class="style11"><b><font face="Trebuchet MS">Senha - </font></b></span></div></td>

<td><font face="Trebuchet MS" size="1"><b>

<input type="password" name="password" maxlength="15" size="20" /></b></font></td>

</tr>

<tr>

<td><div align="right"><span class="style11"><b><font face="Trebuchet MS">Repetir Senha - </font></b></span></div></td>

<td><font face="Trebuchet MS" size="1"><b>

<input type="password" name="password2" maxlength="15" size="20" /></b></font></td>

</tr>

<tr>

<td colspan="2" style="text-align: center;">

<font size="1" face="Trebuchet MS"><b><br />

<input type="submit" name="submit" value="Criar CONTA" />

</b></font></td>

</tr>

</table></center>

</form>

 

<?php

if(ereg("^([a-zA-Z0-9_-])*$", $_POST['account']) && ereg("^([a-zA-Z0-9_-])*$", $_POST['password']) && ereg("^([a-zA-Z0-9_-])*$", $_POST['password2']))

{

if ($page="index.php" && $_POST['account'] && strlen($_POST['account'])<16 && strlen($_POST['account'])>3 && $_POST['password'] && $_POST['password2'] && $_POST['password']==$_POST['password2'])

{

$check=mysql_query("select * from accounts where login='".$_POST['account']."'");

$check1=mysql_num_rows($check);

if($check1>0)

{

echo "<p clss='error'><b>Falha no Registro, Conta ja Existente .</b></p>";

}

else

{

mysql_query("INSERT INTO accounts (login, password, access_level) VALUES ('".$_POST['account']."', '".base64_encode(pack('H*', sha1($_POST['password'])))."', 0)", $link);

mysql_close($link);

print '<p class="error"><b>Resgistro Completo... Conta Criada </b></p>';

}

}

else

{

print '<p class="error"><b> </b></p>'.mysql_error();

}

}

else

{

echo "As limitações não foram testadas para a segurança. Se você for confiável que tido a informação correta, consultar por favor à administração. ";

}

?>

<?php

$L2JBS_config["mysql_host"]="meu ip"; // MySQL IP

$L2JBS_config["mysql_port"]=3306; // MySQP port

$L2JBS_config["mysql_db"]="l2jdb"; // l2jnet_db or your lineage 2 server database name

$L2JBS_config["mysql_login"]="root"; // MySQL Login name

$L2JBS_config["mysql_password"]="minha senha"; // MySQL Password

 

error_reporting(0);

?>

<?php

$L2JBS_config["javascript_sort_method"]="bubble";

$link = mysql_connect($L2JBS_config['mysql_host'].":".$L2JBS_config['mysql_port'], $L2JBS_config['mysql_login'], $L2JBS_config['mysql_password']);

if (!$link)

die("Couldn't connect to MySQL");

@mysql_select_db($L2JBS_config['mysql_db'], $link)

or die ('Error '.mysql_errno().': '.mysql_error());

 

?><style type="text/css">

<!--

body {

background-image: url(imagens/index_r14_c3.gif);

}

a:link {

color: #FF9900;

font-weight: bold;

text-decoration: none;

}

a:visited {

color: #CCCCCC;

text-decoration: none;

}

body,td,th {

font-family: Verdana, Arial, Helvetica, sans-serif;

color: #FFFFFF;

}

a:hover {

color: #FF9933;

text-decoration: none;

}

a:active {

color: #FF6600;

text-decoration: none;

}

.style12 {

color: #FFFFFF;

font-size: 36px;

}

-->

</style>

<script type="text/javascript">//<![CDATA[

function isAlphaNumeric(value)

{

if (value.match(/^[a-zA-Z0-9]+$/))

return true;

else

return false;

}

function checkform(f)

{

if (f.account.value=="")

{

alert("Preencher todos os campos do formularios ");

return false;

}

if (!isAlphaNumeric(f.account.value))

{

alert("Preencher todos os campos do formularios");

return false;

}

if (f.oldpassword.value=="")

{

alert("Você colocou sua senha antiga");

return false;

}

if (f.newpassword.value=="")

{

alert("Nenhuma senha detectada no campo");

return false;

}

if (!isAlphaNumeric(f.newpassword.value))

{

alert("44444");

return false;

}

if (f.newpassword2.value=="")

{

alert("Você não repetiu a senha");

return false;

}

if (f.newpassword.value!=f.newpassword2.value)

{

alert(" Senha não é igual! ");

return false;

}

return true;

}

//]]></script>

<link href="style.css" rel="stylesheet" type="text/css">

<title>Trocar Senha</title></head>

<style type="text/css">

<!--

.Estilo1 {

color: #FFFFFF;

font-family: "Courier New", Courier, monospace;

}

color: #FFFFFF;

font-weight: bold;

}

-->

.Estilo4 {font-size: 10px; font-weight: bold; }

.Estilo6 {color: #FFFFFF}

-->

</style>

<body>

<form method="post" action="?ir=lembrarsenha" onSubmit="return checkform(this)">

<center>

<font face="Verdana, Arial, Helvetica, sans-serif"><strong><span class="Estilo1">Trocar </span><span class="Estilo6">senha<br>

</span><font color="#FF0000" size="4">

</font></strong></font> <br>

<table background="imagens/imagens/home_r6_c1.gif">

<tr>

<td><div align="right"><span class="style11"><b><font face="Trebuchet MS">Login - </font></b></span></div></td>

<td>

<font size="1"><b>

<input name="account" type="text" class="camp1" style="font-family: Trebuchet MS; " size="20" maxlength="15" />

</b></font></td>

</tr>

<tr>

<td><div align="right"><span class="style11"><b><font face="Trebuchet MS">Senha Atual - </font></b></span></div></td>

<td><font size="1"><b>

<input name="oldpassword" type="password" class="camp1" style="font-family: Trebuchet MS; " size="20" maxlength="15" />

</b></font></td>

</tr>

<tr>

<td><div align="right"><span class="style11"><b><font face="Trebuchet MS">Nova Senha - </font></b></span></div></td>

<td><font size="1"><b>

<input name="newpassword" type="password" class="camp1" style="font-family: Trebuchet MS; " size="20" maxlength="15" />

</b></font></td>

</tr>

<tr>

<td><div align="right"><span class="style11"><b><font face="Trebuchet MS">Repetir - </font></b></span></div></td>

<td><font size="1"><b>

<input name="newpassword2" type="password" class="camp1" style="font-family: Trebuchet MS; " size="20" maxlength="15" />

</b></font></td>

</tr>

<tr>

<td colspan="2" style="text-align: center;"><font size="1"><b>

<input name="submit" type="submit" class="camp1" style="font-family: Trebuchet MS" value="Trocar SENHA" />

</b></font></td>

</tr>

</table>

</center>

</form>

<center>

<?php

if(ereg("^([a-zA-Z0-9_-])*$", $_POST['account']) && ereg("^([a-zA-Z0-9_-])*$", $_POST['oldpassword']) && ereg("^([a-zA-Z0-9_-])*$", $_POST['newpassword']) && ereg("^([a-zA-Z0-9_-])*$", $_POST['newpassword2']))

{

if ($page='index.php' && $_POST['account'] && strlen($_POST['account'])<16 && $_POST['oldpassword'] && $_POST['newpassword'] && $_POST['newpassword']==$_POST['newpassword2'])

{

$result=mysql_query("SELECT login,password FROM accounts WHERE login='".@mysql_real_escape_string($_POST['account'])."' AND password='".base64_encode(pack('H*', sha1($_POST['oldpassword'])))."'", $link)

or die ("Error: ".mysql_error());

if (mysql_num_rows($result))

{

mysql_query("UPDATE accounts SET password='".base64_encode(pack('H*', sha1($_POST['newpassword'])))."' WHERE login='".mysql_real_escape_string($_POST['account'])."'", $link)

or die ("Error: ".mysql_error());

print "<p style=\"font-weight: bold;\"><font size=1 color=ffffff>Senha modificada. </font> </p>";

}

else

print "<p class=\"error\"><font size=1 color=ffffff>Ouve algum erro, tente novamente. </font> </p>";

mysql_close($link);

}

}

else

{

echo "<font size=1 color=ffffff>As limitações não foram testadas para a segurança. Se você for confiável que tido a informação correta, consultar por favor à administração.</font>";

}

?>

</center>

</body>

</html>

 

 

Editado por Williamfs
Use [spoiler] para textos longos
Link para o comentário
Compartilhar em outros sites

Posta o registro em forma de texto também, senão não tem como te ajudar..

 

~~

 

Usa esse e ve se vai dar algum erro (ainda não corrigi, alterei para encontrar o erro).

 

O conteúdo está oculto, favor efetuar login ou se cadastrar!

 

Editado por Williamfs
Use [spoiler] para textos longos

"In a way, the supernatural is what's behind the curtain. Normally, you only need to see what's happening on stage. That's how reality works. If you don't know then it's for the best. Actually, learning about the supernatural only increases the number of things you don't know."'

Link para o comentário
Compartilhar em outros sites

Só executar essa SQL e testar:

O conteúdo está oculto, favor efetuar login ou se cadastrar!

Editado por Rhion

"In a way, the supernatural is what's behind the curtain. Normally, you only need to see what's happening on stage. That's how reality works. If you don't know then it's for the best. Actually, learning about the supernatural only increases the number of things you don't know."'

Link para o comentário
Compartilhar em outros sites

Execute esta SQL, tente criar uma conta e tente abrir o login.

Se ocorrer algum erro poste-o.

 

O conteúdo está oculto, favor efetuar login ou se cadastrar!

Editado por Rhion

"In a way, the supernatural is what's behind the curtain. Normally, you only need to see what's happening on stage. That's how reality works. If you don't know then it's for the best. Actually, learning about the supernatural only increases the number of things you don't know."'

Link para o comentário
Compartilhar em outros sites

Pelo que entendi este erro não tem haver pela altereção, pois está dizendo que algo ja está em uso, porém não sei como arrumar.. =/

"In a way, the supernatural is what's behind the curtain. Normally, you only need to see what's happening on stage. That's how reality works. If you don't know then it's for the best. Actually, learning about the supernatural only increases the number of things you don't know."'

Link para o comentário
Compartilhar em outros sites

O conteúdo está oculto, favor efetuar login ou se cadastrar!

 

Amigo dono do tópico leia e cumpra as regras, seu tópico é na verdade uma duvida, não um pedido, a área correta seria a de dúvidas!

 

estou movendo o tópico para a área correta!

Link para o comentário
Compartilhar em outros sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Visitante
Responder esta pergunta...

×   Você colou conteúdo com formatação.   Remover formatação

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Processando...




×
×
  • Criar Novo...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.