I have this code:
------------------------
<HTML>
<HEAD>
<Link rel="stylesheet" title="screen" media=screen href="index.css" type=text/css>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-2">
<META http-equiv="Default style" content="screen">
<Title>Trefort 07A - Belépés</Title>
</HEAD>
<Body>
Az oldalra csak jelszóval lehet belépni.<BR><BR>
<?php
$password = "xxx";
if((isset($_POST['password'])) && ($password == $_POST['password']))
{
print '<iframe width=100% height=100% src=00000/index.php> A jelszó megfelel!
<A Href="00000/info.php">Tovább>></A></iframe
>';
}
else {
print 'A jelszó nem felel meg!<BR>
<form method="post" action="'.$PHP_SELF.'">
<input type="password" lenght=20 name="password"><input type="submit" value="Belépés"></form>';
}
?>
</body>
</html>
------------------
Where can I take this code?
session_start()
$_SESSION["login"] = 1;
(because this code will protect my page!)
------------------------
<HTML>
<HEAD>
<Link rel="stylesheet" title="screen" media=screen href="index.css" type=text/css>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-2">
<META http-equiv="Default style" content="screen">
<Title>Trefort 07A - Belépés</Title>
</HEAD>
<Body>
Az oldalra csak jelszóval lehet belépni.<BR><BR>
<?php
$password = "xxx";
if((isset($_POST['password'])) && ($password == $_POST['password']))
{
print '<iframe width=100% height=100% src=00000/index.php> A jelszó megfelel!
<A Href="00000/info.php">Tovább>></A></iframe
>';
}
else {
print 'A jelszó nem felel meg!<BR>
<form method="post" action="'.$PHP_SELF.'">
<input type="password" lenght=20 name="password"><input type="submit" value="Belépés"></form>';
}
?>
</body>
</html>
------------------
Where can I take this code?
session_start()
$_SESSION["login"] = 1;
(because this code will protect my page!)