Try this:
$query="INSERT INTO user_details values('".$r."','".$city."','".$from_city."','".$to_city."')";
mysql_query($query);
More Related Contents:
- if condition in php and mysql [closed]
- Notice: undifined index, but why?
- How to get ID of the last updated row in MySQL?
- When should I use MySQLi instead of MySQL?
- SQL injections in ADOdb and general website security
- PHP PDO prepared statement — MySQL LIKE query
- How can I use mysqli_fetch_array() twice?
- Best practice multi language website
- Prevent InnoDB auto increment ON DUPLICATE KEY
- PHP inserting multiple checkbox AND textbox arrays into MySQL Database
- How to know if MySQLnd is the active driver?
- using nulls in a mysqli prepared statement
- How can I count the numbers of rows that a MySQL query returned?
- How to solve time out in phpmyadmin?
- MySQL: Add sequence column based on another field
- How to run the PHP script at scheduled time
- Laravel 5.4 on PHP 7.0: PDO Exception – Could not find driver (MySQL)
- How to handle error for duplicate entries?
- How to handle PDO exceptions [duplicate]
- MySql PHP select count of distinct values from comma separated data (tags)
- mysql_insert_id() returns 0
- php artisan migrate throwing [PDO Exception] Could not find driver – Using Laravel
- Change name of Laravel’s created_at and updated_at
- How do I get database column names in Laravel?
- PDO and MySQL Fulltext searches
- How to avoid “Using temporary” in many-to-many queries?
- how to execute mysql command DELIMITER
- Cannot figure out how to run a mysqli_multi_query and use the results from the last query
- PDO and MySQL ‘between’
- PHP add up two time variables