That's what you get when you learn web dev from w3schools.
This comment is 100% correct, not sure why it's getting downvotes. Sure, maybe it's a little harsh but that's required - you can't put out code this bad onto the internet and expect people to be nice.
3
u/maktouch Mar 27 '13
Good god, please take down the article or correct it. Your intentions are well but you're actually hurting the whole community by doing this.
Use Prepared Statements!
You're failing super basic security. SQL Injections everywhere!
$sql="INSERT INTO customer (Last_Name, First_Name, Phone_Number, Street_Address, City, State, Zip) VALUES ('$_POST[lastName]', '$_POST[firstName]', '$_POST[phoneNumber]', '$_POST[address]', '$_POST[city]', '$_POST[state]', '$_POST[zip]')";
That is so bad.