Kefiirs Posted January 21, 2008 Report Share Posted January 21, 2008 (edited) Nu es esmu uztaisījis sadaļu "ziedo serverim" un gribu uztaisīt skriptu "nika reģistrācija"! Man vajadzētu šim te skriptam pielikt klāt "reģistrāciju ar SMS palīdzību" PARASTĀ REĢISTRĀCIJA! <? $nick = $_POST['nickname']; $pass = $_POST['password']; $pass2 = $_POST['pw_coniform']; $access = "z"; $flags = "a"; $nickname = "regnick"; $ip = $_SERVER['REMOTE_ADDR']; $id = "6"; if($pass == $pass2){ echo ""; }else{ die ("<script>alert('Paroles nesakrit!');window.back()</script>"); } if(empty($nick)){ die ("<script>alert('Ieraksti niku!'); window.back()</script>"); } if(empty($pass)){ die ("<script>alert('Ieraksti paroli!'); window.back()</script>"); } include('config.php'); $check = mysql_query("SELECT username FROM amx_amxadmins WHERE username='$nick'"); $exist = mysql_num_rows($check); if($exist > 0){ echo "<script>alert('Tads niks ir jau registrets!');window.back()</script>"; unset($nick); exit(); } $register = "INSERT INTO amx_amxadmins ( username, password, access, flags, nickname) VALUES('$nick', '$pass', '$access', '$flags', '$nickname')"; mysql_query($register) or die(mysql_error()); mysql_close(); echo "Registracija pabeikta!"; //header('location: index.php'); ?> <? $host = "localhost"; $db = "amxbansdatubāze"; $mysql_user = "lietotājs"; $mysql_pw = "parole"; mysql_connect ($host, $mysql_user, $mysql_pw)or die("neizdevas piekonekteeties: ".mysql_error()); mysql_select_db($db) or die(mysql_error()); ?> <html> <head> <title>Nick Registration</title> </head> <body> <center> <form method="post" action="add.php"> <table border="1"> <tr><td>Niks</td><td><input type="text" name="nickname"></td></tr> <tr><td>Parole</td><td><input type="text" name="password"></td></tr> <tr><td>Apstiprini Paroli</td><td><input type="text" name="pw_coniform"></td></tr> <tr><td></td><td><input type="submit" value="Registret"></td></tr> </table> </form> </center> </body> </html> REĢISTRĀCIJA AR SMS! <? //noradam failu kur saglabasies ziedotaji $uberfails = "regnicks.php"; $teksts= $_GET['message']; $fails = fopen("$uberfails", "a"); fwrite($fails,$teksts); fclose($fails); echo ('Paldies, ka reģistrējāt savu spēlētāja niku!') ?> Man vajag, lai viņu pieliktu klāt pirmajam skriptam, tā lai reģistrācija notiktu ar SMS palīdzību! SMS'ā lai būtu jāraksta: REG SERVERIS NIKS PAROLE Edited January 21, 2008 by Kefiirs Link to comment Share on other sites More sharing options...
Aleksejs Posted January 21, 2008 Report Share Posted January 21, 2008 http://www.kannel.org/download/1.4.1/userg.../userguide.html Link to comment Share on other sites More sharing options...
Kefiirs Posted January 21, 2008 Author Report Share Posted January 21, 2008 Es neprasu nekādu linku, kur es neko nevaru atrast, vienkārši lai to pirmo skriptu izlabo un pieliek viņam klāt otro skriptu! Link to comment Share on other sites More sharing options...
Aleksejs Posted January 21, 2008 Report Share Posted January 21, 2008 āāā.... nu, ta neko. Link to comment Share on other sites More sharing options...
andrisp Posted January 21, 2008 Report Share Posted January 21, 2008 Kefīrs, ar šitādu attieksmi, vēlme tev palīdzēt tikai samazinās un samazinās. Link to comment Share on other sites More sharing options...
Kavacky Posted January 21, 2008 Report Share Posted January 21, 2008 Nu ja tev vajag, tad arī liec. Link to comment Share on other sites More sharing options...
Kefiirs Posted January 21, 2008 Author Report Share Posted January 21, 2008 BET ES NEMĀKU! (cry) Man vienkārši vajag Jūsu palīdzību! Link to comment Share on other sites More sharing options...
p4F Posted January 22, 2008 Report Share Posted January 22, 2008 (edited) Mēs šeit izlabojam tavā kodā, nevis rakstām par brīvo no 0!!Un vispār ar tādu attieksmi teiksi saviem radiniekiem. Vai arī tas kas tev sataisīs par naudu! PS. Es tev varu tikai to pateikt ka visa informācija no sms ņemas ar $_GET[] palīdzību Edited January 22, 2008 by p4F Link to comment Share on other sites More sharing options...
Vebers Posted January 22, 2008 Report Share Posted January 22, 2008 Vispirms piesakies pie SMS pakalpojumiem un tad no $_GET, vai $_POST padotajiem parametriem atlasi to kas ir dots, attiecīgi visu pieglabā un gatavs... Un ja kaut ko nemāki, tad iemācies! @#%$^& Link to comment Share on other sites More sharing options...
Mikijs Posted January 22, 2008 Report Share Posted January 22, 2008 (edited) =D man ir vislabakais sms pak. skripts Vops skripts dod uz aru $get... un sheit ir apstrade... <? include("kodi/kodi.php"); $nr = $_GET['sms_sutitajs']; $code = $_GET['sms_kods']; $id = getid($code); $kods = kodi($code); if ($kods == "true") { add_flags($id, $nr); return "Tavas privilegijas pieskirtas! ".getnick($id); } else { disablecode($code); return "Kods ir jau izmantots, jeb tas tika ievadits nepareizi!"; } ?> Edited January 22, 2008 by Mikijs Link to comment Share on other sites More sharing options...
Aleksejs Posted January 23, 2008 Report Share Posted January 23, 2008 Mikij, man ir vēl labāks skripts pēc analoģijas ar Tavu.... <?php include('skripts_kuraa_notiek_visas_darbiibas_un_kuraa_defineetas_visas_funkcijas.php'); if(valideet_kodu_ar_funkciju_kura_ir_augstaakmineetajaa_includee_un_kura_uzstaa da_visus_sisteemas_mainiigos_un_staavokljus()){ //te seko daļa, kad saņemtais SMS kods ir akceptēts } else { //te seko daļa, kad saņemtais SMS kods ir noraidīts } ?> Easy as a pie! Link to comment Share on other sites More sharing options...
Mikijs Posted January 23, 2008 Report Share Posted January 23, 2008 =D reali tu izdariji to pasu ko es :D bet tas taaa Link to comment Share on other sites More sharing options...
Recommended Posts