Re: [PHP] Quidelines for Site visitor counter

2005-07-11 Thread Richard Lynch
On Mon, July 11, 2005 10:58 pm, William Stokes said: > I would like to add a visitor counter to my site. I know that there are > plenty of free and nice applications/scripts for this avalable but I would > like to write my own. I'm at the moment thinking either to make graphical > or > text based u

Re: [PHP] constructors in PHP

2005-07-11 Thread Richard Lynch
On Mon, July 11, 2005 9:53 am, Psystorm said: > Burhan Khalid wrote: > >> Alessandro Rosa wrote: >> >>> Thanks to all for clear responses! >>> >>> So just a question now, why have not multiple constructors been >>> implemented? >>> Are there some security issues related to them ? >> >> >> As far as

Re: [PHP] still trying to cURL.

2005-07-11 Thread Richard Lynch
Try closing your cURL handle and making a new one before you get the page that's giving you trouble. Sometimes cURL maintains "state" that it shouldn't. You'll maybe need to get the Cookies "by hand" from the header and send them back as headers -- Not sure a Cookie Jar can survive a new handle.

Re: [PHP] constructors in PHP

2005-07-11 Thread Richard Lynch
On Mon, July 11, 2005 10:04 am, Alessandro Rosa said: >> > As far as I know, its not a security issue, but a structure/design > issue. >> >> The issue is that in php you can't definitely say what type a variable >> is , whereas in c++ you can say this variable is a string, this one a >> int, …. > >

Re: [PHP] libssl.so.0.9.7

2005-07-11 Thread Richard Lynch
Check if you've got "leftover" 0.9.7 library sitting around. Perhaps you put 0.9.8 in /usr/local/lib, but 0.9.7 is still in /usr/lib If you have "locate" you can just do: locate libssl.so and see what turns up On Mon, July 11, 2005 10:09 am, [EMAIL PROTECTED] said: > Hello, > > I've upgraded to

Re: [PHP] how to get time cost for MySQL query

2005-07-11 Thread Richard Lynch
Try doing an "explain $query" query. I *think* MySQL might cache the query/results enough that you'd get an accurate estimate... You could also turn MySQL Logging on. Or, rather crudely, time it in PHP: $query_start_time = microtime(); $result = mysql_query($query); $query_end_time = microtime(

[PHP] Quidelines for Site visitor counter

2005-07-11 Thread William Stokes
Hello, I would like to add a visitor counter to my site. I know that there are plenty of free and nice applications/scripts for this avalable but I would like to write my own. I'm at the moment thinking either to make graphical or text based user interface for this statistics counter. So I'm as

Re: [PHP] creating of multi dimensional arrays with unknown depth

2005-07-11 Thread Richard Lynch
On Mon, July 11, 2005 10:56 am, Ben-Nes Yonatan said: > Hi all! > > I got a string which include information for categories that I need to > build, the string is built like this: > $string = "val1~~val2~~val3~~val4~~val5" > > Now, I want to create from this string a multi dimensional array an

RE: [PHP] Help installing on Win2003 server?

2005-07-11 Thread Richard Lynch
On Mon, July 11, 2005 12:43 pm, Grosz, Steve (IPG IT) said: > I get a message in the browser saying it can't find the file, will find > standard .htm or .cfm files, but when I try to browse to a .php file, > nothing. What is the EXACT error message?... An error message isn't "nothing" -- It's an

Re: [PHP] Some CLASS file help, should be a quick answer...

2005-07-11 Thread Richard Lynch
On Mon, July 11, 2005 4:05 pm, Matt Babineau said: > Ok so I set a variable at the top of my class definition > > var $tmp; > < bunch of functions> > > Function $func1() { You don't really have a $ before the function name, right?... > > $n = $this->result_from_another_function($var1

Re: [PHP] how to delete lines in a txt file using php.

2005-07-11 Thread Richard Lynch
On Mon, July 11, 2005 4:13 pm, babu said: > $f=fopen($file,"w"); http://php.net/fopen "w" will open the file for WRITING, a fresh, new, EMPTY file. You want "r+" or "a+" or "w+" or something similar. -- Like Music? http://l-i-e.com/artists.htm -- PHP General Mailing List (http://www.p

Re: [PHP] zlib.output_compression

2005-07-11 Thread LacaK
I see contents using Network Monitor, so I se response header and contents andthey are uncompressed, so somresion does not uccured. It's likely the browser is uncomressing it before you ever see it. I would telnet to port 80 and make an HTTP request to see for sure. -- PHP General Mailing L

[PHP] how to delete lines in a txt file using php.

2005-07-11 Thread babu
Hi i have a txt file like [SUBSTRAT] TYP=25x25_10 SUBSTRATNAME=S112 PIXEL=5 OPERATOR=Zi KOMMENTAR=dunkel INTENSITAET=1000.00 [MESSUNG] DATUM=03.01.2005 UHRZEIT=11:22 MESSUNG=SWEEP_UI i want to delete lines which start with '[' and 'TYP'. i have multiple such files.i have used strstr method.

[PHP] Some CLASS file help, should be a quick answer...

2005-07-11 Thread Matt Babineau
Ok so I set a variable at the top of my class definition var $tmp; < bunch of functions> Function $func1() { $n = $this->result_from_another_function($var1, $var2, $var3); // this function returns an ARRAY //print_r($n); $this->tmp = $n; } When I try to set $thi

RE: [PHP] Two websites need to share part of one database, suggestions please

2005-07-11 Thread Chris W. Parker
André Medeiros on Monday, July 11, 2005 3:08 PM said: > XML is quite easy. Let's say you're making a search for books, and you > have site1.com searching site2.com for some stuff. > > site2.com could have some sort of "back end" like I see what you're saying. But t

Re: [PHP] using require

2005-07-11 Thread Tim Boring
Hello! On Fri, 2005-10-14 at 11:33 -0700, Cima wrote: > hi all, > > > i have my web site working something like this: in every php script i have > require(auth.php). this auth.php has my connection to my postgresql server > and database along with some other stuff i need for the user to be >

Re: [PHP] Two websites need to share part of one database, suggestions please

2005-07-11 Thread André Medeiros
XML is quite easy. Let's say you're making a search for books, and you have site1.com searching site2.com for some stuff. site2.com could have some sort of "back end" like http://site2.com/_backend/search.php?keywords=a+book That would search it's database for the keywords "a book". It could ge

Re: [PHP] Changing directory permissions???

2005-07-11 Thread Al
Steve Buehler wrote: At 02:13 PM 7/11/2005, you wrote: Philip Hallstrom wrote: Is there a way to change directory permissions with pre php5.0? Linux/Apache I'm designing a CM application and would like my code to enable non-techies to be able to create a simple text file. [e.g., directory

RE: [PHP] Two websites need to share part of one database, suggestions please

2005-07-11 Thread Chris W. Parker
André Medeiros on Monday, July 11, 2005 12:44 PM said: > What about using web-services (something ala xml?). Could that be > considered an option? No because I don't how to use that stuff. :) Chris. -- PHP General Mailing List (http://www.php.net/) To unsubscribe

Re: [PHP] Ugh. Need some advice...

2005-07-11 Thread aaronjw
> There is not going to be 1 easy solution that you can just magically tie > in > to your existing design. No matter what solution you chose, you are going > to > have to hack around to get it all working (any pre-written script). If it > "DOES" everything you need, then you are not going to get a

Re: [PHP] Ugh. Need some advice...

2005-07-11 Thread phpninja
There is not going to be 1 easy solution that you can just magically tie in to your existing design. No matter what solution you chose, you are going to have to hack around to get it all working (any pre-written script). If it "DOES" everything you need, then you are not going to get any furthe

Re: [PHP] Changing directory permissions???

2005-07-11 Thread Steve Buehler
At 02:13 PM 7/11/2005, you wrote: Philip Hallstrom wrote: Is there a way to change directory permissions with pre php5.0? Linux/Apache I'm designing a CM application and would like my code to enable non-techies to be able to create a simple text file. [e.g., directory temporarilly from 755 to

Re: [PHP] Ugh. Need some advice...

2005-07-11 Thread aaronjw
> "John Nichel" <[EMAIL PROTECTED]> wrote: > http://www.x-cart.com/ Yeah, I downloaded this to play aorund with it. My problem is I am not that great at working with template engines/system. I don't know where the f#!@ to change anything and the documentation isn't all that self explanatory. >

Re: [PHP] Register globals and ini_set

2005-07-11 Thread Philip Olson
>> If i use, at the beginning of my scripts, >> ini_set('register_globals', 0), register globals will be >> turned off? > if you have php <= 4.2.3 yes, otherwise no. > it has to be set in php.ini, .htaccess, or httpd.conf You may NEVER set register_globals at runtime with ini_set() regardless of

Re: [PHP] Two websites need to share part of one database, suggestions please

2005-07-11 Thread André Medeiros
What about using web-services (something ala xml?). Could that be considered an option? On 7/11/05, Brad Pauly <[EMAIL PROTECTED]> wrote: > On 7/8/05, Chris W. Parker <[EMAIL PROTECTED]> wrote: > > > Which option should I go for? Is there another option I'm not > > considering? > > Another possi

RE: [PHP] Help installing on Win2003 server?

2005-07-11 Thread Grosz, Steve (IPG IT)
I get a message in the browser saying it can't find the file, will find standard .htm or .cfm files, but when I try to browse to a .php file, nothing. -Original Message- From: John Nichel [mailto:[EMAIL PROTECTED] Sent: Monday, July 11, 2005 1:39 PM To: php-general@lists.php.net Subject

Re: [PHP] Changing directory permissions???

2005-07-11 Thread Philip Hallstrom
That is because your php code made the directory and is therefore the owner. My directory already exists and was made by ftp. Well, in that case you are toast... nothing short of becoming the 'ftp' user or becoming the superuser or becoming a member of the group that directory belongs to is g

Re: [PHP] Help installing on Win2003 server?

2005-07-11 Thread John Nichel
Grosz, Steve (IPG IT) wrote: Yes, I have looked at that info, but am still having a problem. And that problem is? Error messages? Logs? -- John C. Nichel ÜberGeek KegWorks.com 716.856.9675 [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://ww

Re: [PHP] Changing directory permissions???

2005-07-11 Thread Al
Philip Hallstrom wrote: The key word is "directory" chmod only works for files PHP5 has a ftp_chmod; but not 4.3.x It works on directories for me... % php -v PHP 4.3.4 (cli) (built: Jul 19 2004 14:52:27) Copyright (c) 1997-2003 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2003 Zen

RE: [PHP] Help installing on Win2003 server?

2005-07-11 Thread Grosz, Steve (IPG IT)
Yes, I have looked at that info, but am still having a problem. -Original Message- From: Jay Blanchard [mailto:[EMAIL PROTECTED] Sent: Monday, July 11, 2005 12:39 PM To: Grosz, Steve (IPG IT); php-general@lists.php.net Subject: RE: [PHP] Help installing on Win2003 server? [snip] No, thi

RE: [PHP] Ugh. Need some advice...

2005-07-11 Thread Jim Moseby
> -Original Message- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: Monday, July 11, 2005 2:42 PM > To: php-general@lists.php.net > Subject: [PHP] Ugh. Need some advice... > > > Sorry for the OT guys but I really need some advice. > > I've just started a new company with a f

Re: [PHP] Changing directory permissions???

2005-07-11 Thread Philip Hallstrom
The key word is "directory" chmod only works for files PHP5 has a ftp_chmod; but not 4.3.x It works on directories for me... % php -v PHP 4.3.4 (cli) (built: Jul 19 2004 14:52:27) Copyright (c) 1997-2003 The PHP Group Zend Engine v1.3.0, Copyright (c) 1998-2003 Zend Technologies % mkdir d %

Re: [PHP] Changing directory permissions???

2005-07-11 Thread Al
The key word is "directory" chmod only works for files PHP5 has a ftp_chmod; but not 4.3.x Philip Hallstrom wrote: Is there a way to change directory permissions with pre php5.0? Linux/Apache I'm designing a CM application and would like my code to enable non-techies to be able to create a

Re: [PHP] Two websites need to share part of one database, suggestions please

2005-07-11 Thread Brad Pauly
On 7/8/05, Chris W. Parker <[EMAIL PROTECTED]> wrote: > Which option should I go for? Is there another option I'm not > considering? Another possibility would be adding a new table that relates products to sites. This allows a one (product) to many (sites) relationship without changing the produ

Re: [PHP] Ugh. Need some advice...

2005-07-11 Thread John Nichel
[EMAIL PROTECTED] wrote: Sorry for the OT guys but I really need some advice. I've just started a new company with a friend/associate of mine where we will be selling about 5 products for now. Obviously, I don't require a major front-end but I do require excellent functionality for the back-end

[PHP] Ugh. Need some advice...

2005-07-11 Thread aaronjw
Sorry for the OT guys but I really need some advice. I've just started a new company with a friend/associate of mine where we will be selling about 5 products for now. Obviously, I don't require a major front-end but I do require excellent functionality for the back-end. Order Management, export

RE: [PHP] Help installing on Win2003 server?

2005-07-11 Thread Jay Blanchard
[snip] No, this is on a IIS6 install [/snip] Have you read this... http://us2.php.net/manual/en/install.windows.iis.php ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Help installing on Win2003 server?

2005-07-11 Thread Grosz, Steve (IPG IT)
No, this is on a IIS6 install, not Apache -Original Message- From: Jay Blanchard [mailto:[EMAIL PROTECTED] Sent: Monday, July 11, 2005 12:27 PM To: Grosz, Steve (IPG IT); php-general@lists.php.net Subject: RE: [PHP] Help installing on Win2003 server? [snip] Can someone tell me where I c

RE: [PHP] Changing directory permissions???

2005-07-11 Thread Jay Blanchard
[snip] Is there a way to change directory permissions with pre php5.0? Linux/Apache I'm designing a CM application and would like my code to enable non-techies to be able to create a simple text file. [e.g., directory temporarilly from 755 to 757 and then back again.] PHP5.0 has a chmod; but not

Re: [PHP] Changing directory permissions???

2005-07-11 Thread Philip Hallstrom
Is there a way to change directory permissions with pre php5.0? Linux/Apache I'm designing a CM application and would like my code to enable non-techies to be able to create a simple text file. [e.g., directory temporarilly from 755 to 757 and then back again.] PHP5.0 has a chmod; but not, 4.

[PHP] Changing directory permissions???

2005-07-11 Thread Al
Is there a way to change directory permissions with pre php5.0? Linux/Apache I'm designing a CM application and would like my code to enable non-techies to be able to create a simple text file. [e.g., directory temporarilly from 755 to 757 and then back again.] PHP5.0 has a chmod; but not, 4.3

RE: [PHP] Two websites need to share part of onedatabase,suggestions please

2005-07-11 Thread Chris W. Parker
Robert Cummings on Friday, July 08, 2005 5:25 PM said: > Thus siteMask should have one of the following values: > > (1 << 1) == 2 // only site1 can use the product. > (1 << 2) == 4 // only site2 can use the product. >

RE: [PHP] Help installing on Win2003 server?

2005-07-11 Thread Jay Blanchard
[snip] Can someone tell me where I can find some detailed instructions on how to install PHP on a Win2003 Server? I've tried to install it using the PHP instructions, but it doesn't seem to be working, think I'm missing something. [/snip] Did you install Apache? -- PHP General Mailing List (http

Re: [PHP] Re: Security, Late Nights and Overall Paranoia

2005-07-11 Thread Evert | Rooftop
The point is.. If you for example only allow and doing this with bbcode would require extra cpu-cycles to convert [i] to I don't really agree with this, because I think escaping the html + replacing bbcode would require less cpu cycles then scanning the string for invalid html and escapin

[PHP] Help installing on Win2003 server?

2005-07-11 Thread Grosz, Steve (IPG IT)
Can someone tell me where I can find some detailed instructions on how to install PHP on a Win2003 Server? I've tried to install it using the PHP instructions, but it doesn't seem to be working, think I'm missing something. Thanks.

Re: Re[6]: [PHP] Re: Security, Late Nights and Overall Paranoia

2005-07-11 Thread Jonathan Kart
I've been loosely following this thread, and have a question now. Isn't one advantage of a bbcode type solution that you can more easily avoid session hijacking vis cross site scripting? If you allow html, then you open the door for people to add eventhandlers. I guess you could always strip the

[PHP] creating of multi dimensional arrays with unknown depth

2005-07-11 Thread Ben-Nes Yonatan
Hi all! I got a string which include information for categories that I need to build, the string is built like this: $string = "val1~~val2~~val3~~val4~~val5" Now, I want to create from this string a multi dimensional array and not one dimension array as explode('~~', $string) will give me.

Re: [PHP] file function

2005-07-11 Thread Joseph Lee
I see. Now I know how it works. Thank you, all, for your great help. Joe --- Burhan Khalid <[EMAIL PROTECTED]> wrote: > Joseph Lee wrote: > > Hi, > > > > I tried file() in the following lines: > > > > >$authFile = file("/tmp/authenticate.txt"); > >print "authFile = $authFile"; > > ?>

Re: [PHP] how to get time cost for MySQL query

2005-07-11 Thread x
I did checked both of them and it seems they do not provide such info... thanks "Philip Hallstrom" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >> Hi, Is there any MySQL lib function which can provide time cost for last >> query? >> > > Maybe... > > http://us2.php.net/manual/en/funct

Re: [PHP] how to get time cost for MySQL query

2005-07-11 Thread x
I did checked both of them and it seems they do not provide such info... thanks "Philip Hallstrom" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >> Hi, Is there any MySQL lib function which can provide time cost for last >> query? >> > > Maybe... > > http://us2.php.net/manual/en/fun

Re: [PHP] constructors in PHP

2005-07-11 Thread Greg Donald
On 7/11/05, Alessandro Rosa <[EMAIL PROTECTED]> wrote: > But, right because PHP is weakly typed, multiple constructors could be > handled easier, I suppose ... isn't true? The sky is the limit with the function handling functions: http://php.net/manual/en/ref.funchand.php -- Greg Donald Zend C

Re: [PHP] searching for files in a directory with a specific structure.

2005-07-11 Thread babu
thanks the format works, i have written some code for deleting some lines from the above obtained files,i have used like keyword match for deleting lines from the above files.the keywords are in the array. can u pls look at the code and check where goes wrong. Stut <[EMAIL PROTECTED]> wrote:

[PHP] libssl.so.0.9.7

2005-07-11 Thread gmourani
Hello, I've upgraded to OpenSSL 0.9.8 and PHP 4.4.0 and get the following error durring compilation. chmod 755 /var/tmp/php-4.4.0-root/usr/lib/httpd/modules/libphp4.so Installing PHP CLI binary:/var/tmp/php-4.4.0-root/usr/bin/ Installing PHP CLI man page: /var/tmp/php-4.4.0-root/usr/

Re: [PHP] constructors in PHP

2005-07-11 Thread Alessandro Rosa
> > As far as I know, its not a security issue, but a structure/design issue. > > The issue is that in php you can't definitely say what type a variable > is , whereas in c++ you can say this variable is a string, this one a > int, …. But, right because PHP is weakly typed, multiple constructors c

Re: [PHP] how to get time cost for MySQL query

2005-07-11 Thread Philip Hallstrom
Hi, Is there any MySQL lib function which can provide time cost for last query? Maybe... http://us2.php.net/manual/en/function.mysql-info.php http://us2.php.net/manual/en/function.mysql-stat.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.

[PHP] still trying to cURL.

2005-07-11 Thread Jon
I have minimal experience with cURL but have had some success with it. I am trying to download some invoices that are posted every month. I am able to get a login to the https: and get the first few pages but when I try to get the invoices I get an error page with this content. HTTP Status 500 -

Re: [PHP] constructors in PHP

2005-07-11 Thread Psystorm
Burhan Khalid wrote: Alessandro Rosa wrote: Thanks to all for clear responses! So just a question now, why have not multiple constructors been implemented? Are there some security issues related to them ? As far as I know, its not a security issue, but a structure/design issue. The iss

[PHP] Problem installing in Win2003 Server SP1

2005-07-11 Thread Grosz, Steve (IPG IT)
I have been trying for several days to get PHP 4.x installed on my Win2003 SP1 server. I am doing the manual (isapi) install. I modified my php.ini file, I think correctly. And added the extension into IIS6, pointing to the \php directory and the php4isapi.dll file. When I try to view a php

[PHP] how to get time cost for MySQL query

2005-07-11 Thread x
Hi, Is there any MySQL lib function which can provide time cost for last query? Since we can see the time cost each time we query MySQL through MySQL console (such as 75 rows in set (0.01 sec)), so I am wondering there is already an existing function which will return the value... Thanks -- PHP

RE: [PHP] iCalendar creation not working with Outlook [SOLVED]

2005-07-11 Thread Chris W. Parker
Daevid Vincent on Saturday, July 09, 2005 7:24 PM said: > I'm sure there's a better way to get the GMT time, as my way is a > total hack. I'm in PST btw, 7 hours from GMT, and I set the party > events to be 6 hours long arbitrarily. Adjust as desired. PST is normall

Re[6]: [PHP] Re: Security, Late Nights and Overall Paranoia

2005-07-11 Thread Richard Davey
Hello Greg, Monday, July 11, 2005, 5:06:51 PM, you wrote: GD> I wouldn't know, isn't one of the tags I allow. If you stick to the plain vanilla HTML tags such as i, b, u, etc then BBCode is pointless - I agreed on this with you several posts ago. I don't however use it just for that, I use it t

Re: Re[4]: [PHP] Re: Security, Late Nights and Overall Paranoia

2005-07-11 Thread Greg Donald
On 7/11/05, Richard Davey <[EMAIL PROTECTED]> wrote: > u wanted to allow a user to say colour a piece of text red, > they'd have to enter x to make it I wouldn't know, isn't one of the tags I allow. > happen? Poor bastards (never mind the fact I'd love to see you use > less CPU cycles to perfect

Re: [PHP] constructors in PHP

2005-07-11 Thread Burhan Khalid
Alessandro Rosa wrote: Thanks to all for clear responses! So just a question now, why have not multiple constructors been implemented? Are there some security issues related to them ? As far as I know, its not a security issue, but a structure/design issue. -- PHP General Mailing List (http:/

[PHP] libssl.so.0.9.7

2005-07-11 Thread gmourani
Hello, I've upgraded to OpenSSL 0.9.8 and PHP 4.4.0 and get the following error durring compilation. chmod 755 /var/tmp/php-4.4.0-root/usr/lib/httpd/modules/libphp4.so Installing PHP CLI binary:/var/tmp/php-4.4.0-root/usr/bin/ Installing PHP CLI man page: /var/tmp/php-4.4.0-root/usr/

Re[4]: [PHP] Re: Security, Late Nights and Overall Paranoia

2005-07-11 Thread Richard Davey
Hello Greg, Monday, July 11, 2005, 3:46:24 PM, you wrote: GD> On 7/11/05, Richard Davey <[EMAIL PROTECTED]> wrote: >> I gave several valid good usability reasons, that I've yet to see >> anyone provide a coherent reason not to use. GD> Misuse of CPU cycles. So if you wanted to allow a user to s

Re: [PHP] searching for files in a directory with a specific structure.

2005-07-11 Thread Stut
babu wrote: I have a directory which has thousands of files based on date. for example mmdd-number(auto increment).txt 20050101-0001.txt,20050101-0002.txt20050101-0210.txt 20050102-0001.txt,20050102-0002.txt..20050102-0141.txt and many

[PHP] searching for files in a directory with a specific structure.

2005-07-11 Thread babu
Hi, I have a directory which has thousands of files based on date. for example mmdd-number(auto increment).txt 20050101-0001.txt,20050101-0002.txt20050101-0210.txt 20050102-0001.txt,20050102-0002.txt..20050102-0141.txt and many other fi

Re: [PHP] constructors in PHP

2005-07-11 Thread Alessandro Rosa
Thanks to all for clear responses! So just a question now, why have not multiple constructors been implemented? Are there some security issues related to them ? Alessandro -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] PHP 4.4.0 Released!

2005-07-11 Thread Derick Rethans
Hello! The PHP Development Team would like to announce the immediate release of PHP 4.4.0. This is a maintenance release that addresses a serious memory corruption problem within PHP concerning references. If references were used in a wrong way, PHP would often create memory corruptions which

Re: [PHP] constructors in PHP

2005-07-11 Thread André Medeiros
On Mon, 2005-07-11 at 16:44 +0200, Alessandro Rosa wrote: > Is there the possibility to have in PHP multiple class constructors > as in C++ or just one ? > I would be sure about it in order to prevent useless mad investigations > in the code I'm writing. > > Thanks in advance ... > > Alessandro R

Re: [PHP] constructors in PHP

2005-07-11 Thread Greg Donald
On 7/11/05, Alessandro Rosa <[EMAIL PROTECTED]> wrote: > Is there the possibility to have in PHP multiple class constructors > as in C++ or just one ? Doesn't seem as though you can: > cat class.php #!/usr/bin/php > ./class.php PHP Fatal error: Cannot redeclare __construct() in /home/greg/c

Re: [PHP] zlib.output_compression

2005-07-11 Thread Greg Donald
On 7/11/05, LacaK <[EMAIL PROTECTED]> wrote: > Can anyone help me with this question : > > when I write script like this : >ini_set('zlib.output_compression', true); > phpinfo(); > ?> > > page displays, that zlib.output_compression is On, but realy is not > compresed (is send only like text

[PHP] constructors in PHP

2005-07-11 Thread Alessandro Rosa
Is there the possibility to have in PHP multiple class constructors as in C++ or just one ? I would be sure about it in order to prevent useless mad investigations in the code I'm writing. Thanks in advance ... Alessandro Rosa

RE: [PHP] error when trying to delete a record

2005-07-11 Thread Jay Blanchard
[snip] Is the above statement true when the id field is numeric (which it surely is in this case)? I get the expected results (in mySQL) when using statements like SELECT name FROM table WHERE id=1 with no single quotes round it. Putting quotes round integer values is counter-intuitive - is it ne

RE: [PHP] error when trying to delete a record

2005-07-11 Thread Mike Johnson
From: Paul Waring [mailto:[EMAIL PROTECTED] > On Mon, Jul 11, 2005 at 03:25:33PM +0100, Mark Rees wrote: > > with no single quotes round it. Putting quotes round > > integer values is counter-intuitive - is it necessary > > in some cases? > > If the field is a numeric type (e.g. INT) as oppose

Re: Re[2]: [PHP] Re: Security, Late Nights and Overall Paranoia

2005-07-11 Thread Greg Donald
On 7/11/05, Richard Davey <[EMAIL PROTECTED]> wrote: > I gave several valid good usability reasons, that I've yet to see > anyone provide a coherent reason not to use. Misuse of CPU cycles. -- Greg Donald Zend Certified Engineer MySQL Core Certification http://destiney.com/ -- PHP General Mail

[PHP] searching for files in a directory.

2005-07-11 Thread babu
Hi, I have a directory which has thousands of files based on date. for example mmdd-number(auto increment).txt 20050101-0001.txt,20050101-0002.txt20050101-0210.txt 20050102-0001.txt,20050102-0002.txt..20050102-0141.txt and many other

Re: [PHP] error when trying to delete a record

2005-07-11 Thread Paul Waring
On Mon, Jul 11, 2005 at 03:25:33PM +0100, Mark Rees wrote: > with no single quotes round it. Putting quotes round integer values is > counter-intuitive - is it necessary in some cases? If the field is a numeric type (e.g. INT) as opposed to numeric data being stored in a character field (e.g. a te

Re: [PHP] error when trying to delete a record

2005-07-11 Thread Mark Rees
""Jay Blanchard"" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] [snip] $query= "DELETE FROM sheet1 WHERE id=$id"; You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 [/snip] try... $query

Re: [PHP] error when trying to delete a record

2005-07-11 Thread John Nichel
Ross wrote: I dunno if my text book is out of date or I have made a syntax error but I am trying to delete a record with $query= "DELETE FROM sheet1 WHERE id=$id"; $result= mysql_query($query); if($result){ echo "it was deleted"; } else echo mysql_error(); } and I get the followi

RE: [PHP] error when trying to delete a record

2005-07-11 Thread Jay Blanchard
[snip] $query= "DELETE FROM sheet1 WHERE id=$id"; You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 [/snip] try... $query= "DELETE FROM sheet1 WHERE id = '".$id."' "; Note the single quotes around

[PHP] error when trying to delete a record

2005-07-11 Thread Ross
I dunno if my text book is out of date or I have made a syntax error but I am trying to delete a record with $query= "DELETE FROM sheet1 WHERE id=$id"; $result= mysql_query($query); if($result){ echo "it was deleted"; } else echo mysql_error(); } and I get the followign sql error

[PHP] CASE Tool For PHP OO Programming

2005-07-11 Thread Pascual De Ruvo
Hi, Can someone suggest a free CASE Tool for UML modelling that generates PHP 5 code? Thanks in advance, Pascual De Ruvo

RE: [PHP] Two websites need to share part of one database, suggestions please

2005-07-11 Thread Nathan Tobik
This seems to be the best option of the one you presented. If you start duplicating data you will have a situation where your data will get out of sync eventually. You can have a lookup table with the keys to the items that belong to website two, just look in the lookup table to get your key, the

Re[2]: [PHP] Re: Security, Late Nights and Overall Paranoia

2005-07-11 Thread Richard Davey
Hello Chris, Sunday, July 10, 2005, 2:31:57 AM, you wrote: CS> I completely agree. I think you'll find that, when pressed, no one CS> can really provide a good reason to use BBCode. I often see CS> security cited as a reason, but it makes no sense. I gave several valid good usability reasons, th

Re: [PHP] getting the email addresses in a sendable format.

2005-07-11 Thread Paul Waring
On Mon, Jul 11, 2005 at 11:20:05AM +0100, Ross wrote: > But I have having trouble assiging them to the variable $recipients. Really > what i want is to convert > > $email_addresses[0] = [EMAIL PROTECTED] > $email_addresses[1] = [EMAIL PROTECTED] > $email_addresses[2] = [EMAIL PROTECTED] > > into

[PHP] getting the email addresses in a sendable format.

2005-07-11 Thread Ross
Hi, I have a database of 300 email addresses retrieved with a select statement. while ($row=mysql_fetch_array($result)) { $email_addresses[] = $row['email']; } But I have having trouble assiging them to the variable $recipients. Really what i want is to convert $email_addresses[0] = [EMA

[PHP] zlib.output_compression

2005-07-11 Thread LacaK
Can anyone help me with this question : when I write script like this : page displays, that zlib.output_compression is On, but realy is not compresed (is send only like text/html) Is possible to turn on compression (enable) in user script (using ini_set), or only disable ini_set('zlib.outpu

Re: [PHP] from tree/hirarki format to table format

2005-07-11 Thread Richard Lynch
On Thu, July 7, 2005 5:36 pm, Feriyanto said: > affid upline sponsor > 1 0 0 > 2 1 1 > 3 1 1 > 4 2 1 > 5 2 2 > 6 3 1 > 7 3 1 > 8 4 1 > 9 4 1 > 105 1 > > > i have table with field and data like abo

Re: [PHP] url reload

2005-07-11 Thread Richard Lynch
On Thu, July 7, 2005 6:40 pm, timothy johnson said: > This should be pretty simple but I cant find any info on it at the > site. I am writing a function that will create a anchor, but I want it > to call the same page it is on. Is there a way to get the current php > page I am on so that when I out

Re: [PHP] Problem serializing a mysqli_result object.

2005-07-11 Thread Richard Lynch
On Thu, July 7, 2005 10:31 pm, Bjarke Freund-Hansen said: > Richard Lynch wrote: > >>On Thu, July 7, 2005 12:53 pm, Bjarke Freund-Hansen said: >> >> You can't serialize resource objects. Try: serialize($res->fetch_assoc()); >>>I know I can serialize the array fetch_assoc retu

Re: [PHP] SESSION

2005-07-11 Thread Richard Lynch
On Sun, July 10, 2005 7:50 pm, Thomas Bonham said: > I have been trying to update & fix the errors. > With the new code (That I will post at the end), I'm only getting one > error and that is that it can't start the session because that it has > been started. Whoops! If you've set php.ini to ALWA

Re: [PHP] Apache 1.3x/PHP 5.0.3 404 error handler & posted data...

2005-07-11 Thread Burhan Khalid
Rasmus Lerdorf wrote: [ snip ] A better option may be to just use mod_rewrite. Something along the lines of: RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)\.html$ $1.php [T=application/x-httpd-php,L] You should verify this with the mod_rewrite docs, but this should only rewrite a reque