Friday, March 23, 2012

PHP in action

Since we are goint to use PHP in Microsoft Windows environment...

1) First thing to do is... stop IIS server if it exists

  1. Click Start, and then click Control Panel.
  2. Do one of the following:
    • If you are using Windows Vista® or Windows Server® 2008, click System and Maintenance, and then click Administrative Tools.
    • If you are using Windows® 7 or Windows Server® 2008 R2, click System and Security, and then click Administrative Tools.
  3. In the Administrative Tools window, double-click Internet Information Services (IIS) Manager.
  1. Click Start.
  2. In the Start Search box, type inetmgr and press ENTER.
2) Install XAMPP or WAMPP. Make sure when we browse to http://localhost/, it will point to XAMP instead of to IIS

3) For security, create password for 'root'

4) Login into phpAdmin and start creating the database and the needed fields

5) In Dreamweaver, create a site for the project

6) Create a connection to link the site with the Database in MySQL

7) Start creating the PHP files
  
   - login.php          (first page of this website)
   - register.php      (no username, then has to register first)
   - input.php          (redirected page after login to type in comments)
   - view.php           (display the comments that were input)

 

Automated Server Behaviour


* login.php - User Authentication --> Log In User
( Username and passwords will be checked whether they match or not...)

* register.php - User Authentication --> Check New User
( Username will be checked whether duplicate username exists...)

* input.php - Insert Records
(Input will be inserted into the database according to the matching field names)

* view.php - Recordset, Bindings, Repeat Region


best if i can display my work.. but argghh.. there are so many files that are jumbled up... not sure which one is the right one already...


Security Introduced...

Dr. Zaida introduced concepts of security in website development

1) Through login page.. no login.. no page

2) Pages restriction ( linked with login page)
    Server behaviour : User Authentication --> Restrict Access to Page

3) Acces level
    - set alongside the username and password
    - checked during login

No comments:

Post a Comment