Re: [PHP-DB] "Fatal error: Call to undefined function pq_query()"

2010-04-13 Thread Firan Corneliu
Are you sure you're not using q instead of g :) just to be sure, you can check if a function exists by using $boolExists = function_exists('any_function_name'); http://www.php.net/manual/en/function.function-exists.php On Tue, Apr 13, 2010 at 11:20 AM, Gary . wrote: > What the... > > What is c

Re: [PHP-DB] Connection Question!

2005-05-17 Thread Firan Corneliu
If you mean database access that is simple, just create a user that has access only from localhost (and of course remove the others). For mysql just do the query : "GRANT ALL PRIVILEGES ON your_database.* to 'user'@'localhost' identified by 'password'". If you mean http access then you can confi

Re: [PHP-DB] addslashes + stripslashes + mysql question

2005-05-16 Thread Firan Corneliu
r words the original string. It is a normal behaviour and you should omit the stripslashes function. Hope it helps Firan Corneliu On Mon, 2005-05-16 at 11:20 +0300, Petzo wrote: > Hi, > > My question is about the norlmal behaviour of PHP and MYSQL but I cant > explain it w

Re: [PHP-DB] Error: "Resource id #3"

2005-05-14 Thread Firan Corneliu
The message that you receive is not an error, it is a description of the object $result after the query is done. So, you will not get anywhere just by echo $result, you have to process that information using one of the mysql_fetch_array(),mysql_fetch_assoc(), mysql_result(). In your case try :

Re: [PHP-DB] Function to convert a Date String to a MYSQL TimeStamp

2005-05-08 Thread Firan Corneliu
You can use date('YmdHis',strtotime($your_date_string)); check http://ro.php.net/manual/en/function.date.php for more about the date function. On Sat, 2005-05-07 at 18:06 -0700, Graham Anderson wrote: > I need to batch convert a bunch of date strings into mysql time stamps: > > If I have the

Re: [PHP-DB] [suspicious - maybe spam] How to deal with " ...?

2005-05-05 Thread Firan Corneliu
Another method could be the base64_encode(),base64_decode(). Something like this : echo("codigo:". $row['codigo'] ." | familia: ". $row['familia']." \n"); Hope it helps, capi On Wed, 2005-05-04 at 20:05 -0700, Ardilla Roja wrote: > Hi, > > I'm working in a database of products. Until now I'm ab