This example illustrates different ways to define single and double quotes in the php application with sql query.
This example illustrates different ways to define single and double quotes in the php application with sql query.This example illustrates different ways to define single and double quotes in the php application with sql query.
By default, PHP uses "magic quoting". This means that any variable passed via POST, GET, or cookies, will have all single quotes turned into backslash single quotes. That is, for these variables, all ' characters get turned in \' as in the source code.
Table: users before insertion
Table: users after insertion
Source Code of sql_quotes.php
<?php
|
Output: