Pradinis
Pagalba
Užsisakyk!
- Reklamą
- Hostingą
- El. pašto dėžutę
Užsisakyk!
Įrankiai
Pasidalink
- Visos temos
1. Sukurkite unregister.php failą ir įterpkite šį kodą:
<?php 2. Jei norite, kad nuoroda į išsiregistravimą atsirastų vartotojo meniu, infusions/user_info_panel/user_info_panel.php faile kodą pakeiskite šiuo: <?php | Straipsnio informacijaAutoriusRytis Parašymo data 2007 gruodžio 16 14:12:02 Komentarų 24 Skaityta 1975 Spausdinti |
dbquery("DELETE FROM ".$db_prefix."users WHERE user_id='".$userdata['user_id']."' AND user_password='".$passw1."'");
dbquery("DELETE FROM ".$db_prefix."posts WHERE post_author='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."submissions WHERE submit_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."messages_options WHERE user_id='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."online WHERE online_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."threads WHERE thread_author='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."thread_notify WHERE notify_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."poll_votes WHERE vote_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."ratings WHERE rating_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."shoutbox WHERE shout_name='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."messages WHERE message_from='".$userdata['user_id']."' AND message_to='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."comments WHERE comment_name='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."users WHERE user_id='".$userdata['user_id']."' AND user_password='".$passw1."'");
<?php
/*---------------------------------------------------+
| PHP-Fusion 6 Content Management System
+----------------------------------------------------+
| Copyright � 2002 - 2006 Nick Jones
| http://www.php-fusion.co.uk/
+----------------------------------------------------+
| Released under the terms & conditions of v2 of the
| GNU General Public License. For details refer to
| the included gpl.txt file or visit http://gnu.org
+----------------------------------------------------+
| Unreg addon created by Rytis S. (webdnd.com)
+----------------------------------------------------*/
require_once "maincore.php";
require_once "subheader.php";
require_once "side_left.php";
if(!iMEMBER || iADMIN){redirect('news.php');}
opentable('Išsiregistruoti');
if(!$step)
{
echo"
<center>
<form name='unreg' method='post' action='unregister.php?step=ok'>
<table align='center' cellpadding='0' cellspacing='0'>
<tr>
<td class='tbl'>Įveskite savo slaptažodį:<span style='color:#ff0000'>*</span></td>
<td class='tbl'><input type='password' name='passwrodas' maxlength='30' class='textbox' style='width:200px;'></td>
</tr>
<tr>
<td colspan='2'><input type='submit' value='Išsiregistruoti' class='button' style='width:300px'></td>
</table>
<br/><br/>
<span style='color:#ff0000'><b>DĖMESIO:</b> atlikę šį veiksmą jūs ištrinsite šį vartotoją ir visus su juo susijusius duomenis. Prašome rimtai apmąstyti šį žingsnį.</span>
</form>
</center> ";
}
else
{
$passw1 = addslashes(md5(md5($_POST['passwrodas'])));
$passw2 = $userdata['user_password'];
if($passw1 == $passw2){
dbquery("DELETE FROM ".$db_prefix."posts WHERE post_author='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."submissions WHERE submit_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."messages_options WHERE user_id='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."online WHERE online_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."threads WHERE thread_author='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."thread_notify WHERE notify_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."poll_votes WHERE vote_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."ratings WHERE rating_user='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."shoutbox WHERE shout_name='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."messages WHERE message_from='".$userdata['user_id']."' AND message_to='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."comments WHERE comment_name='".$userdata['user_id']."'");
dbquery("DELETE FROM ".$db_prefix."users WHERE user_id='".$userdata['user_id']."' AND user_password='".$passw1."'");
echo"Jūs išsiregistravote. ";
}
else
{
echo"<span style='color:#ff0000'><b>Neteisingai įvedėte slaptažodį</b></span><br/><br/>
<a href='unregister.php'>Bandyti dar kartą</a>";
}
}
closetable();
require_once "side_right.php";
require_once "footer.php";
?>
if (isset($_POST['unregister_profile'])) redirect(BASEDIR."unregister.php");
<input type='submit' name='update_profile' value='".$locale['460']."' class='button'>";
if (!iADMIN) {
echo " <input type='submit' name='unregister_profile' value='".$locale['u019']."' class='button'></td>
</tr>
</table>
</form>\n";
}
else {
echo "</td>
</tr>
</table>
</form>\n";
}