For putting $_POST variable in where clause, I don't know which is correct between parenthesis in the above and braket in the below?Code:code $query="select id from myTable1 where title='$_POST ('$myVar')' " ; echo $query; result select id from myTable1 where title='Array('title1')'
How can I make the result "select id from myTable1 where title='title1' "?Code:code $query="select id from myTable1 where title='$_post['$myVar']' " ; echo $query; result Parse error: syntax error, unexpected T_ENCAPSED_AND_WHITESPACE, expecting T_STRING or T_VARIABLE or T_NUM_STRING




Bookmarks