Hi,

I'm interested in writing a PHP script that will allow a customer with a job number (ticket number) & a login password the ability to access their account within my database, and therefore have information on the status of their order. I'm only learning PHP, and any help or advice as to what direction I would need to take would be very much appreciated. I know some basics.

Thanks in advance.

PHP is very simple and that's the reason why it is so popular.

So doing it step by step:
0) get a homeserver (Apache with PHP and MySQL - you can use Xammp).
1) Set up a database and save job number and the password together with the article (eg `nb`,`pw`,`art`)
2) write a systemfile in db and put your code in simple functions:
function opendb()
mysql_connect...
end function
function checkjob($nb,$pw){
opendb()
$r=mysql_query("SELECT `art` FROM `db` WHERE `nb`=".$nb." AND `pw`=".$pw);
$a=mysql_fetch_row($r);
return $a[0];
}
and so on.
3) write you code. $art=checkjob($nb,$pw);
echo "You article is: ".$art.". How can I help you? ...";

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.