Login   Register  
PHP Classes

File: phpsecureweb/index.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Bulent Tezcan  >  phpsecureweb  >  phpsecureweb/index.php  >  Download  
File: phpsecureweb/index.php
Role: Application script
Content type: text/plain
Description: remove this file or integrate it to your site.
Class: phpsecureweb
Allow users certain rights, login with password.
Author: By
Last change:
Date: 12 years ago
Size: 1,672 bytes


Class file image Download
    * @author Bulent Tezcan. bulent@greenpepper.ca

session_start( );

ob_start( );


    if (
$_GET['isOK'] == 'OK')
$FormElements['__error'] = "Thank you. We hope you found it useful.";
$_SESSION['resetDatabaseError'] = "";
$_GET['isOK'] == 'ERROR')
$FormElements['__error'] = $_SESSION['resetDatabaseError'];

$myForm = new Form("login");
$myForm-> SetNumberOfColumns);
$myForm-> SetCellSpacing);
$myForm-> SetCellPadding);
$myForm-> SetBorder    );
$myForm-> SetAlign ("center");
$myForm-> SetTableWidth ("400");
$myForm-> SetTableHeight (null);
$myForm-> SetCSS $_SESSION["CSS"] );
$myForm-> SetEmptyCells (false);
$myForm-> SetFormHeader("<font class=\"".$_SESSION["CSS"]."FormHeaderFont\">Welcome to Security Demo</font>");

$myForm-> SetErrorMessage($FormElements['__error']);
$label = new Label("lbl1","After you are done with the testing,<br>PLEASE reset the database for others.<br><br>User : admin<br>Password: secret");
$label-> SetColspan(2);

$myForm-> AddFormElementToNewLine($label);

$adminMenu "\n<a class=\"".$_SESSION["CSS"]."LinkButton\" href=\"adminmenu.php\">Start the Demo</a>";

$passtru = new PassTru();


$myForm-> AddFormElementToNewLine($passtru);

$passtru->SetValue("\n<a class=\"".$_SESSION["CSS"]."LinkButton\" href=\"resetDatabase.php\">Reset the Database</a>");
$myForm-> AddFormElement($passtru);

$myForm-> GetFormInTable( );


ob_end_flush( );