Ive been having trouble querying my database. I connect just fine, I get no errors but I cant seem to insert anything from my form. I dont have a clue what Im doing wrong and if it's not the php on the page then it has to be the mysql server setup.
I know something is wrong because it doesn't even get to the echo script and posting the values.
I dont know all the information you guys need to help me out but will post it when you tell me.
Here's what I have so far:
<?php $name = $_POST['name']; $company = $_POST['company']; $phone = $_POST['phone']; $email = $_POST['email']; $shape = $_POST['shape']; $colors = $_POST['colors']; $size = $_POST['size']; $quantity = $_POST['quantity']; $comments = $_POST['comments']; $dbc = mysqli_connect ('me.mysite.com','user', 'password','database') or die('Error connecting to MSQL server.'); $query = "INSERT INTO mytable (name, company, phone, email, shape, colors, size, quantity, comments)". "VALUES ('$name', '$company','$phone'.'$email'.'$shape'.'$colors'.'$size'.'$quantity','$comments')"; $result = mysqli_query($dbc, $query) or die ('cant query the stupid server'); mysqli_close ($dbc); echo 'Your name : ' .$name .'<br/>'; echo ' Your Company : ' .$company .'<br/>'; echo ' Your phone # : ' .$phone .'<br/>'; echo ' Your email : ' .$email .'<br/>'; echo ' Label shape : ' .$shape .'<br/>'; echo ' Label colors : ' .$colors .'<br/>'; echo ' Label size : ' .$size.'<br/>'; echo ' Label quantity : ' .$quantity .'<br/>'; ?>