Hey guys,
It seems simple what I am trying to do, but the quotes keep interfering. I know there are easier ways to accomplish what I'm trying to do, but just trying to learn.
Here is a simple query:
$query = "update users set images=\"$POST[images]\", hidden=\"$POST[hidden]\" where id=$id";
I want to input the fields so the query becomes:
update users set images="1", hidden="0", is_admin="1" where id=$id";
The info is input by an html form:
images= 1
hidden= 0", is_admin = "1
when I put quotes into the html form, it automatically adds the slashes. How to get around this? Should I input it differently?