Mam proste logowanie z użyciem php,mysql. Wcześniej to logowanie działało mi na WampServer i ogólnie na wykonanych stronach. Po formacie zainstalowałem WS 2.0i z php 5.3.0; mysql 5.1.36 i apache 2.2.11 i niestety podczas wykonywanie skryptu wysypuje się Apache. Link do printscreena: http://img697.imageshack.us/img697/1830/apachez.png
Ma ktoś pomysł co jest nie tak?
logowanie.php:
<?php require_once('./config.php'); // załaczamy plik config.php function usun($data){ } } $message .= '<font class="blad">Nie podałeś loginu</font><br />'; $l = FALSE; }else{ $l = usun($_POST['login']); } $message .= '<font class="blad">Nie podałeś hasła</font><br />'; $h = FALSE; }else{ $h = usun($_POST['haslo']); } if ( $l && $h ){ $query = "SELECT username, access, user_id FROM lwow_user WHERE username='$l' AND haslo=password('$h')"; if($row){ $_SESSION['username'] = $row['username']; $_SESSION['access'] = $row['access']; $_SESSION['user_id'] = $row['user_id']; $_GET['cmd'] = 'ok'; }else{ $message .= '<font class="blad">Błędne hasło lub login</font><br />'; } }else{ $message .= '<font class="blad">Spróbuj jeszcze raz</font>'; } } ?> <table align="center" border="0"> <tr> <td align="right" class="uni_01">Login:</td> <td><input type="text" name="login" size="30"></td> </tr> <tr> <td align="right" class="uni_01">hasło:</td> <td><input type="password" name="haslo" size="30"></td> </tr> <tr> <td align="right" class="uni_01"> </td> <td> <p align="center"><input style="font-weight: bold;" type="submit" name="submit" value="loguj"> </td></tr> </table> </form> <div align="center"> } ?> </div>
a dalej plik panel.php:
<?php if(($_SESSION['access'] != 'admin')){ } ... ?>