Posts by Gilson Fabiano • 21 points
2 posts
-
2
votes2
answers1510
viewsA: file_get_contents(): Content-type not specified assuming application/x-www-form-urlencoded
The error is in the formation of $options. Content-Type is not a valid parameter. It is an http header and the right place for it would be in $options['header']; Note the concatenation of the…
-
0
votes2
answers502
viewsA: SQL with 2 of multiple conditions
Well, you can concatenate your query. example: $query = "SELECT * from table WHERE 1 = 1"; if ($nome) { $query .= "Nome = ". $nome; } if ($cidade) { $query .= "Cidade = ". $cidade; } This is just an…