Uldeens Posted September 12, 2003 Report Share Posted September 12, 2003 Man ir login forma: <form action="login.php" method="post"> <input type="text" name="login"> <input type="submit" name="submit" value="apstiprinat" ></form> Un skripts: Login.php <? $idiots==idiots; if($login==$idiots); {echo "Kluda,Tu nemaz tads neesi"; exit; } else { echo "TU esi Registrejies <br> Tavs login ir:" echo $_POST['login']; } ?> Kur ir problema??? Serverim nepatiik ELSE uzreiz saku: PARSE EROR/UNEXPECTED T_ELSE IN ............../localhost. Link to comment Share on other sites More sharing options...
Aleksejs Posted September 12, 2003 Report Share Posted September 12, 2003 <code><font color="#000000"> $idiots==idiots;</font> </code> vietaa jaabuut <code><font color="#000000"> $idiots='idiots';</font> </code> == ir saliidzinaashana = ir pieshkjirshana <code><font color="#000000"> if($login==$idiots)[b];[/b]</font> </code> vietaa jaabuut <code><font color="#000000"> if($login==$idiots)</font> </code> Link to comment Share on other sites More sharing options...
Uldeens Posted September 12, 2003 Author Report Share Posted September 12, 2003 Taapat neiet.. Link to comment Share on other sites More sharing options...
kasisppr Posted September 12, 2003 Report Share Posted September 12, 2003 Atceries, ka echo beigās ir jāliek tāda zīmīte kā ;, pat, ja esi sadalījis echo 2 rindās. Tev ir: <code><font color="#000000"> Tavs login ir:"</font> </code> A vajag ar ;: <code><font color="#000000"> Tavs login ir:";</font> </code> Link to comment Share on other sites More sharing options...
Uldeens Posted September 12, 2003 Author Report Share Posted September 12, 2003 Nu nau arii tas.Tas ja tur kads komats nav var gadiities jo es 25 reizes laboju taas () "" :; ., ,,, utt. Saku tacu serverim nepatiik else!!! Varbuut kaads pameeginat palaist to skriptu un tad dodat padomus:)) Paldies Link to comment Share on other sites More sharing options...
Aleksejs Posted September 12, 2003 Report Share Posted September 12, 2003 varbuut, ka nepatiik tas, ka ir <code><font color="#000000"> {echo "Kluda,Tu nemaz tads neesi";</font> </code> bet varbuut vajag <code><font color="#000000"> { echo "Kluda,Tu nemaz tads neesi";</font> </code> Link to comment Share on other sites More sharing options...
K|NG Posted September 12, 2003 Report Share Posted September 12, 2003 (edited) Nu nau arii tas.Tas ja tur kads komats nav var gadiities jo es 25 reizes laboju taas () "" :; ., ,,, utt. še: <code><font color="#000000"> <font color="#0000CC"><?php </font><font color="#006600">if(!isset(</font><font color="#0000CC">$login</font><font color="#006600">)|| </font><font color="#0000CC">$login</font><font color="#006600">!=</font><font color="#CC0000">'idiots'</font><font color="#006600">){ echo</font><font color="#CC0000">'<form action="login.php" method="post"> <input type="password" name="login"> <input type="submit" name="submit" value="apstiprinat" ></form>'</font><font color="#006600">; }else{ echo </font><font color="#CC0000">"TU esi Registrejies Tavs login ir: $login"</font><font color="#006600">; } </font><font color="#0000CC">?> </font> </font> </code> Edited September 12, 2003 by K|NG Link to comment Share on other sites More sharing options...
Venom Posted September 13, 2003 Report Share Posted September 13, 2003 Ja kas, pirmatnējā variantā kļūda bija šeit: if($login==$idiots); < jebšu ja ... neizpildi neko if (true){;} Tāpēc arī bļāva, ka skripta vidū kaukāc else. Un vēl: strādā arī {echo'kautkas'; bez atstarpēm - php sintaksis ir gudrš ;) Link to comment Share on other sites More sharing options...
Uldeens Posted September 13, 2003 Author Report Share Posted September 13, 2003 King tavs variants arii neiet... :( UNEXPECTED VARIABLE T_ELSE ON LINE ......... Taadu kluudu izmet. Jaa nu venom no tava komentaara es drusku nesapratu kur taa kluuda bija(ja godiigi es neko nesapratu) :) Link to comment Share on other sites More sharing options...
jannis Posted September 13, 2003 Report Share Posted September 13, 2003 mosh vispirms skolaa iemaacies kaadu citu programmeeshanas valodu (Basic, Pascal vai C) un tad kjeries pie PHP un piedrazot forumu ar taadiem ... jautaajumiem Link to comment Share on other sites More sharing options...
K|NG Posted September 15, 2003 Report Share Posted September 15, 2003 King tavs variants arii neiet... :( nu b :( kurā vietā Tev tur izmet to kļūdu? šite nevar būt kļūdu. Tas ko Tu tur talāk saraksti, tās jau nav manas kļūdas ;) pamēģini velreiz :) re: http://paste.php.lv/355 Link to comment Share on other sites More sharing options...
Uldeens Posted September 15, 2003 Author Report Share Posted September 15, 2003 Nu neko es neraxtu taalkaak... Kluuda: Parse error: parse error, unexpected T_ELSE in c:program fileseasyphpwwwlogin.php on line Vispaar tevi king nesaprotu hulji tu visu kidu gan formu gan php liec vienaa failaa???? Vai man tur bija domaats atdaliit??? Login.php ta paliek taadspats..karo4e nesapraru un neiet.... :unsure: tikai nelamaajieties ja es kautko netaa sapratu.. Zinu kaads tuuliit uzraxtiis :"kaa tu veel neesi sapratis ka tas nav domaats tev(php) beidz maazoties" :) bet es jau to gandriiz saprotu..bet gribaas :)) Powered by <? echo "Skaties zemaak"; ?> Link to comment Share on other sites More sharing options...
Kaklz Posted September 15, 2003 Report Share Posted September 15, 2003 Nu neko es neraxtu taalkaak... Kluuda: Parse error: parse error, unexpected T_ELSE in c:program fileseasyphpwwwlogin.php on line Vispaar tevi king nesaprotu hulji tu visu kidu gan formu gan php liec vienaa failaa???? Vai man tur bija domaats atdaliit??? Login.php ta paliek taadspats..karo4e nesapraru un neiet.... :unsure: tikai nelamaajieties ja es kautko netaa sapratu.. Zinu kaads tuuliit uzraxtiis :"kaa tu veel neesi sapratis ka tas nav domaats tev(php) beidz maazoties" :) bet es jau to gandriiz saprotu..bet gribaas :)) Powered by <? echo "Skaties zemaak"; ?> nu nez nez .. liekas, ka vieniigais, ko tev varu ieteikt ir pameegjinaat veelreiz .. tam IR jaastraadaa, pats tikko paarliecinaajos Link to comment Share on other sites More sharing options...
Uldeens Posted September 15, 2003 Author Report Share Posted September 15, 2003 kaklz kam tiesi kas jaaraxta formaa un kas login.php???? Visaadi meeginu neiet ..... Link to comment Share on other sites More sharing options...
Uldeens Posted September 15, 2003 Author Report Share Posted September 15, 2003 Paga varbuut es kautko nepreizi daru tipa..........varbuut kautkas nau pareizi nokonfigureets(php,vai apache) jo man neh....ja neiet. Nu ja uzraxta <? infophp(); ?> tad paraadaas taa tabula tipa POWERED by zend utt. Bet mos veel kaut kas. Register globals ir on. Vienkaarsi kaa man bija ar HTML un failu uploadeesanu uz servera..tur romaanu var saraxtiit. Klausaas Man tipa dreamwiever mx.Nu tur arii ir iebuuveets ftp klients ka var uploadot failus.Es itkaa nu uzzinaaju host name password utt(tas prasiija kaadus 2.meen kameer sapratu kaa pareizi raxtiit un mur vinus:)) Uploadoju bet times lapaa nekas neparaadaas....un tad pats jautraakais....delfi chataa prasiiju ir kaads web specs tur taad Mis_alise Un Liiguce divas web dizaineres abas OPi,nu taraneeju kaadas 2 nedeelas ar jautaajumiem. Siis ar visaadaam metodeem meegina man staastiit,nu man pat dreamvieweraa REMOTE wiebv paraada ka ir tur tie faili(es siim to skaidroju ka ir bet atverot lapu tukss) siis netic nu karoce apniku(izvedu abas ) uzlika man ip banu uz delfi chatu. Peecd laika spaidu to linku Uldis.times.lv un izdomaaju uzraxtiit uldis.times.lv/manalapa.html(html lapu ko taisiiju dreamwieveraa seivoju kaa manalapa.html) Un viss aiziet.(nu paraadijaas uzraksts "Uldis :) Hello world un laikam viss.. Nu neviens tacu neiedomaajaas pateikt ka pirmaa lapa jaaseivo kaa INDEX.HTML. Tad kautkaa traapiju delfi chataa pastaastiiju taa pasmeejaamies,bet siis taapat suutiija di...t ka kautko paprasu.. :)) <?php $a=<html><body><b>Hello world</b></body></html> If($a=index.html); echo "HELLO WORLD "; exit; else echo "pi....s taalaak:)) ; ?> Link to comment Share on other sites More sharing options...
Recommended Posts