Re: [PHP] question regarding Reflection

2005-11-01 Thread Jochem Maas
Manish Marathe wrote: Hello All, I am developing a unit test generator for PHP. The generated tests would be PHPUnit2 compatible and I will be using the Reflection API to generate the tests. The tests would be generated only for classes and written on PHP 5.0.3 compatible. My question is to

Re: [PHP] Question about including files and server load

2005-10-14 Thread Richard Davey
Hi Jay, Friday, October 14, 2005, 2:21:57 PM, you wrote: I was wondering isn't this putting a bigger load on a server by including so many files for each function? Also, I was wondering what everyone's opinion was on this approach in terms of maintenance. Do you think it's better practice to

Re: [PHP] Question about including files and server load

2005-10-14 Thread Edward Vermillion
Richard Davey wrote: Hi Jay, Friday, October 14, 2005, 2:21:57 PM, you wrote: I was wondering isn't this putting a bigger load on a server by including so many files for each function? Also, I was wondering what everyone's opinion was on this approach in terms of maintenance. Do you think

Re: [PHP] Question

2005-10-07 Thread Michael Crute
On 10/7/05, Sven Simons [EMAIL PROTECTED] wrote: I've installed PHP using the windows installer I try to open then php pages containing the following script : ?php echo Current IP Address: ; $ipx = getenv(HTTP_CLIENT_IP) ? getenv(HTTP_CLIENT_IP) : 0; $ipx = !$ipx

Re: [PHP] Question

2005-10-07 Thread Richard Lynch
On Fri, October 7, 2005 6:54 am, Sven Simons wrote: When manually installing PHP it always gives me the status UNKNOWN. Definitely check $_SERVER instead of GetEnv to see if it gives you what you want. The only strange thing is that the phpinfo says that the ini file is located in C:\Winnt

Re: [PHP] Question about Rasmus' 30 second AJAX Tutorial

2005-09-30 Thread Stut
xfedex wrote: I did the Rasmus' 30 second AJAX Tutorial just for testing and everything works fine, by the way... thanks Rasmus, for this and for all !!. My little script have a single input and for every keystroke (calling the javascript function with onkeyup) the value of the input is parsed

Re: [PHP] Question about Rasmus' 30 second AJAX Tutorial

2005-09-30 Thread Jochem Maas
xfedex wrote: Hi, I did the Rasmus' 30 second AJAX Tutorial just for testing and everything works fine, by the way... thanks Rasmus, for this and for all !!. My little script have a single input and for every keystroke (calling the javascript function with onkeyup) the value of the input is

Re: [PHP] Question about Rasmus' 30 second AJAX Tutorial

2005-09-30 Thread xfedex
On 9/30/05, Jochem Maas [EMAIL PROTECTED] wrote: I'm guessing that trhe onclick and onsumbit handlers you set are hanging on a 'submit' type input? .. if so the form is submitting - in whcih case the AJAX request will arrive back at your page - and the page won't be there (so to speak). try

Re: [PHP] Question about Rasmus' 30 second AJAX Tutorial

2005-09-29 Thread Robert Cummings
On Thu, 2005-09-29 at 22:46, xfedex wrote: Hi, I did the Rasmus' 30 second AJAX Tutorial just for testing and everything works fine, by the way... thanks Rasmus, for this and for all !!. My little script have a single input and for every keystroke (calling the javascript function with

Re: [PHP] Question about Rasmus' 30 second AJAX Tutorial

2005-09-29 Thread xfedex
On 9/29/05, Robert Cummings [EMAIL PROTECTED] wrote: Aside from using ajax to clean the toilet once in a while I'm not really into it. But I do wrangle out some javascript from time to time :) Why are you using onsubmit? Wouldn't onclick work better? Cheers, Rob. Hi Robert, I also try

Re: [PHP] question on order of variables passed to a function

2005-08-23 Thread Jasper Bryant-Greene
Vidyut Luther wrote: ?php myErrorHandler($errno, $errstr, $errfile, $errline) { switch ($errno) { case E_USER_ERROR: . } ? and then: ?php trigger_error(log(x) for x = 0 is undefined, you used: scale = $scale, E_USER_ERROR); ? So, wouldn't this make $errno in the myErrorHandler be

RE: [PHP] Question about exec() call an CLI php script from Apache CGI/filter module PHP

2005-07-28 Thread Liang ZHONG
I forgot to mention that calling from shell directly s.php runs correctly. ~ marvin:~/liang.ns2user.info/php ./s.php This is a PHP-CLI Script!!0123456789 ~ The php configuration of this site is: http://liang.ns2user.info/php/info.php Thank you

Re: [PHP] Question about apache-php concurrent process control

2005-07-22 Thread Liang ZHONG
Thank you Richard, I think I'd better explain a little about the project and then you or somebody else might give some good suggestion upon the restrictions of the project. The project is to implement a digital library protocol, called oai_pmh

Re: [PHP] Question about apache-php concurrent process control

2005-07-22 Thread Rasmus Lerdorf
Read this chapter of the manual: http://www.php.net/manual/en/features.connection-handling.php Liang ZHONG wrote: I now encounter a problem with flow control of my program with PHP. This is very crucial to the design of a pretty big project. This is what I want to do in the program: ?php

Re: [PHP] Question about apache-php concurrent process control

2005-07-22 Thread Richard Lynch
On Tue, July 19, 2005 5:32 am, Liang ZHONG said: It sounds interesting. But since I am pretty new to PHP, I have some questions, naive maybe, about what you wrote. #!/bin/sh\n/path/to/script/Send.php 12 \n What does the Send.php look like? I do not have idea how a shell interprets an php

Re: [PHP] Question about apache-php concurrent process control

2005-07-21 Thread Liang ZHONG
I now encounter a problem with flow control of my program with PHP. This is very crucial to the design of a pretty big project. This is what I want to do in the program: ?php do_A(); header(Location: .$result_of_do_A); do_B(); ? Since it takes do_B() quite a while to finish, so I want the

Re: [PHP] Question about apache-php concurrent process control

2005-07-21 Thread Robert Cummings
http://ca.php.net/manual/en/function.register-shutdown-function.php Cheers, Rob. On Thu, 2005-07-21 at 23:40, Liang ZHONG wrote: I now encounter a problem with flow control of my program with PHP. This is very crucial to the design of a pretty big project. This is what I want to do in the

Re: [PHP] Question about apache-php concurrent process control

2005-07-21 Thread Richard Lynch
On Thu, July 21, 2005 8:40 pm, Liang ZHONG said: I now encounter a problem with flow control of my program with PHP. This is very crucial to the design of a pretty big project. This is what I want to do in the program: ?php do_A(); header(Location: .$result_of_do_A); Depending on the

Re: [PHP] Question about apache-php concurrent process control

2005-07-19 Thread Liang ZHONG
Thank you Rouvas, I never used the tools you mentioned. But I will definitely give them a try. I wrote a perl script using LWP as an http user agent. and the timing function you suggested. It works well. I am new to this forum, and new to PHP. It seems Rasmus is famous, and I should have

RE: [PHP] Question about apache-php concurrent process control

2005-07-19 Thread Shaw, Chris - Accenture
snipIt seems Rasmus is famous, and I should have shown my respect./snip history src = 'php_manual_en.chm' PHP succeeds an older product, named PHP/FI. PHP/FI was created by Rasmus Lerdorf in 1995, initially as a simple set of Perl scripts for tracking accesses to his online resume. He named this

Re: [PHP] Question about apache-php concurrent process control

2005-07-19 Thread Liang ZHONG
Hi André, It sounds interesting. But since I am pretty new to PHP, I have some questions, naive maybe, about what you wrote. #!/bin/sh\n/path/to/script/Send.php 12 \n What does the Send.php look like? I do not have idea how a shell interprets an php script and what the parameter 12 means

RE: [PHP] Question about apache-php concurrent process control

2005-07-19 Thread Liang ZHONG
Can somebody here help me to delete my message? People who read this must be laughing at me. :) snipIt seems Rasmus is famous, and I should have shown my respect./snip history src = 'php_manual_en.chm' PHP succeeds an older product, named PHP/FI. PHP/FI was created by Rasmus Lerdorf in

Re: [PHP] Question about apache-php concurrent process control

2005-07-17 Thread André Medeiros
I did something like that for a newsletter sending script. Basiclly, I had two scripts: a) AddEdit.php that would list the newsletter's items and allow it to send b) Send.php that was a script I ran on the background When pressed Send on AddEdit, it would do something like $tempName = tempnam(

Re: [PHP] Question about apache-php concurrent process control

2005-07-16 Thread rouvas
Hi Liang, trying to get conclusive results with browsers is futile. Use a command-line tool (like curl) to invoke the web pages and get the results. Or you can use PHP's own function to query the web server and do your own timing with microtime() function or another suitable for your purposes.

Re: [PHP] Question about apache-php concurrent process control

2005-07-16 Thread Rory Browne
On 7/16/05, rouvas [EMAIL PROTECTED] wrote: Hi Liang, trying to get conclusive results with browsers is futile. Use a command-line tool (like curl) to invoke the web pages and get the results. Or you can use Although personally I think that telnet-to-port-80 would be a better idea, in this

Re: [PHP] Question about apache-php concurrent process control

2005-07-15 Thread Rasmus Lerdorf
Liang wrote: I am a programmer and new to php. I wonder what process control can php interpreter do for multithreading . I notice that through http request, php interpreter can execute 2 php programs simataneously, but will only sequentially queued and execute if I try to execute one php

Re: [PHP] Question about apache-php concurrent process control

2005-07-15 Thread Liang ZHONG
thing. Or 2 php interpreter processes process one php program sepreately without interfer with each other. Hope I have explained myself clearly. Thank you. From: Rasmus Lerdorf [EMAIL PROTECTED] To: Liang [EMAIL PROTECTED] CC: php-general@lists.php.net Subject: Re: [PHP] Question about

Re: [PHP] Question about apache-php concurrent process control

2005-07-15 Thread Rasmus Lerdorf
Liang ZHONG wrote: As I know, apache-php works this way. When the web server gets an http request with file name extension .php, it will start the php interpreter to process the php file. Now I have a php program does something like this: when it is executing with one parameter p1, the

Re: [PHP] Question about apache-php concurrent process control

2005-07-15 Thread Liang ZHONG
Could you please explain it a little bit more? I did test this way. The code is the same for a.php and b.php ?php sleep(20); print Done. br /; ? I place request from 2 browser windows. First time, I placed with http://baseURL/a.php with both 2 browsers, starting times have 5

Re: [PHP] Question about apache-php concurrent process control

2005-07-15 Thread Rasmus Lerdorf
Liang ZHONG wrote: Could you please explain it a little bit more? I did test this way. The code is the same for a.php and b.php ?php sleep(20); print Done. br /; ? I place request from 2 browser windows. First time, I placed with http://baseURL/a.php with both 2

Re: [PHP] Question about apache-php concurrent process control

2005-07-15 Thread Liang ZHONG
Hi Rasmus, You are right. It was the problem with the browser. I used Mozilla Firefox to try, and do not know what consideration it just serialized the identical url http requests. I then turned to use 2 IE 6.0 windows, 2 tabs within Maxthon browser, one IE windows and one Firefox, to test.

RE: [PHP] Question to eregi Syntax

2005-07-07 Thread Shaw, Chris - Accenture
Do a search on the php website or the php offline manual for Pattern Syntax -Original Message- From: janbro [mailto:[EMAIL PROTECTED] Sent: 07 July 2005 15:30 To: php-general@lists.php.net Subject: [PHP] Question to eregi Syntax * This e-mail has

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-28 Thread Jasper Bryant-Greene
Kevin L'Huillier wrote: On 27/06/05, Dr. Brad Lustick [EMAIL PROTECTED] wrote: I'm a novice trying to understand the exact construction of code for doing an HTTP 301 permanent redirect for a server coded in PHP. Could someone please tell me how I would handle the following example? In your

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-28 Thread Jochem Maas
Jasper Bryant-Greene wrote: Kevin L'Huillier wrote: On 27/06/05, Dr. Brad Lustick [EMAIL PROTECTED] wrote: I'm a novice trying to understand the exact construction of code for doing an HTTP 301 permanent redirect for a server coded in PHP. Could someone please tell me how I would handle the

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-28 Thread Jasper Bryant-Greene
Jochem Maas wrote: header('HTTP/1.1 301 Moved Permanently'); also consider that using 'Status' may be better or possibly both to cover you bases, e.g.: ?php header(HTTP/1.1 301 Moved Permanently); header(Status: 301 Moved Permanently); ? Waste of time. Go read the HTTP

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-28 Thread Marek Kilimajer
Jasper Bryant-Greene wrote: Jochem Maas wrote: header('HTTP/1.1 301 Moved Permanently'); also consider that using 'Status' may be better or possibly both to cover you bases, e.g.: ?php header(HTTP/1.1 301 Moved Permanently); header(Status: 301 Moved Permanently); ? Waste of

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-28 Thread Jochem Maas
Jasper Bryant-Greene wrote: Jochem Maas wrote: header('HTTP/1.1 301 Moved Permanently'); also consider that using 'Status' may be better or possibly both to cover you bases, e.g.: ?php header(HTTP/1.1 301 Moved Permanently); header(Status: 301 Moved Permanently); ? Waste of

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-28 Thread Andy Pieters
Hi Actually you can get away with this: header(Location: $url,301); This will let php generate the proper headers Also, and I stress this point (again and again), the http specification clearly states that location headers need to have a *fully qualified url* not a site-specific one.

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-28 Thread Andy Pieters
On Wednesday 29 June 2005 00:31, Andy Pieters wrote: Hi Actually you can get away with this: header(Location: $url,301); Well it looks like we all make typos Header(Location: $url,true,301); is more like it This will let php generate the proper headers Also, and I stress this point

Re: [PHP] Question about HTTP 301 permanent redirects

2005-06-27 Thread Kevin L'Huillier
On 27/06/05, Dr. Brad Lustick [EMAIL PROTECTED] wrote: I'm a novice trying to understand the exact construction of code for doing an HTTP 301 permanent redirect for a server coded in PHP. Could someone please tell me how I would handle the following example?

Re: [PHP] Question to example from manual

2005-06-16 Thread Richard Lynch
On Thu, June 16, 2005 1:31 pm, janbro said: Hi, I've been working on this example and copied it in my webroot, it doesn't give me an output. Does anybody know why? System WinXP Apache 2.0.50 php 5.0.3 thx janbro Example 7-6. Static variables with recursive functions ?php function

Re: [PHP] question about system function call

2005-06-16 Thread Richard Lynch
On Thu, June 16, 2005 2:43 pm, Tom Cruickshank said: I'm trying to do the following in php. system(/usr/bin/smbutil -v view //[EMAIL PROTECTED]) to be able to view some shares folders on a server. Unfortunately, if I use this command in console, I get prompted for a password. Is

Re: [PHP] Question about acessing databases and formatting output

2005-05-10 Thread The Doctor
On Mon, May 09, 2005 at 10:41:22PM +0530, bala chandar wrote: On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Mon, May 09, 2005 at 08:19:47PM +0530, bala chandar wrote: Hi, On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Mon, May 09, 2005 at 08:29:34AM +0530, bala chandar

Re: [PHP] Question about acessing databases and formatting output

2005-05-09 Thread The Doctor
On Mon, May 09, 2005 at 08:29:34AM +0530, bala chandar wrote: On 5/9/05, bala chandar [EMAIL PROTECTED] wrote: Hi On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Sun, May 08, 2005 at 01:49:08PM -0600, The Doctor wrote: On Sun, May 08, 2005 at 08:56:25PM +0530, bala chandar wrote:

Re: [PHP] Question about acessing databases and formatting output

2005-05-09 Thread bala chandar
Hi, On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Mon, May 09, 2005 at 08:29:34AM +0530, bala chandar wrote: On 5/9/05, bala chandar [EMAIL PROTECTED] wrote: Hi On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Sun, May 08, 2005 at 01:49:08PM -0600, The Doctor wrote: On

Re: [PHP] Question about acessing databases and formatting output

2005-05-09 Thread The Doctor
On Mon, May 09, 2005 at 08:19:47PM +0530, bala chandar wrote: Hi, On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Mon, May 09, 2005 at 08:29:34AM +0530, bala chandar wrote: On 5/9/05, bala chandar [EMAIL PROTECTED] wrote: Hi On 5/9/05, The Doctor [EMAIL PROTECTED] wrote:

Re: [PHP] Question about acessing databases and formatting output

2005-05-09 Thread bala chandar
On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Mon, May 09, 2005 at 08:19:47PM +0530, bala chandar wrote: Hi, On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Mon, May 09, 2005 at 08:29:34AM +0530, bala chandar wrote: On 5/9/05, bala chandar [EMAIL PROTECTED] wrote: Hi

Re: [PHP] Question about acessing databases and formatting output

2005-05-08 Thread The Doctor
On Thu, May 05, 2005 at 05:49:38AM -0600, The Doctor wrote: On Thu, May 05, 2005 at 10:11:14AM +0530, bala chandar wrote: hi, On 5/5/05, The Doctor [EMAIL PROTECTED] wrote: This is probably easy, but how does one access a database, mysql or oracle or postgresql, and present the

Re: [PHP] Question about acessing databases and formatting output

2005-05-08 Thread bala chandar
On 5/8/05, The Doctor [EMAIL PROTECTED] wrote: On Thu, May 05, 2005 at 05:49:38AM -0600, The Doctor wrote: On Thu, May 05, 2005 at 10:11:14AM +0530, bala chandar wrote: hi, On 5/5/05, The Doctor [EMAIL PROTECTED] wrote: This is probably easy, but how does one access a database,

Re: [PHP] Question about acessing databases and formatting output

2005-05-08 Thread The Doctor
On Sun, May 08, 2005 at 08:56:25PM +0530, bala chandar wrote: On 5/8/05, The Doctor [EMAIL PROTECTED] wrote: On Thu, May 05, 2005 at 05:49:38AM -0600, The Doctor wrote: On Thu, May 05, 2005 at 10:11:14AM +0530, bala chandar wrote: hi, On 5/5/05, The Doctor [EMAIL PROTECTED]

Re: [PHP] Question about acessing databases and formatting output

2005-05-08 Thread The Doctor
On Sun, May 08, 2005 at 01:49:08PM -0600, The Doctor wrote: On Sun, May 08, 2005 at 08:56:25PM +0530, bala chandar wrote: On 5/8/05, The Doctor [EMAIL PROTECTED] wrote: On Thu, May 05, 2005 at 05:49:38AM -0600, The Doctor wrote: On Thu, May 05, 2005 at 10:11:14AM +0530, bala chandar

Re: [PHP] Question about acessing databases and formatting output

2005-05-08 Thread bala chandar
Hi On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Sun, May 08, 2005 at 01:49:08PM -0600, The Doctor wrote: On Sun, May 08, 2005 at 08:56:25PM +0530, bala chandar wrote: On 5/8/05, The Doctor [EMAIL PROTECTED] wrote: On Thu, May 05, 2005 at 05:49:38AM -0600, The Doctor wrote: On

Re: [PHP] Question about acessing databases and formatting output

2005-05-08 Thread bala chandar
On 5/9/05, bala chandar [EMAIL PROTECTED] wrote: Hi On 5/9/05, The Doctor [EMAIL PROTECTED] wrote: On Sun, May 08, 2005 at 01:49:08PM -0600, The Doctor wrote: On Sun, May 08, 2005 at 08:56:25PM +0530, bala chandar wrote: On 5/8/05, The Doctor [EMAIL PROTECTED] wrote: On Thu, May

Re: [PHP] Question about acessing databases and formatting output

2005-05-05 Thread The Doctor
On Thu, May 05, 2005 at 10:11:14AM +0530, bala chandar wrote: hi, On 5/5/05, The Doctor [EMAIL PROTECTED] wrote: This is probably easy, but how does one access a database, mysql or oracle or postgresql, and present the data in a tabular format? -- Member - Liberal International

Re: [PHP] Question about acessing databases and formatting output

2005-05-04 Thread bala chandar
hi, On 5/5/05, The Doctor [EMAIL PROTECTED] wrote: This is probably easy, but how does one access a database, mysql or oracle or postgresql, and present the data in a tabular format? -- Member - Liberal International This is [EMAIL PROTECTED] Ici [EMAIL PROTECTED] God Queen and

RE: [PHP] Question regarding PDF creation

2005-04-18 Thread Chris W. Parker
Mário Gamito mailto:[EMAIL PROTECTED] on Monday, April 18, 2005 3:01 AM said: I'm using FPDF (http://www.fpdf.org/) to create a... PDF. First of all thanks for asking this question because I was in need of building PDFs and lo and behold FPDF works great so far! $pdf-Cell(60,10,'Powered

Re: [PHP] Question about fsockopen

2005-04-11 Thread Hans Juergen von Lengerke
Date: Sun, 10 Apr 2005 08:00:23 - (UTC) From: [EMAIL PROTECTED] I have several IP in one interface (eth0) in my server and I want make connection to another server (check email, etc) using different ip for every mail server. I was read the document, and there is no way how to make this

Re: [PHP] Question about fsockopen

2005-04-11 Thread Richard Lynch
On Sun, April 10, 2005 1:00 am, [EMAIL PROTECTED] said: I have several IP in one interface (eth0) in my server and I want make connection to another server (check email, etc) using different ip for every mail server. I was read the document, and there is no way how to make this happen. Any

Re: [PHP] Question about fsockopen

2005-04-10 Thread Josip Dzolonga
[EMAIL PROTECTED] wrote: Dear list, I have several IP in one interface (eth0) in my server and I want make connection to another server (check email, etc) using different ip for every mail server. I was read the document, and there is no way how to make this happen. Any idea? Thank you Take a

Re: [PHP] Question about fsockopen

2005-04-10 Thread php
Dear lists, I have tested it but it's not what I want to do. I am looking for any method to make multi connection with many ip from my box to download email from different mailserver. Thank you David T [EMAIL PROTECTED] wrote: Dear list, I have several IP in one interface (eth0) in my

Re: [PHP] Question about fsockopen

2005-04-10 Thread Greg Donald
On Apr 10, 2005 9:12 PM, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: I have tested it but it's not what I want to do. I am looking for any method to make multi connection with many ip from my box to download email from different mailserver. The method I'd use to fetch mail is fetchmail.

RE: [PHP] Question about shortening a string

2005-03-16 Thread Kim Madsen
-Original Message- From: Steve Slater [mailto:[EMAIL PROTECTED] Sent: Saturday, March 12, 2005 5:29 PM $name_array = explode( ,$name); $short_name = $name_array[0] . end($name_array); And a dozen other ways to do it I'm sure. I just finished a project with a mess of pattern matching

Re: [PHP] Question about shortening a string

2005-03-12 Thread Steve Slater
At 11:54 PM 3/11/2005, Stephen Johnson wrote: Just a quick and dirty solution - but couldn't you explode the name into an array and use the first and last array fields ? $name_array = explode( ,$name); $short_name = $name_array[0] . end($name_array); And a dozen other ways to do it I'm sure. I

Re: [PHP] Question about shortening a string

2005-03-11 Thread Steve Slater
Mario, Many ways to do it, most using regex. This is not as clean as it can be but still shows the idea: ?php $name = Mario Augusto Machado dos Reis Gamito; preg_match (/^(\w+)(\W*)(\w+\W+)*(\w+)$/,$name,$matches); $short_name = $matches[1] $matches[4]; ? This example works for any number of

Re: [PHP] Question about shortening a string

2005-03-11 Thread Stephen Johnson
Just a quick and dirty solution - but couldn't you explode the name into an array and use the first and last array fields ? On Mar 11, 2005, at 11:39 PM, Steve Slater wrote: Mario, Many ways to do it, most using regex. This is not as clean as it can be but still shows the idea: ?php $name =

Re: [PHP] Question re empty query

2005-03-09 Thread Jochem Maas
Jackson Linux wrote: Hi, This: if (isset($_GET['r']) !empty($_GET['r']) ($r = intval($_GET['r'])) ){ $r = {$_GET['r']}; //Set the variable $r to mean the category number for starters WTF is the preceding statement for??? $r is already set if it exists by the expression in the if

Re: [PHP] Question: re: Session-only cookies and Firefox

2005-02-14 Thread Richard Lynch
RGL wrote: Question: Has anybody else noticed session-only cookies not disappearing when using Firefox? Is this a Firefox bug (should they be notified/ or I get latest Firefox) ? Using IE6 I can: setcookie('sesvar', 'this session only', 0, , www.mypersonaldomain.net); This can be read and

RE: [PHP] Question about php.ini

2005-02-07 Thread Jay Blanchard
[snip] 1.) rename the php.ini.default to plain php.ini and see if that resolves it. However, I'm not sure what kind of tests can I perform to see that it is working properly? [/snip] How about just making a copy of the file and testing it? Have you run phpinfo() yet? -- PHP General Mailing List

RE: [PHP] Question about php.ini

2005-02-07 Thread Jay Blanchard
[snip] Yup, I have tried making a copy of it. I'm just not exactly sure how to test it? I ran phpinfo() , and it runs even without a php.ini. [/snip] Change something in the configuation file that you know you can run a test on, like safe mode status, then restart Apache and conduct the test.

Re: [PHP] Question about php.ini

2005-02-07 Thread Richard Lynch
Stephen Wong wrote: I'm very new to php. Here are some basic info about my server that I am running: Mac OS X 10.3.7 PHP 4.3.10 MySQL 4.0.18 Apache 1.3.33 What I want to do is host a forum on my web page. I can't seem to get it set up, and I notice that I do not have a php.ini file in

RE: [PHP] Question about php.ini

2005-02-07 Thread Brandon Thompson
PROTECTED] Sent: Monday, February 07, 2005 12:53 PM To: Stephen Wong Cc: php-general@lists.php.net Subject: RE: [PHP] Question about php.ini [snip] Yup, I have tried making a copy of it. I'm just not exactly sure how to test it? I ran phpinfo() , and it runs even without a php.ini. [/snip

RE: [PHP] Question about Safe Mode

2005-01-31 Thread Jay Blanchard
[snip] So... how do I work around this? Can I get php to write the files so they aren't owned by apache but rather thwn owner of the php script that creates them? [/snip] PHP scripts run by the HTTP server are run as the web server. The web server runs as 'Apache', so Apache needs permissions

Re: [PHP] Question about Safe Mode

2005-01-31 Thread Marek Kilimajer
Rick Root wrote: I have a little home made CMS that writes files... on the server I've recently installed this CMS on, those files get written as apache:apache ... that file uses include to include other files that are not owned by apache, and this doesn't work. Warning: main(): SAFE MODE

Re: [PHP] question on getting URL

2005-01-30 Thread Matthew Fonda
$file = basename(_FILE_); On Sun, 2005-01-30 at 01:26, David Banning wrote: I have a script called index.php on my main page and it actually is used to launch several webpages like so; http://mysite.com/index.php?id=16 When http://mysite.com runs it still uses index.php. but it doesn't

RE: [PHP] question about a cron job

2005-01-17 Thread Jay Blanchard
[snip] I've got a question about the following cronjob. #At 3:01 our time, run backups 1 0 * * * /usr/local/bin/php /www/r/rester/htdocs/auto_backup/back_em_up.php /www/r/rester/htdocs/auto_backup/cron.log 21 #At 3:02 clean up sessions folder 2 0 * * * (find /www/r/rester/htdocs/sessions/

Re: [PHP] question about a cron job

2005-01-17 Thread Al
Jay Blanchard wrote: [snip] I've got a question about the following cronjob. #At 3:01 our time, run backups 1 0 * * * /usr/local/bin/php /www/r/rester/htdocs/auto_backup/back_em_up.php /www/r/rester/htdocs/auto_backup/cron.log 21 #At 3:02 clean up sessions folder 2 0 * * * (find

Re: [PHP] question about a cron job

2005-01-17 Thread Erwin Kerk
Al wrote: I've got a question about the following cronjob. #At 3:01 our time, run backups 1 0 * * * /usr/local/bin/php /www/r/rester/htdocs/auto_backup/back_em_up.php /www/r/rester/htdocs/auto_backup/cron.log 21 #At 3:02 clean up sessions folder 2 0 * * * (find /www/r/rester/htdocs/sessions/

RE: [PHP] question about a cron job

2005-01-17 Thread Michael Sims
#this is only for testing a new cronjob, every minute * * * * * /usr/local/bin/php /www/r/rester/htdocs/phpList_cronjob/process_cronjob.php /www/r/rester/htdocs/phpList_cronjob/cron.log 21 The new one doesn't seem to want to run until after 3:01 or 3:02. Shouldn't the sever just run it

Re: [PHP] question about a cron job

2005-01-17 Thread Al
Erwin Kerk wrote: Al wrote: I've got a question about the following cronjob. #At 3:01 our time, run backups 1 0 * * * /usr/local/bin/php /www/r/rester/htdocs/auto_backup/back_em_up.php /www/r/rester/htdocs/auto_backup/cron.log 21 #At 3:02 clean up sessions folder 2 0 * * * (find

Re: [PHP] question about a cron job

2005-01-17 Thread Bret Hughes
On Mon, 2005-01-17 at 09:01, Erwin Kerk wrote: Al wrote: I've got a question about the following cronjob. #At 3:01 our time, run backups 1 0 * * * /usr/local/bin/php /www/r/rester/htdocs/auto_backup/back_em_up.php /www/r/rester/htdocs/auto_backup/cron.log 21 #At 3:02 clean up

RE: [PHP] question about a cron job

2005-01-17 Thread Michael Sims
Erwin Kerk wrote: The CRON daemon only refreshes it's job list after a job in the current list is completed. Therefore, the CRON daemon won't notice the every-minute job until 3.01 pm. I'm not sure I understand what you're saying above. Can you provide a pointer to documentation about this?

Re: [PHP] question about a cron job

2005-01-17 Thread Jason Wong
On Monday 17 January 2005 23:19, Al wrote: Erwin Kerk wrote: Al wrote: The CRON daemon only refreshes it's job list after a job in the current list is completed. Therefore, the CRON daemon won't notice the every-minute job until 3.01 pm. Not sure if I've misunderstood what Al is saying

Re: [PHP] question about a cron job

2005-01-17 Thread Jochem Maas
Michael Sims wrote: Erwin Kerk wrote: The CRON daemon only refreshes it's job list after a job in the current list is completed. Therefore, the CRON daemon won't notice the every-minute job until 3.01 pm. I'm not sure I understand what you're saying above. Can you provide a pointer to

RE: [PHP] question about a cron job

2005-01-17 Thread Michael Sims
Jochem Maas wrote: Michael Sims wrote: Additionally, cron checks each minute to see if its spool directory's modtime (or the modtime on /etc/crontab) has changed, and if it has, cron will then examine the modtime on all crontabs and reload those which have changed. Thus cron need not be

Re: [PHP] question about a cron job

2005-01-17 Thread Al
Michael Sims wrote: Erwin Kerk wrote: The CRON daemon only refreshes it's job list after a job in the current list is completed. Therefore, the CRON daemon won't notice the every-minute job until 3.01 pm. I'm not sure I understand what you're saying above. Can you provide a pointer to

Re: [PHP] question about a cron job

2005-01-17 Thread Jochem Maas
Michael Sims wrote: Jochem Maas wrote: Michael Sims wrote: Additionally, cron checks each minute to see if its spool directory's modtime (or the modtime on /etc/crontab) has changed, and if it has, cron will then examine the modtime on all crontabs and reload those which have changed. Thus

RE: [PHP] Question: arrays and form elements

2004-12-30 Thread Jay Blanchard
[snip] Generally, when I set up a form where, for example, I'll be taking multiple selections from a list I would set the variable / element name as myvar[]. So I have the brackets [] after the variable name to make it an array. What I want to know is there a way to get around the use of this

Re: [PHP] Question: arrays and form elements

2004-12-30 Thread Brent Baisley
Nope. Is there a problem you are having with using that syntax? If you are having trouble with referencing the fields with javascript, you can't use the regular syntax you are used to.: document.formname.fieldname[] That will give you an error because of the brackets. In javascript you'll need

Re: [PHP] Question about dates

2004-12-24 Thread Greg Donald
On Fri, 24 Dec 2004 08:46:28 -0600, Brent Clements [EMAIL PROTECTED] wrote: How does one over come the issue of unix time not going beyond a certain date? Overcome the issue in what way? A 32bit integer is what it is. ie, when I do echo strtotime(2099-10-08); it outputs -1 So don't use

Re: [PHP] Question

2004-12-17 Thread Ligaya Turmelle
I assume by edit you mean change the value to something completely new. If you are having the user input the new value you 1) must make sure it is valid input and 2)move it into the array value (maybe set the array as a session variable so it crosses over to the next page instead of being re

RE: [PHP] Question in posting form-data

2004-12-17 Thread Richard Lynch
Yao, Minghua wrote: Yes. I did modify the original since I need to send data to a program which takes only form-data. content-disposition: came from RFC 2388. I don't think the program can take application/x-www-form-urlencoded content. Further help needed. Try it the old way -- I suspect

RE: [PHP] Question in posting form-data

2004-12-17 Thread Yao, Minghua
] Sent: Fri 12/17/2004 11:27 AM To: Yao, Minghua Cc: Erwin Kerk; [EMAIL PROTECTED] Subject: RE: [PHP] Question in posting form-data Yao, Minghua wrote: Yes. I did modify the original since I need to send data to a program which takes only form-data. content-disposition: came from RFC 2388. I

Re: [PHP] Question in posting form-data

2004-12-16 Thread Erwin Kerk
Yao, Minghua wrote: Hi, all, I am testing how to post form-data to a host using the following code (test.php): ?php function PostToHost($host, $path, $name, $value) { // Test of posting form-data $fp = fsockopen($host,80); fputs($fp, POST

RE: [PHP] Question in posting form-data

2004-12-16 Thread Richard Lynch
. -Minghua -Original Message- From: Erwin Kerk [mailto:[EMAIL PROTECTED] Sent: Thu 12/16/2004 6:30 AM To: Yao, Minghua Cc: [EMAIL PROTECTED] Subject: Re: [PHP] Question in posting form-data Yao, Minghua wrote: Hi, all, I am testing how to post form-data to a host using the following

Re: [PHP] Question

2004-12-16 Thread Richard Lynch
Dennis Yang wrote: I'm using PHP 4.3.2 and using ODBC to connect to my Access database. I want to get the value from this query statement: select count(id) as quantity from danhmucdia. How can I get this value? How can I equalize this value into variable ? It's a query, just like any other

RE: [PHP] Question in posting form-data

2004-12-16 Thread Yao, Minghua
: Richard Lynch [mailto:[EMAIL PROTECTED] Sent: Thu 12/16/2004 11:46 AM To: Yao, Minghua Cc: Erwin Kerk; [EMAIL PROTECTED] Subject: RE: [PHP] Question in posting form-data You also need to URLEncode the $value, either before you pass it in, or inside the function itself. Where did you get this PostToHost

RE: [PHP] Question in posting form-data

2004-12-16 Thread Yao, Minghua
Thanks. I changed fputs($fp, $value\n); to fputs($fp, $name=$value\n); But I still got the same message. -Minghua -Original Message- From: Erwin Kerk [mailto:[EMAIL PROTECTED] Sent: Thu 12/16/2004 6:30 AM To: Yao, Minghua Cc: [EMAIL PROTECTED] Subject: Re: [PHP] Question in posting

Re: [PHP] Question: Repopulating form parameters

2004-12-13 Thread Jason Wong
On Monday 13 December 2004 18:29, Stuart Felenstein wrote: I think you are missing the point Jason was trying to make, which is the difference between '$Ind' and $Ind. If you look again, you will see that those are handled differently. If you read the post Jason suggested I print out

Re: [PHP] Question: Repopulating form parameters

2004-12-13 Thread Jason Wong
On Monday 13 December 2004 19:00, Stuart Felenstein wrote: heaven's sake ? bit over dramatic. The code above is my created html. I've created a number of them, both from a table and just listing out some options. To repeat they all work . Yet all seem to have little in common when the values

RE: [PHP] Question: Repopulating form parameters

2004-12-13 Thread Ford, Mike
To view the terms under which this email is distributed, please go to http://disclaimer.leedsmet.ac.uk/email.htm On 12 December 2004 14:27, Stuart Felenstein wrote: --- Jason Wong [EMAIL PROTECTED] wrote: If in doubt, print it out (TM) echo '$Indbr', $Indbr, $Ind; $Ind

<    1   2   3   4   5   6   7   8   9   10   >