PIPARIns :* Posted July 4, 2010 Report Share Posted July 4, 2010 <? require ("load.config.sys.php"); $login = "<form name='LOGIN' action='{$forummap}/index.php?act=Login&CODE=01' method='post'> <input type='hidden' name='act' value='Login' /> <input type='hidden' name='CODE' value='01' /> <input type='hidden' name='CookieDate' value='1' /> <font class=logintext size=1><strong>Lietotāja vārds:<br /> <input class='forminput' type='text' size='18' name='UserName'><br /> Parole:<br /> <input class='forminput' type='password' size='18' name='PassWord' /><br /></strong> <input class='forminput' type='submit' value='Ienakt'></font></form> <form name='reg' action='{$forummap}/index.php?act=Reg' method='post'> <input style='display:inline' class='forminput' type='submit' value='Registreties'></form? "; if(!empty($_COOKIE['member_id']) && is_numeric($_COOKIE['member_id']) && !empty($_COOKIE['pass_hash'])){ $sql = sprintf("SELECT m.id, m.members_display_name, m.email, m.member_login_key, m.joined, e.avatar_location FROM `ibf_members` m, `ibf_member_extra` e WHERE m.id=%d AND m.member_login_key='%s' AND e.id=m.id LIMIT 1", (int)$_COOKIE['member_id'], mysql_real_escape_string($_COOKIE['pass_hash'])); $res = mysql_query($sql); if(mysql_num_rows($res)>0){ $row = mysql_fetch_object($res); $logout = md5($row->email.'&'.$row->member_login_key.'&'.$row->joined); printf("Sveiks, <strong><a href='{$forummap}/index.php?showuser=%s' />%s</a></strong>!<br />", $row->id, $row->members_display_name, $row->avatar_location, md5($row->email.'&'.$row->member_login_key.'&'.$row->joined)); echo "» <a href='{$forummap}/index.php?act=Search&CODE=getnew' />Skatit jaunos postus</a><br />» <a href='{$forummap}/index.php?act=UserCP&CODE=00' />Mani uzstadijumi</a><br />» <a href='{$forummap}/index.php?act=Msg&CODE=01' />Vestules</a><br />» <a href='{$forummap}/index.php?act=Login&CODE=03&k={$logout}' />Iziet</a><br />"; }else{ echo $login; } }else{ echo $login; } ?> Ceru kad noderēs. Link to comment Share on other sites More sharing options...
ABU Posted July 4, 2010 Report Share Posted July 4, 2010 Lai tiešām palīdzētu Noob'iem, tad tev vēl vajag pievienot klāt: 1) failu load.config.sys.php 2) uzrakstīt, kādu DB izmantot un tabulas struktūru. Pretējā gadījumā no šitā skripta nav nekādas jēgas. Tikai sataisa input laukus un atrod datus tabulā. Link to comment Share on other sites More sharing options...
mounkuls Posted July 4, 2010 Report Share Posted July 4, 2010 echo "» <a href='{$forummap}/index.php?act=Search&CODE=getnew' />Skatit jaunos postus</a><br />» <a href='{$forummap}/index.php?act=UserCP&CODE=00' />Mani uzstadijumi</a><br />» <a href='{$forummap}/index.php?act=Msg&CODE=01' />Vestules</a><br />» <a href='{$forummap}/index.php?act=Login&CODE=03&k={$logout}' />Iziet</a><br />"; Esi pamēģinājis arī?:) Šādam te, ja nemaldos, būs nevalīda lapa dēļ and simboliem. And simbolu izvadot to jāraksta kā &apm;. Link to comment Share on other sites More sharing options...
PIPARIns :* Posted July 4, 2010 Author Report Share Posted July 4, 2010 (edited) Rekur bus. :) http://www.failiem.lv/down.php?i=ncwkwr&n=load.config.sys.php Edited July 4, 2010 by PIPARIns :* Link to comment Share on other sites More sharing options...
codez Posted July 4, 2010 Report Share Posted July 4, 2010 Atvaino, bet tavs skripts met ārā kļūdas, warningus un vēl nezin ko. Kāpēc jāpostē tāds skripts? Link to comment Share on other sites More sharing options...
PIPARIns :* Posted July 4, 2010 Author Report Share Posted July 4, 2010 Codez nez nez nez, man viss iet :) Link to comment Share on other sites More sharing options...
mounkuls Posted July 4, 2010 Report Share Posted July 4, 2010 Ar šo te </form? uz pārlūka rēķina validējot? Link to comment Share on other sites More sharing options...
codez Posted July 4, 2010 Report Share Posted July 4, 2010 protams, ka iet, jo tev ir visi faili, kuri tiek skripta izpildes laikā inklūdoti. Link to comment Share on other sites More sharing options...
Kemito Posted July 4, 2010 Report Share Posted July 4, 2010 āksts, nekas vairāk ! Gribi postus krāt, sac darīt kautko noderīgāku. Izlasi kautvai to pašu manis veidoto postu, kur jautāju attiecībā uz komentāru sistēmu . Tur diezgan arī apskaidroja ietas, tai skaitā validēšanu! Link to comment Share on other sites More sharing options...
mefisto Posted July 4, 2010 Report Share Posted July 4, 2010 Nu šitādam subjektam iedot "read-only" uz kādu mēnesi, un visus postus nahrenizēt. Link to comment Share on other sites More sharing options...
bubu Posted July 4, 2010 Report Share Posted July 4, 2010 Norādam sourci, no kurienes ņemam savus skriptus! http://php.lv/f/topic/16775-login-skripts-un-topposters-kaut-kas-nau-ka-vaig/page__p__131303 Link to comment Share on other sites More sharing options...
Recommended Posts