answersLogoWhite

0

If you will see this example as below, this may help.

<?php

$string = mysql_real_escape_string($string);

$sql = "insert into stringtable(mystring) values('$string')";

?>

User Avatar

Wiki User

14y ago

What else can I help you with?

Related Questions

Why are you required to use a MySQL database in PHP?

You don't. PHP does not required MySQL to function. But because PHP is one of the easiest language with more built-in functions than you would ever need, and MySQL is free and easy to manage; people often use them together :)


How are PHP and MySQL compatible?

By sending messages to the MySQL server, you can communicate with the database. To submit SQL queries to the database, you use PHP functions. You don't need to know how to communicate with MySQL because PHP takes care of that. You only need to be familiar with SQL queries and PHP functions. To learn more about data science please visit- Learnbay.co


Which mysql product is suitable for php connection?

mysql client library


What character allows you to concatenate strings in PHP?

To concatenate strings in PHP, you use the . (dot) character. For example: $str = "String1" . "String2";


What has the author Janet Valade written?

Janet Valade has written: 'PHP &amp; MySQL' 'PHP &amp; MySQL web development all-in-one desk reference for dummies' -- subject(s): Computer Technology, Nonfiction, OverDrive, PHP (Computer programming language), SQL (Computer program language), Web site development 'PHP et MYSQL' 'PHP and MySQL for Dummies'


Why to use use MYSQL with PHP and not anyother database?

You can connect any DB via PHP if you have database specific database extensions defined. LAMPP stack refer to 'Linux Apache Mysql PHP Perl'. Hence this stack is famous for php development as it include all the needed components for web development. Mysql is preferred mostly because it's extension is added by default in XAMPP or WAMPP stack.


How do you delete data from a MySQL database using PHP?

To delete data from your MySQL database you need to use the mysql_query() function. Please see the example below: &lt;?php mysql_query("DELETE FROM table_name WHERE field_name = 44"); ?&gt;


Where can someone find more information about the php mysql tutorial?

One can find more information about the php mysql tutorial on Tutorials Point, Tizag, and W3 Schools. More information about the php mysql tutorial can be found at Site Ground.


Who can design your website in PHP and MySQL?

Any of the millions of web developers using PHP and MySQL around the world. Either that or teach yourself!


What host do you use when your MySQL database is on a separate server to your PHP scripts?

For the host you need to put the IP address of the MySQL server instead of localhost.


Can you run PHP and MySQL on Linux?

Yes.


How do you develop software using PHP and MySQL?

how do u develop software using php and mysql?