Authenticate the name and password, PHP Web Programming

Keep a list of allowed reporters and their passwords in a database table Authentication.  Define and populate the table beforehand manually using the phpMyAdmin interface to MySQL (or a command line interface if you like.) You can assume the reporter name is to be the primary key for the table.  The authentication information should have nothing to do with your UCID or MySQL passwords and name.  The table looks as follows with the appropriate data types for the columns.  The contents are NOT encrypted.

Authentication (for incident reports)

reporter_name

reporter_password

joe456

zebra

james777

checker

The PHP script should test the reporter name and password submitted from the form using a simple PHP or-die construction that queries the database for a matching reporter and password.  An SQL select command can be used but the returned data should not be accessed.  Just look up in the IT202 manual or on the online PHP manual how to tell if a select returned any rows.  If the select is defined appropriately, that will tell you if the reporter name and password were valid.   The password should not be encrypted by the browser, the script or in the database.

Caveat:

PHP:    When testing strings for equality in PHP, do not use = where you should use == (a pair of equal signs).  The PHP symbol = is for assignment statements; it is not used to compare strings; use the == equality operator for string comparison.

SQL:   When testing strings for equality in SQL, use = symbol, not the == used in PHP

Posted Date: 3/29/2013 6:01:31 AM | Location : United States







Related Discussions:- Authenticate the name and password, Assignment Help, Ask Question on Authenticate the name and password, Get Answer, Expert's Help, Authenticate the name and password Discussions

Write discussion on Authenticate the name and password
Your posts are moderated
Related Questions
Want help WordPress OAuth Plugin We have written a Wordpress oauth plugin that delivers Wordpress authentication via our oauth provider at PlayGrid.com. The present plugin has a

We need help to edit php code Website wants editing and support in php Change notifications,logins as well as some other functionalities. Project to be discussed in more detail.

Looking for a Ruby on Rails developer Rails 3 also related gems Job Description- I am seeking a developer to work on fixes on an existing ROR project. Your responsibilitie

Wed need a Wordpress and PHP developer needed monthly I want a developer that will be paid on a monthly basis to do miscellaneous as needed tasks on already developed websites.

Move my GoDaddy Site to WP.org I would like someone to move my current website and blog content to WP.org. I love my current site pretty much as is. The merely reason I want

Develop an ecommerce website in the optical industry that will allow customers to shop for frames upload/order prescriptions and have a shopping cart and pay. Need to look similar

I need Custom T-shirt Website Project Description: Seeking a full-time developer to help custom t-shirt company with multiple projects in the upcoming year. Skills require

Web Programmer need to integrate web and database Requirements- The primary responsibility of the intended web programmer is- 1) Choose as well as customize website templa

I need help for Wordpress plugin to pull Facebook group posts I am seeking someone to create a custom WordPress plugin for me that will take the post feed from my closed/private

Web & wordpress theme : design & development Expert with php, bootstrap, css and JavaScript. Good with HTML5 will be nice. Able to work with job schedule Job Description- We'