Thread:Project:Support desk/cookies error message during connection to wiki

Hi,

to prevent acces to my mediawiki server, I create a form requiring the login to server and I check the answer according to values saved into a DB table created with phymyadmin Now, before to run the mediawiki object the form is displayed

to perform this, I modified the index.php as following Incorrect Login "; } if (isset($_SESSION['Acces']) && ($_SESSION['Acces'])){

require __DIR__. '/includes/WebStart.php'; $mediaWiki = new MediaWiki; $mediaWiki->run; } else { ?>       identifiant : 

password : 

 <?php }

and I create a checkForm.php as following

<?php session_start; error_reporting(E_ALL & ~E_NOTICE);

$_SESSION['mytwikiLog'] = $_POST['inputlogin']; $_SESSION['mywikiPwd'] = sha1($_POST['inputpwd']);

$connect = mysqli_connect("localhost","root","rootpass","myDB") or die('error BD connect'); $query = 'SELECT * FROM myTable' ; $result = mysqli_query($connect,$query) or die('Table error') ; while($row = mysqli_fetch_row($result)){ if ( ($_SESSION['mywikiLog']==$row[1]) && ($_SESSION['mywikiPwd']==$row[2]) ){ $_SESSION['Acces']=true; break;} else { $_SESSION['Acces']=false;} } mysqli_free_result($result); mysqli_close($connect); require("./index.php"); exit; ?>

But Now when I want to enter my connect login to the mediawiki The login is performed but I always have the two messages (brown and pink)
 * 'userlogin-loggedin' : you are already logged in as .... use the form below to ogin an another user
 * 'nocookieslogin' : SITENAME uses cookies to login users. You have cookies disabled. Please enabe them and try again

but I am corectly connect to the wiki and my cookies are activated

WHY HAVE I THIS TWO MESSAGES ?

Please coud you help me great thanks