[PHP] Limit script memory usage !!

2001-12-20 Thread Nicolas Guilhot
Hi all, I need to limit the amount of memory that a script can use. Is there a function that I can use to tell the script to die if its memory usage becomes greater than $MAX_MEMORY ! Or maybe, I could use a cron job to monitor processes and kill them if they become too big ? Thanks for your

[PHP] Only one instance of a script at a time !

2001-12-28 Thread Nicolas Guilhot
Running a php script with a cron job, how can I do to have only one instance of the script running ? Thanks for any answer. Nicolas -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the

Re: [PHP] Only one instance of a script at a time !

2001-12-28 Thread Nicolas Guilhot
to execute unlink ($pidFile); } ? On Fri, 28 Dec 2001 15:31:33 +0100, Nicolas Guilhot wrote: Running a php script with a cron job, how can I do to have only one instance of the script running ? Thanks for any answer. Nicolas -- PHP General Mailing List (http://www.php.net

RE: [PHP] Update Query - Urgent

2001-10-23 Thread Nicolas Guilhot
Do you login to the database with a write access or a read only account ?? -Message d'origine- De : Srinivasan Ranganathan [mailto:[EMAIL PROTECTED]] Envoyé : mardi 23 octobre 2001 14:22 À : [EMAIL PROTECTED] Objet : [PHP] Update Query - Urgent Hi I have a php script generate a sql

[PHP] Problem with very big array !

2001-10-29 Thread Nicolas Guilhot
Hi guys, I have an sql query returning a result of nearly 150 000 rows. I use the PEAR DB::getAll method to retrieve this result as an array which is very big indeed (about 300Mb). I can't use the MySQL LIMIT statement because I need to do sorting stuff on the result array. My concern is that

RE: [PHP] Installing PHP with windows

2001-11-21 Thread Nicolas Guilhot
You can also have a look to EasyPhp http://www.easyphp.org/ which installs Apache, PHP and MySQL on Windows box. -Message d'origine- De : Rob Bennion [mailto:[EMAIL PROTECTED]] Envoye : mercredi 21 novembre 2001 21:55 A : [EMAIL PROTECTED] Objet : [PHP] Installing PHP with windows Hi I

RE: [PHP] HELP URGENT VARS !!!

2001-11-30 Thread Nicolas Guilhot
You can also use this syntax : $var1=variable 1; $var2=variable 2; for ($i= 1; $i 3; $i++) { echo ${var$i}; } -Message d'origine- De : Olivier Masudi [mailto:[EMAIL PROTECTED]] Envoyé : vendredi 30 novembre 2001 12:02 À : [EMAIL PROTECTED] Objet : [PHP] HELP URGENT VARS !!!

RE: [PHP] 1 is not a valid MySQL-Link resource in /home/guestbook.php on line 112

2001-12-04 Thread Nicolas Guilhot
Check that you have not already close the connection to the mysql database. Or maybe, the mysql_connect returned an error ! -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Envoyé : mardi 4 décembre 2001 08:42 À : [EMAIL PROTECTED] Objet : [PHP] 1 is not a valid

RE: [PHP] Dumped OK, Restore NOT

2001-12-05 Thread Nicolas Guilhot
Maybe you can try to launch the sql dump file from the SQL shell, not directly from the command line. I think it will give you more feedback about what is going on. Go to the directory where you have your smarts.sql file. Just type mysql smarts And in the SQL shell type \. smarts.sql If you are

[PHP] preg_replace is modifying the type of replacement parameter !!

2001-09-11 Thread Nicolas Guilhot
]); // This line outputs 'integer' $string_after = preg_replace($ary_pattern, $ary_replace, $string_before); echo br$string_afterbr; echo gettype($ary_replace[0]); // This line outputs 'string' ? Is this a bug from preg_replace or am I doing wrong somewhere? Any help would be appreciated. Regards. Nicolas

RE: [PHP] preg_replace is modifying the type of replacement parameter !!

2001-09-11 Thread Nicolas Guilhot
are integers. Andrey Hristov IcyGEN Corporation http://www.icygen.com BALANCED SOLUTIONS - Original Message - From: Nicolas Guilhot [EMAIL PROTECTED] To: Php General MailingList [EMAIL PROTECTED] Sent: Tuesday, September 11, 2001 3:24 PM Subject: [PHP] preg_replace is modifying the type

RE: [PHP] Print array items only once

2001-05-09 Thread Nicolas Guilhot
You can try to modify your SQL query and add the DISTINCT statement !! It will return each distinct row only once. example SELECT DISTINCT cat_id, cat_name FROM categories Regards, Nicolas -Message d'origine- De : [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Envoyé : mercredi 9 mai

[PHP] Passing an array to a C program from a php script??

2001-06-25 Thread Nicolas Guilhot
Hi all, I have a big array (nearly 1000 lines) that I would like to pass to a C program. I don't want to create a temporary file to pass my array (If possible ?!?), and I don't think the command line will fit my needs. Is there a way to execute a program with a php string as the standard input.

RE: [PHP] Passing an array to a C program from a php script??

2001-07-02 Thread Nicolas Guilhot
and the result of the program echo Return value : $num_return\n; echo Result :\n; print_r($ary_result); -Message d'origine- De : Nicolas Guilhot [mailto:[EMAIL PROTECTED]] Envoye : lundi 25 juin 2001 12:59 A : [EMAIL PROTECTED] Objet : [PHP] Passing an array to a C program from a php

[PHP] Problem with session vars !

2001-04-23 Thread Nicolas Guilhot
I am having problem with PHP4 session variables. I think I misunderstood how they work, and I can't see what I'm doing wrong. Any help would be appreciated. I am using the version from EasyPhp 1.1.1. Below is a short example to explain my problem. I've got two php scripts. 'test1.php' which

RE: [PHP] About sessions !!

2001-04-24 Thread Nicolas Guilhot
You should also check if register_globals is set to ON in your php.ini file. Otherwise you can't access you session variable just with $myvar !! And in your code you never increment $myvar, so even if it works, you'll always get 1. Regards, Nicolas Guilhot -Message d'origine- De

RE: [PHP] What's wrong with Apache + php + mysql on Windows?

2001-04-27 Thread Nicolas Guilhot
You can try to had HostnameLookups off in your httpd.conf if it is not already present. More info at http://www.apache.org/DELETE_ME/mod/core.html#hostnamelookups --- Hello, I can't understand the reason apache server running locally on my Win98 machine delays so much to respond

RE: [PHP] Check if a variable has been posted-- HOW?

2001-05-03 Thread Nicolas Guilhot
you can try if (isset($HTTP_POST_VARS['posted_variable_name'])){ // do something } -Message d'origine- De : Martin Cabrera Diaubalick [mailto:[EMAIL PROTECTED]] Envoyé : jeudi 3 mai 2001 13:10 À : [EMAIL PROTECTED] Objet : [PHP] Check if a variable has been posted-- HOW? Hi everyone

RE: [PHP] sessions and reg_globals=off

2001-05-03 Thread Nicolas Guilhot
When reg_globals is off, you can't access session vars just with $varA and $varB (thess variables are not set), you need to use $HTTP_SESSION_VARS['varA'] and $HTTP_SESSION_VARS['varB'] to access these variables !! -Message d'origine- De : ahmad varoqua [mailto:[EMAIL PROTECTED]] Envoyé