Ultima modifica da un moderatore:
questo script serve per uppare l'ip a un gm
nome file : update.php
script:
per configurarlo
la pass serve per non far usare lo script ai nabbetti è.é
Dovete creare un immagine bt_confirm.gif che sara il bottone di conferma e dovete avere lo script conn.php tutto nella stessa cartella...per usarlo andate qui e vedrete il vostro ip e lo mettete nella barra "indirizzo ip"....
nome file : update.php
script:
PHP:
<?php
$action=@$_POST["action"];
switch ($action){
case "send":
send();
break;
default:
change();
break;
}
function change(){
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>Crediti NikoAsBari</title>
<link rel="stylesheet" href="css/index.css">
<link href="images/css.css" rel="stylesheet" type="text/css">
<style type="text/css">
</style>
</head>
<body>
<table background=images/middle.gif border=0 cellpadding=0 cellspacing=0 width=466 align="center">
<tbody>
<tr>
<td width="466" height="200" align=middle valign=top>
<form method=post name=chgform action="update.php">
<input type="hidden" name="action" value="send" />
<table border=0 cellpadding=0 cellspacing=0 width=466>
<tbody>
<tr>
<td width="466"><br>
<b><font size="3">¡¡</font><span class="style1">Update Tool</span></b> <span class="style1"><font
color=#cc3300><font color="#0033FF">- Utilizzo riservato allo Staff</font></font><font
color=#cc3300></font></span></td>
</tr>
<tr>
<td height=1><img height=1 src="" width=300></td>
</tr>
<tr>
<td align=right>¡¡
<div align="left"></div>
<table align=center border=0 cellpadding=5 cellspacing=1 width="425">
<tbody>
<tr>
<td align=right class=txt_gray colspan=2>
div align=left><font
color=#cc3300>Compilare i seguenti campi </font></div>
</td>
</tr>
<tr align="left" valign="middle">
<td class=txt_gray width="184" height="32">
<div align=left>NickName PG</div>
</td>
<td class=txt_gray width="218" height="32">
<input maxlength=16 name=UserID size=17>
<div align=center></div>
</td>
</tr>
<tr align="left" valign="middle">
<td class=txt_gray width="184">Password Tool</td>
<td class=txt_gray width="218">
<input maxlength=7 name=srcno size=7>
</td>
</tr>
<tr align="left" valign="middle">
<td class=txt_gray width="184">Inidirizzo IP</td>
<td class=txt_gray width="218">
<input maxlength=30 name=password1 size=20>
</td>
</tr>
<tr align="left" valign="middle">
<td class=txt_gray width="184"></td>
<td class=txt_gray width="218">
</td>
</tr>
<tr align="left" valign="middle">
<td class=txt_gray width="184"></td>
<td class=txt_gray width="218">
</td>
</tr>
</tbody>
</table>
<div align="left"></div> </td>
</tr>
<tr>
<td height=2><img height=1 src=""
width=466></td>
</tr>
</tbody>
</table>
<div align="center"><br>
<a
href="javascript:document.chgform.submit()"><img border=0 src="bt_confirm.gif" width="79" height="32"></a>
<br>
<br>
</div>
</form> </td>
</tr>
</tbody>
</table>
<div align="left"></div>
</body>
</html>
<?php
}
function send(){
$srcno=$_POST["srcno"];
if ($srcno != "PASS")
{echo "Password Tool Errata.<a href=\"javascript:history.back();\">Torna Inidietro!</a>";exit;
}else{
$UserID=$_POST["UserID"];
$password1=$_POST["password1"];
require_once("conn.php");
mysql_select_db("common");
$exec="update gmlist set mContactIP='$password1' where mName='$UserID'";
$result=mysql_query($exec);
echo "Update Riuscito con Successo.";exit;
}
}
per configurarlo
PHP:
if ($srcno != "PASS")
la pass serve per non far usare lo script ai nabbetti è.é
Dovete creare un immagine bt_confirm.gif che sara il bottone di conferma e dovete avere lo script conn.php tutto nella stessa cartella...per usarlo andate qui e vedrete il vostro ip e lo mettete nella barra "indirizzo ip"....