Re: I'm completely lost here
| From: | Gary Chambers | Date: | Sat, 25 Aug 2012 01:27:31 +0000 |
| Subject: | Re: I'm completely lost here | ||
| References: | 1 2 3 4 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-48429@lists.php.net to get a copy of this message | ||
David,
> Just did that like Richard had suggested also and I do get the expected
> results. I suspect I need to put the same thing in my query correct? like
> this:
>
> mysql_query ("INSERT INTO inventory(image, year, make, model,
> milage, price)VALUES($_POST['image'], $_POST['year'],
> $_POST['make'],
> $_POST['model'], $_POST['milage'] , $_POST['price'])");
I might be stating the obvious here, but you should really validate your input. If this is just an
exercise or a simple test, that will work. If it's an application that, especially, is
accessible on the internet, you definitely need to validate and ensure that you're receiving
sane input.
--
Gary