i am talking about interbase here.
when input string values into a database, sigle quote may cause the problem. sql statement error!
$mystring="world's best php site";
$mystring=str_replace(" ' ", " '' ", $mystring);
//this statement used to solve the single quote issue.
but, on another server, it is aslo using interbase as the database, string value with single quote will be OK.
for
$mystring="world's best php site";
I don't have to use the
$mystring=str_replace(" ' ", " '' ", $mystring);
as a matter of fact, if i do that
$mystring's value will be displayed as "world''s best php site".
my questions are: in some set ups, interbase sql accept the string value with sigle quote. other set ups, don't. are they because
1) Interbase versions are different?
2) Interbase server set up are different?
3) The databases created on the server are with different set ups?
4) If sometimes I have to replace the sigle quote, sometimes I don't, how can build a package to be able to use at any platform without knowing what the database set up will be. (in the single quote issue.)
thanks.