Ir para conteúdo
  • Cadastre-se

[PROJETO] [site] Painel de usuario Avançado!


mephistor

Posts recomendados

ajudem se possivel...

 

Bom! Gente faz algum tempo que estou trabalhando neste painel para os usuários de site de lineage2.

 

Não tenho muito conhecimento em php em tão pouco HTML, mas sei que e vital

 

Poder administrar os personagens, seus itens ,skills e buffs , teleportes e talvez ate vender itens pelo site, e montar estratégias para ficar no top do Server sei que isso e muito bom

 

Fiz este painel pensando em ganhar dinheiro mas como compartilhar as vezes e mas vantajoso do que vender uma idéia estar aqui alguns ss’s .

se caso tiver alguém interessado em reformular este painel entre em contato pelo Orkut, através do email [email protected]

 

PROJETO 75% CONCLUIDO...

funções

ver status 95% concluido..

ver e remover Buffs 85% concluido.. ainda com erro de duplicação mostrando de duas veses a mesmo buff.

ver armors 90% concluido..

ver weapons 90% concluido..

ver add enchant 90% concluido..

ver remover enchant 90% concluido..

 

add futuros

mercado de itens do usuario..

com loja virtual..

 

a data base utilizada e a do server interdarck apenas sincronizei os tabelas accounts,characters do server que eu tinha para o db do intedarck .

 

para rodar o scriopt crie uma pasta com o nome de Connections e dentro dela criar um arquivo com o nome site.php

 

e colar o codigo que postei abaixo.

 

tbm tem que criar um index.php para fazer o login..redimencionando para o arquivo status.php

 

By ]-=Mephistor=-[

SS

armo.jpg

 

userh.jpg

 

SCRIPT ESTADO EM DB L2EMU ...

REMOVA A OPÇÃO DISPLEY ERRO DO WAMP OU OUTRO PROGRAMA EMULADOR DE PHP.

PARA NAO APARECER NOTIFICAÇÃO DE ERROS.

 

crie uma arquivo com o nome de status.php

 

<?php
//initialize the session
if (!isset($_SESSION)) {//By Mephistor email [email protected] ou [email protected]
 session_start();
}

// ** Logout the current user. **
$logoutAction = $_SERVER['PHP_SELF']."?doLogout=true";
if ((isset($_SERVER['QUERY_STRING'])) && ($_SERVER['QUERY_STRING'] != "")){//By Mephistor email [email protected] ou [email protected]
 $logoutAction .="&". htmlentities($_SERVER['QUERY_STRING']);
}

if ((isset($_GET['doLogout'])) &&($_GET['doLogout']=="true")){//By Mephistor email [email protected] ou [email protected]
 //to fully log out a visitor we need to clear the session varialbles
 $_SESSION['MM_Username'] = NULL;
 $_SESSION['MM_UserGroup'] = NULL;
 $_SESSION['PrevUrl'] = NULL;
 unset($_SESSION['MM_Username']);
 unset($_SESSION['MM_UserGroup']);
 unset($_SESSION['PrevUrl']);

 $logoutGoTo = "/index.php";
 if ($logoutGoTo) {//By Mephistor email [email protected] ou [email protected]
header("Location: $logoutGoTo");
exit;
 }
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>PAINEL DE CONTRO E ADMINISTRAÇÃO DO USUARIO</title>
<style type="text/css">
<!--
.titulo {//By Mephistor email [email protected] ou [email protected]
color: #FFF;
font-family: "Comic Sans MS", cursive;
}
-->
</style>
<script type="text/javascript">
<!--
function MM_jumpMenuGo(objId,targ,restore){ //v9.0
 var selObj = null;  with (document) { ///////////By Mephistor email [email protected] ou [email protected]
 if (getElementById) selObj = getElementById(objId);
 if (selObj) eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
 if (restore) selObj.selectedIndex=0; }
}
//-->
</script>
</head>
<?
include "css.php";
?>
<?
include "Connections/site.php";
$link = mysql_connect($hostname_site,$username_site,$password_site)or die('Erro ao conectar no MySQL');
mysql_select_db($database_site,$link) or die('Erro na base');
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////By Mephistor email [email protected] ou [email protected]//////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
?>
<body>
<table width="852" border="0" align="center">
 <tr>
<td align="center" bgcolor="#999999"><strong class="titulo">PAINEL DE CONTRO E ADMINISTRAÇÃO DO USUARIO</strong></td>
 </tr>
</table>
<hr />
<fieldset>
 <legend>Conta</legend>
 <table width="818" border="0" align="center" cellpadding="3" cellspacing="3">
<?
/*********************************/
/******Configuração de Login*****/
/*******************************/
$login_user = $_SESSION['MM_Username'];
$pegarlogin = mysql_query("select * from accounts where login = '".$login_user."'");
$resultado_login = mysql_fetch_array($pegarlogin);
?>
<tr>
  <td width="198">Conta:  <? echo $resultado_login['login'];?></td>
  <td width="228">Ip:  <? echo $resultado_login['lastIP'];?></td>
  <td width="332">E-mail:  <? echo $resultado_login['email'];?></td>
  <td width="32"><a href="<? echo $logoutAction ?>">Siar</a></td>
</tr>
 </table>
</fieldset>
<hr />
<?
/*********************************/
/******Configuração do char*****/
/*******************************/
$login_user = $_SESSION['MM_Username'];
$pegarchars = mysql_query("select * from characters where account_name = '".$login_user."'");
while($resultado_chars = mysql_fetch_array($pegarchars)){//By Mephistor email [email protected] ou [email protected]
$charId = $resultado_chars['charId'];
if($resultado_chars['online']==0){//By Mephistor email [email protected] ou [email protected]
$charstatus = "Offline";}else{//By Mephistor email [email protected] ou [email protected]
$charstatus = "Online";
}
if($resultado_chars['accesslevel'] == 0){$access = "Usuario";}
if($resultado_chars['accesslevel'] == 1){$access = "Admin";}
if($resultado_chars['accesslevel'] == 2){$access = "Head GM";}
if($resultado_chars['accesslevel'] == 3){$access = "Event GM";}
if($resultado_chars['accesslevel'] == 4){$access = "Support GM";}
if($resultado_chars['accesslevel'] == 5){$access = "General GM";}
if($resultado_chars['accesslevel'] == 6){$access = "GM Test";}
if($resultado_chars['accesslevel'] >= 7){$access = "GM Master";}
if ($resultado_chars['race']==5) { $race="kameal"; }
if ($resultado_chars['race']==4) { $race="Dwarf"; }
if ($resultado_chars['race']==2) { $race="Dark elf"; }
if ($resultado_chars['race']==0) { $race="Human"; }
if ($resultado_chars['race']==1) { $race="elf"; }
if ($resultado_chars['race']==3) { $race="Orc"; }
if ($resultado_chars['sex']==1) { $sex="Feminino"; }
if ($resultado_chars['sex']==0) { $sex="Masculino"; }
if ($resultado_chars['noble']==0) { $noble="Não"; }
if ($resultado_chars['noble']==1) { $noble="Sim"; }
if ($resultado_chars['charViP']==0) { $charViP="não"; }
if ($resultado_chars['charViP']==1) { $charViP="Sim"; }

?>
<fieldset>
 <legend>Character</legend>
 <table width="852" border="0" align="center" cellpadding="3" cellspacing="3">
<tr>
  <td width="329" height="23" bgcolor="#999999">Char:  <? echo $resultado_chars['char_name'];?>   <a href="status.php?info=detalhe&id=<? echo $charId;?>">Detalhe</a>|<a href="status.php?info=armor&id=<? echo $charId;?>">Armor</a>|<a href="status.php?info=waepon&id=<? echo $charId;?>">Weapon</a>|
  <a href="status.php?info=buffs&id=<? echo $charId;?>">Buffs</a></td>
  <td width="60" bgcolor="#CCCCCC">Level:   <? echo $resultado_chars['level'];?></td>
  <td width="171" bgcolor="#999999">Titulo:   <? echo $resultado_chars['title'];?></td>
  <td width="147" bgcolor="#CCCCCC">Lvl Acess:  <? echo $access;?></td>
  <td width="97" bgcolor="#999999">Status:  <? echo $charstatus;?></td>
</tr>
 </table>
</fieldset>
<?
}
?>
<?
/*********************************/
/***pegar informações do char****/
/*******************************/
if($_GET['info'] == "detalhe"){//By Mephistor email [email protected] ou [email protected]
$id = $_GET['id'];
$info_char = mysql_query("select * from characters where charId = '$id'");
$resultado_info = mysql_fetch_array($info_char);
$clanid = $resultado_info['clanid'];
$classid = $resultado_info['classid'];
$classbase = $resultado_info['base_class'];
/*********************************/
/***pegar informações do clan****/
/*******************************/
$info_olimp = mysql_query("select * from olympiad_nobles where charId = '$id'");
$resultado_info7 = mysql_fetch_array($info_olimp);
$olimppoint = $resultado_info7['olimpiad_points'];
/*********************************/
/***pegar informações do clan****/
/*******************************/
$info_clan = mysql_query("select * from characters,clan_data where clan_id = '$clanid'");
$resultado_info2 = mysql_fetch_array($info_clan);
if ($resultado_info2['clan_name']==0) { $clan ="Não";}
/*********************************/
/**pegar informações do donator**/
/*******************************/
$info_donator = mysql_query("select * from characters_custom_data where charId = '$id'");
$resultado_info3 = mysql_fetch_array($info_donator);
if ($resultado_info3['donator']=='') { $donator  ="Não"; }
if ($resultado_info3['donator']==0) { $donator  ="Não"; }
if ($resultado_info3['donator']==1) { $donator  ="Sim"; }
/*********************************/
/***pegar informações do classe**/
/*******************************/
$info_classe = mysql_query("select * from char_templates where ClassId = '$classid'");
$resultado_info5 = mysql_fetch_array($info_classe);
$classname = $resultado_info5['ClassName'];
/*********************************/
/***pegar informações do classe**/
/*******************************/
$info_classeB = mysql_query("select * from char_templates where ClassId = '$classbase'");
$resultado_info6 = mysql_fetch_array($info_classeB);
$classBname = $resultado_info6['ClassName'];
/*********************************/
/***pegar informações do classe**/
/*******************************/
?>
<hr />
<fieldset>
 <legend>Status</legend>
 <table width="852" border="0" align="center" cellpadding="3" cellspacing="3">
<tr bgcolor="#CCCCCC">
  <td width="134">Hp:  <? echo $resultado_info['maxHp'];?> / <? echo $resultado_info['curHp'];?></td>
  <td width="190">Mp:  <? echo $resultado_info['maxMp'];?> / <? echo $resultado_info['curMp'];?></td>
  <td width="196">Cp:  <? echo $resultado_info['maxCp'];?> / <? echo $resultado_info['curCp'];?></td>
  <td width="134">Sp:  <? echo $resultado_info['sp'];?></td>
  <td width="116">Xp:  <? echo $resultado_info['exp'];?></td>
</tr>
<tr bgcolor="#999999">
  <td>Recomendações:</td>
  <td>Pk:  <? echo $resultado_info['pkkills'];?></td>
  <td>PvP:  <? echo $resultado_info['pvpkills'];?></td>
  <td>Karma:  <? echo $resultado_info['karma'];?></td>
  <td>Raça:  <? echo $race; ?></td>
</tr>
<tr bgcolor="#CCCCCC">
  <td>s***:  <? echo $sex; ?></td>
  <td>C.Atual: <? echo $classBname;?></td>
  <td>C. Base: <? echo $classname;?></td>
  <td>Vip:  <? echo $charViP;?></td>
  <td>Nobless:  <? echo $noble;?></td>
</tr>  
<tr bgcolor="#999999">
  <td>Coladorador: <? echo $donator;?></td>
  <td>Clan: <? echo $resultado_info2['clan_name'];?></td>
  <td>Lvl:  <? echo $resultado_info2['clan_level'];?></td>
  <td>Rep***ção: <? echo $resultado_info2['rep***tion_score'];?></td>
  <td>Pontos olimp: <? echo $olimppoint;?></td>
</tr>
<?
}
 ?>

</table>
</fieldset>
<fieldset>
<legend>Armors</legend>
<table width="852" border="0" align="center" cellpadding="3" cellspacing="3">
 <?
if($_GET['info'] == "armor"){//By Mephistor email [email protected] ou [email protected]
$id_iten = $_GET['id'];
$itens_set = mysql_query("select * from items where owner_id='".$id_iten."'");
while($resultado_infoset = mysql_fetch_array($itens_set)){
$link1 = $resultado_infoset['item_id'];
$resul = $resultado_infoset['enchant_level'];
?>
 <?
$sql2= mysql_query("select name from armor where item_id='".$link1."'");
while($busca=mysql_fetch_array($sql2)){
?>
 <tr>
<td width="267" bgcolor="#999999">Iten: <? echo $busca['name'];?></td>
<td width="221" bgcolor="#CCCCCC">Enchant: + <? echo $resul; ?></td>
<td width="160" bgcolor="#999999"><div align="center">Excluir</div></td>
<td width="165" bgcolor="#999999"><div align="center">Add Enchant</div></td>
 </tr>
 <?
 }}}
 ?>
 </table>
</fieldset>
<fieldset>
<legend>Weapons</legend>
 <?
if($_GET['info'] == "waepon"){//By Mephistor email [email protected] ou [email protected]
$id_iten2 = $_GET['id'];
$itens_set1 = mysql_query("select * from items where owner_id='".$id_iten2."'");
while($resultado_infoset1 = mysql_fetch_array($itens_set1)){
$link2 = $resultado_infoset1['item_id'];
$resu2 = $resultado_infoset1['enchant_level'];
?>
  <table width="852" border="0" align="center" cellpadding="3" cellspacing="3">
 <?
$sql3= mysql_query("select * from weapon where item_id='".$link2."'");
while($busca1=mysql_fetch_array($sql3)){//By Mephistor email [email protected] ou [email protected]
?> 
<tr>
<td width="267" bgcolor="#999999">Iten: <? echo $busca1['name'];?></td>
<td width="221" bgcolor="#CCCCCC">Enchant: + <? echo $resu2; ?></td>
<td width="161" bgcolor="#999999"><div align="center">Excluir</div></td>
<td width="164" bgcolor="#999999"><div align="center">Add Enchant</div></td>
</tr>
<?
 }}}
 ?>
</table>
</fieldset>
<fieldset>
<legend>Buffs</legend>
  <table width="852" border="0" align="center" cellpadding="3" cellspacing="3">
<?
if($_GET['info'] == "buffs"){//By Mephistor email [email protected] ou [email protected]
$id_iten3 = $_GET['id'];
$itens_set2 = mysql_query("select * from character_skills_save where charId='".$id_iten3."'");
while($resultado_infoset2 = mysql_fetch_array($itens_set2)){//By Mephistor email [email protected] ou [email protected]
?>
 <?
$sql4= mysql_query("select * from buff_templates where skill_id='".$resultado_infoset2['skill_id']."'");
while($busca2=mysql_fetch_array($sql4)){//By Mephistor email [email protected] ou [email protected]
?> 
<tr>
<td width="267" bgcolor="#999999">Iten: <? echo $busca2['skill_name'];?></td>
<td width="221" bgcolor="#CCCCCC">Levelt: <? echo $resultado_infoset2['skill_level']; ?></td>
<td width="124" bgcolor="#999999">Tempo:</td>
<td bgcolor="#CCCCCC"><div align="center">Remover</div></td>
</tr>
<?
 }}}
 ?>
</table>
</fieldset>
</body>
</html>

 

 

crie uma pasta com o nome de Connections e dentro dela crie um arquivo com o nome de site.php

 

 

<?php
# FileName="Connection_php_mysql.htm"
# Type="MYSQL"
# HTTP="true"
$hostname_site = "localhost";
$database_site = "l2jdb"; 
$username_site = "root";
$password_site = "l2ct2v1";
$site = mysql_pconnect($hostname_site, $username_site, $password_site) or trigger_error(mysql_error(),E_USER_ERROR); 
?>

Editado por mephistor

Projeto L2JSites By Mephistor

Iniciado em 11-02-2011 webdesign

Contato: E-mail:[email protected]

Link para o comentário
Compartilhar em outros sites


Posta o backup ai que tento terminar ele hoje mesmo.

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

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

×   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...
  • Registre-se

    Faça parte da maior e  mais antigas comunidades sobre Lineage2 da América Latina.





×
×
  • 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.