GeRik Posted June 29, 2009 Report Share Posted June 29, 2009 Ja mana majaslapa ir IPB Login iebuvets un kad ielagojas vinsh iemet uzreiz foruma ka to partraukt lai paliek majaslapa kad ielagojas ? Quote Link to comment Share on other sites More sharing options...
waplet Posted June 29, 2009 Report Share Posted June 29, 2009 <form action="./index.php"> Quote Link to comment Share on other sites More sharing options...
ezis Posted June 29, 2009 Report Share Posted June 29, 2009 <form action="./index.php"> tas taču būs tiaki tādā gadījumā, ja tas login skripts ir iekš index faila.. nezinu par IPB, bet vinjiem nav tāda iespēja kā redirect after login.? Oo pačolē to login skriptu. tur taču jābūt vietai kur aizmēt ^^ Quote Link to comment Share on other sites More sharing options...
waplet Posted June 29, 2009 Report Share Posted June 29, 2009 nu jā bet login scripts jau būs tanī pat saitā, jo uztaisīt sessija vai kūkijus vai ko tur taisa Quote Link to comment Share on other sites More sharing options...
GeRik Posted June 29, 2009 Author Report Share Posted June 29, 2009 pielika un man vairs nevarej ielagoites Quote Link to comment Share on other sites More sharing options...
ezis Posted June 29, 2009 Report Share Posted June 29, 2009 doaah.! ^^ pačolē to savu login skriptu.. tur ta4u visam jābūt raxtītam.. :? Quote Link to comment Share on other sites More sharing options...
GeRik Posted June 29, 2009 Author Report Share Posted June 29, 2009 bet es tak jau skatijos kur notiek login funkcija pierakstiju klat beigas izskatijas shadi <form action='/index.php'> <form method='post' action='http://sixsixone.oo.lv/forum/index.php?act=Login&CODE=01' name='LOGIN'> <b>Lietotajvards:</b><br> <input style='width: 124px;' name='UserName' type='text'><br> <b>Parole:</b><br> <input style='width: 124px;' name='PassWord' type='password'><br> <b>acereties mani?</b> <input name='CookieDate' value='1' type='checkbox'><br> <input value=' Ienakt ' name='CookieDate' type='submit'><a href=http://sixsixone.oo.lv/forum/index.php?act=Reg&CODE=00'> Registreties</a> </form>"; Quote Link to comment Share on other sites More sharing options...
ezis Posted June 29, 2009 Report Share Posted June 29, 2009 es biju domājis, lai Tu paskaties act=Login. index failā būs tāda vieta kurs svičam vajadzētu būt vai kā tml. tur attiecīgi vajadzētu būt vietai, kur lietotāju iežurnālē, līdz ar to pie veiksmīgas ielogošanās var uzlikt header ( "Location: http://sixsixone.oo.lv" ); Quote Link to comment Share on other sites More sharing options...
GeRik Posted June 29, 2009 Author Report Share Posted June 29, 2009 (edited) man ir atsevishki ielikts taka tip caur <?include ("login.php");?> luuk viss login.php <?php mysql_connect("localhost", "root", "parole"); mysql_select_db("forum"); $id = $_COOKIE['member_id']; $dati= "SELECT * FROM `ibf_members` WHERE id = $id LIMIT 1"; $dati1=mysql_query($dati) or mysql_error(); $dati2= mysql_fetch_array($dati1); $logout = md5($dati2['email']."&".$dati2['member_login_key']."&".$dati2['joined']); if(isset($_COOKIE['member_id'])){ $get=mysql_query("SELECT * FROM `ibf_members` WHERE id='".intval($_COOKIE['member_id'])."'") or die(mysql_error()); $udata=mysql_fetch_object($get); if($udata->member_login_key==$_COOKIE['pass_hash']) { echo " <center>Čau, <b>".$udata->members_display_name."</b></center><br> <a href= 'http://sixsixone.oo.lv/'>Pievienot reklamu</a><br> <a href= 'http://sixsixone.oo.lv/forum/index.php?act=Msg&CODE=01'>Vēstules</a><br> <a href= 'http://sixsixone.oo.lv/forum/index.php?act=UserCP&CODE=00'>Labot Profilu</a><br> <a href= 'http://sixsixone.oo.lv/forum/index.php?act=Members'>Lietotāji</a><br> <a href= 'http://sixsixone.oo.lv/forum/index.php?act=Search&f=0'>Meklēt forumā</a><br> <a href='irc://irc.lv/sixsixone'><font color=red>#sixsixone mIRC</font></a><br><br> <a href= 'forum/index.php?act=Login&CODE=03&k=".$logout."'>[iZIET]</a>"; }else{ echo " <form action='/index.php'> <form method='post' action='http://sixsixone.oo.lv/forum/index.php?act=Login&CODE=01' name='LOGIN'> <b>Lietotajvards:</b><br> <input style='width: 124px;' name='UserName' type='text'><br> <b>Parole:</b><br> <input style='width: 124px;' name='PassWord' type='password'><br> <b>acereties mani?</b> <input name='CookieDate' value='1' type='checkbox'><br> <input value=' ienakt ' name='CookieDate' type='submit'><a href=http://sixsixone.oo.lv/forum/index.php?act=Reg&CODE=00'> Registreties</a> </form>"; } }else{ echo " <form action='/index.php'> <form method='post' action='http://sixsixone.oo.lv/forum/index.php?act=Login&CODE=01' name='LOGIN'> <b>Lietotajvards:</b><br> <input style='width: 124px;' name='UserName' type='text'><br> <b>Parole:</b><br> <input style='width: 124px;' name='PassWord' type='password'><br> <b>acereties mani?</b> <input name='CookieDate' value='1' type='checkbox'><br> <input value=' Ienakt ' name='CookieDate' type='submit'><a href=http://sixsixone.oo.lv/forum/index.php?act=Reg&CODE=00'> Registreties</a> </form>"; } ?> Edited June 29, 2009 by GeRik Quote Link to comment Share on other sites More sharing options...
ezis Posted June 29, 2009 Report Share Posted June 29, 2009 wouuu, neesmu genius, bet izskatās ka Tev tur baigā šmuce.. to tavu skriptu vajadzētu savest kārtībā.. 2x pēc kātas atkārtojas vienāda daļa un tā daļa ir form. divas formas.. bextam katrā no tām ir divi formu sākumi ar atķirīgiem action.. Oo šādu piemēru pirmo reizi redzu.! beztam, manjoprojām liekas, ka atrisinājumu vari atrāst foruma index failā kur act ir Login. skaties tur. tur vajadzētu būt kkam kas atbild tālāk par login.. ceru, ka nemaldos. Quote Link to comment Share on other sites More sharing options...
GeRik Posted June 29, 2009 Author Report Share Posted June 29, 2009 maldies jo ja caur forumu ielagosies tad vinsh tak aizmetis uz web lapu bet man vaig ja caur web lapu tikai ja ielagojas ka vinju nemet uz forumu bet paliek turpat Quote Link to comment Share on other sites More sharing options...
ezis Posted June 30, 2009 Report Share Posted June 30, 2009 par to es arī runāju Oo Quote Link to comment Share on other sites More sharing options...
GeRik Posted June 30, 2009 Author Report Share Posted June 30, 2009 atradu atrisinajumu :) <form action='/forum/index.php?act=Login&CODE=01&return=http://sixsixone.oo.lv/' method='post' name='LOGIN'> Bet ka to izdarit ar logout ? :O <a href= 'forum/index.php?act=Login&CODE=03&k=".$logout."'>[iZIET]</a>"; Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.