php-general Digest 6 Feb 2007 15:09:21 -0000 Issue 4611

2007-02-06 Thread php-general-digest-help
php-general Digest 6 Feb 2007 15:09:21 - Issue 4611 Topics (messages 248417 through 248432): Re: who is online? 248417 by: Richard Lynch Re: is there socket.so file? 248418 by: Craige Leeder Re: PHP book reviewers wanted 248419 by: Manuel Lemos 248420 by:

[PHP] file_get_contents

2007-02-06 Thread Steven Macintyre
Hiya, I need to be able to read a file into a string - I have used the above command and it works ... now ... I need to read a file into a string - that requires a username and password to access the authentication is normal HTTP basic realm Any ideas? Kind Regards Steven Macintyre --

Re: [PHP] Writting a simple proxy in PHP

2007-02-06 Thread Jochem Maas
Alessandro Vernet wrote: I would like to forward on the server side (also called proxy or server-side redirect) some queries that get to my PHP script. A naive approach is to do: print(implode(, file(http://localhost:8090; . $REQUEST_URI))); Where http://localhost:8090 is the address I

[PHP] Graphs

2007-02-06 Thread Kristian Erendi
Hi, I wish to draw graphs on a web page. Can someone tell me which extension or package I should use? Any examples? TIA Krillo

Re: [PHP] Converting string representation of a directory to multi-dimensional array

2007-02-06 Thread Jochem Maas
Richard Lynch wrote: On Mon, February 5, 2007 12:27 pm, Matt Carlson wrote: Over the weekend, I was tasked with taking a string representation of a directory ('\Interface\Addons\some dir\some file'), which can vary in length (no set number of depths) to a multi-dimensional array (i.e.

[PHP] All-in-one PHP Classes

2007-02-06 Thread Tim
Hello folks, Have been reading posts daily for two months now on the list, and am very pleased at how informative these can be. I have noticed, many examples where one is pointed to using classes downloadable on the internet. Not a very big user of these classes my self (maybe a bit naïf in

Re: [PHP] Server Stall

2007-02-06 Thread Stut
Sancar Saran wrote: I think php does not open second thread for same session... Does your script use sessions? If so, then your problem has nothing to do with anything the script is doing and everything to do with PHP locking sessions. * Request 1 does a start_session(), and PHP locks the

Re: [PHP] Graphs

2007-02-06 Thread David Blanco
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi! Kristian Erendi escribió: I wish to draw graphs on a web page. Can someone tell me which extension or package I should use? Any examples? I suppose you mean Statistical graphs. If such a case, try jpgraph http://www.aditus.nu/jpgraph/ For

[PHP] Re: All-in-one PHP Classes

2007-02-06 Thread setcookie
there are special design patterns for autoloading classes and subclasses to use only we needed at runtime! this together with singeltons pattern will prevent any memory overflows. problem is that almost nobody implements these patterns when designing standalone classes fra* Hello folks, Have

RE: [PHP] Graphs

2007-02-06 Thread Jay Blanchard
[snip] I wish to draw graphs on a web page. Can someone tell me which extension or package I should use? Any examples? [/snip] Google for jpgraph -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: file_get_contents

2007-02-06 Thread Colin Guthrie
Steven Macintyre wrote: Hiya, I need to be able to read a file into a string - I have used the above command and it works ... now ... I need to read a file into a string - that requires a username and password to access the authentication is normal HTTP basic realm Any ideas? $var =

Re: [PHP] Server Stall

2007-02-06 Thread Stut
Sancar Saran wrote: Yes you are absolute right. Session was locked... Thanks for info :) No problem, but please include the list in replies especially when you're confirming a possible explanation. It helps improve the usefulness of the archives. -Stut On Tuesday 06 February 2007

Re: [PHP] PHP book reviewers wanted

2007-02-06 Thread tedd
At 8:39 PM -0600 2/5/07, Richard Lynch wrote: On Mon, February 5, 2007 10:09 am, tedd wrote: At 1:05 AM -0200 2/5/07, Manuel Lemos wrote: Demonstrating good English writing skills and having published good book reviews in the past gets me preference. gets me preference ??? Me get any

Re: [PHP] PHP book reviewers wanted

2007-02-06 Thread tedd
At 4:04 AM -0200 2/6/07, Manuel Lemos wrote: Anyway, since you brought that up, I would like to clarify that this is often misunderstood issue. Nobody likes ads, including myself. Ads are obviously necessary to keep the site viable. Otherwise it would have been closed a long time ago. Why are

Re: [PHP] Writting a simple proxy in PHP

2007-02-06 Thread Casey Chu
Try using cUrl. On 2/6/07, Jochem Maas [EMAIL PROTECTED] wrote: Alessandro Vernet wrote: I would like to forward on the server side (also called proxy or server-side redirect) some queries that get to my PHP script. A naive approach is to do: print(implode(, file(http://localhost:8090; .

Re: [PHP] Converting string representation of a directory to multi-dimensional array

2007-02-06 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2007-02-06 12:45:22 +0100: there may also be some kind of solution based on ArrayArrayArrayIteratorIteratorRecursiveArrayIteratorIteratorRecursiveIterator but personally I don't grok those exotic forms of SPL interface well enough to tell you. I had wanted to post

[PHP] Open pop-up stylish window

2007-02-06 Thread Chris Carter
Hi, I am looking for a way to open a preview window. This should be a seperate pop-up but within the same page. The moment the user clicks for say more details » .. this should not open a next page or a pop-up window but a dhtml transparent window that has the short discription. This window

[PHP] Re: Open pop-up stylish window

2007-02-06 Thread Colin Guthrie
Chris Carter wrote: Hi, I am looking for a way to open a preview window. This should be a seperate pop-up but within the same page. The moment the user clicks for say more details » .. this should not open a next page or a pop-up window but a dhtml transparent window that has the short

Re: [PHP] All-in-one PHP Classes

2007-02-06 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2007-02-06 12:47:47 +0100: Have been reading posts daily for two months now on the list, and am very pleased at how informative these can be. I have noticed, many examples where one is pointed to using classes downloadable on the internet. This is when i realized how

Re: [PHP] PHP book reviewers wanted

2007-02-06 Thread Stut
tedd wrote: My point was, or at least my failed attempt was: 1) humor; 2) pointing out a proof reading error in a request for roof reading skills. I found that ironically humorous. HumoUrous roof reading skills you've got there. No disrespect was intended, it was just a jab between posters.

Re: [PHP] file_get_contents

2007-02-06 Thread scotdiddle
Steven, I asked this same question a week or so on the ZEND PHP Fourm See the answer to my post for an elegant solution: http://www.zend.com/forums/index.php?t=msgth=2977start=0S=fe14095d33458d18b9bc49ea04a9a13b Scot L. Diddle, Richmond VA Quoting Steven Macintyre [EMAIL PROTECTED]:

Re: [PHP] Open pop-up stylish window

2007-02-06 Thread Jim Lucas
Chris Carter wrote: Hi, I am looking for a way to open a preview window. This should be a seperate pop-up but within the same page. The moment the user clicks for say more details » .. this should not open a next page or a pop-up window but a dhtml transparent window that has the short

Re: [PHP] Open pop-up stylish window

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 10:09 -0800, Jim Lucas wrote: Chris Carter wrote: Hi, I am looking for a way to open a preview window. This should be a seperate pop-up but within the same page. The moment the user clicks for say more details » .. this should not open a next page or a pop-up

Re: [PHP] Converting string representation of a directory to multi-dimensional array

2007-02-06 Thread Matt Carlson
It will never receive a base name due to the way the data is structured before being passed into the function. I appreciate everyone's input on this. It's been tough for us to develop what we did (since it's such an odd case), and it's good to see other possible methods to do this in a better

Re: [PHP] Writting a simple proxy in PHP

2007-02-06 Thread Alessandro Vernet
Jochem Maas wrote: if your using apache then you should look at the ProxyPass directive - very hand, STW or STA for more detailed info. Jochem, I went this route. I agree, it is much simpler than trying to hack this in PHP. Alex -- View this message in context:

Re: [PHP] Open pop-up stylish window

2007-02-06 Thread Jim Lucas
Robert Cummings wrote: On Tue, 2007-02-06 at 10:09 -0800, Jim Lucas wrote: Chris Carter wrote: Hi, I am looking for a way to open a preview window. This should be a seperate pop-up but within the same page. The moment the user clicks for say more details » .. this should not open a next page

Re: [PHP] Open pop-up stylish window

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 13:05 -0800, Jim Lucas wrote: Robert Cummings wrote: On Tue, 2007-02-06 at 10:09 -0800, Jim Lucas wrote: Chris Carter wrote: Hi, I am looking for a way to open a preview window. This should be a seperate pop-up but within the same page. The moment the user clicks

Re: [PHP] Open pop-up stylish window

2007-02-06 Thread Jim Lucas
Robert Cummings wrote: On Tue, 2007-02-06 at 13:05 -0800, Jim Lucas wrote: Robert Cummings wrote: On Tue, 2007-02-06 at 10:09 -0800, Jim Lucas wrote: Chris Carter wrote: Hi, I am looking for a way to open a preview window. This should be a seperate pop-up but within the same page. The

Re: [PHP] Open pop-up stylish window

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 13:16 -0800, Jim Lucas wrote: Robert Cummings wrote: On Tue, 2007-02-06 at 13:05 -0800, Jim Lucas wrote: Robert Cummings wrote: On Tue, 2007-02-06 at 10:09 -0800, Jim Lucas wrote: Chris Carter wrote: Hi, I am looking for a way to open a preview window. This

Re: [PHP] Writting a simple proxy in PHP

2007-02-06 Thread Jochem Maas
Alessandro Vernet wrote: Jochem Maas wrote: if your using apache then you should look at the ProxyPass directive - very hand, STW or STA for more detailed info. Jochem, I went this route. I agree, it is much simpler than trying to hack this in PHP. it's rather a neat way of solving

Re: [PHP] PHP5 Commercial Development

2007-02-06 Thread Keryx Web
Robert Cummings skrev: I sincerely question the competence of someone who advocates a one size fits all approach to programming. There are many reasons why a developer may work with the old-school interface calls. For instance they may be supporting an old school application. They might be

Re: [PHP] All-in-one PHP Classes

2007-02-06 Thread Chris
Roman Neuhauser wrote: # [EMAIL PROTECTED] / 2007-02-06 12:47:47 +0100: Have been reading posts daily for two months now on the list, and am very pleased at how informative these can be. I have noticed, many examples where one is pointed to using classes downloadable on the internet. This

Re: [PHP] PHP5 Commercial Development

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 23:45 +0100, Keryx Web wrote: The question PHP 4 or PHP 5: If you stay with 4 you are bound to a one size fits all solution. In PHP 5 you can use DB-specific drivers or PDO or a PHP-based abstraction layer. That's *more* choice, not less! To summarize: With PDO or

Re: [PHP] _GET('name') truncates

2007-02-06 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2007-02-05 18:09:21 -0600: GET args can be truncated at some number, if the server does not want to allow longer args. I believe the minimum compliant limit is 1024 bytes. Since you asked for a reference in the other post: HTTP/1.1 tries to be as general as possible, and

Re: [PHP] All-in-one PHP Classes

2007-02-06 Thread Robert Cummings
On Wed, 2007-02-07 at 09:59 +1100, Chris wrote: Roman Neuhauser wrote: # [EMAIL PROTECTED] / 2007-02-06 12:47:47 +0100: Have been reading posts daily for two months now on the list, and am very pleased at how informative these can be. I have noticed, many examples where one is pointed to

[PHP] Apache asks to save php file?

2007-02-06 Thread Skip Evans
Hey all, Just did a new install on FreeBSD 6.0 of Apache 2, PHP4 and MySQL, but the browser asks to save a PHP file rather than execute it. I do have the following in httpd.conf, however. LoadModule php4_module libexec/apache2/libphp4.so DirectoryIndex index.php index.html index.htm

Re: [PHP] Apache asks to save php file?

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 16:15 -0700, Skip Evans wrote: Hey all, Just did a new install on FreeBSD 6.0 of Apache 2, PHP4 and MySQL, but the browser asks to save a PHP file rather than execute it. I do have the following in httpd.conf, however. LoadModule php4_module

Re: [PHP] Apache asks to save php file?

2007-02-06 Thread Skip Evans
Nothing in the log file. Did restart the web server, and yes, I'm compiling this myself. The log file is actually not being touched. I think it failed to compile the apache module on the last attempt (it stopped before because I was not subscribed to a paypal module I tried to include), so

Re: [PHP] Apache asks to save php file?

2007-02-06 Thread Chris
Skip Evans wrote: Hey all, Just did a new install on FreeBSD 6.0 of Apache 2, PHP4 and MySQL, but the browser asks to save a PHP file rather than execute it. I do have the following in httpd.conf, however. LoadModule php4_module libexec/apache2/libphp4.so Is that the right path to the

Re: [PHP] Apache asks to save php file?

2007-02-06 Thread Greg Maruszeczka
On Tue, 06 Feb 2007 16:42:03 -0700 Skip Evans [EMAIL PROTECTED] wrote: Nothing in the log file. Did restart the web server, and yes, I'm compiling this myself. The log file is actually not being touched. I think it failed to compile the apache module on the last attempt (it stopped

Re: [PHP] Apache asks to save php file?

2007-02-06 Thread Robert Cummings
On Tue, 2007-02-06 at 15:59 -0800, Greg Maruszeczka wrote: On Tue, 06 Feb 2007 16:42:03 -0700 Skip Evans [EMAIL PROTECTED] wrote: Nothing in the log file. Did restart the web server, and yes, I'm compiling this myself. The log file is actually not being touched. I think it failed

Re: [PHP] Apache asks to save php file?

2007-02-06 Thread Skip Evans
Yes, the file name and path are correct. Apache will give an error upon restart if they are not. Chris wrote: Skip Evans wrote: Hey all, Just did a new install on FreeBSD 6.0 of Apache 2, PHP4 and MySQL, but the browser asks to save a PHP file rather than execute it. I do have the

RE: [PHP] PHP5 Commercial Development

2007-02-06 Thread Ligaya A. Turmelle
Law of mass tonnage - better to be in the big motorized vehicle then the little one when *crunch* happens. Respectfully, Ligaya Turmelle Systems Analyst Guamcell Communications Phone: (671)689-2377 -Original Message- From: Stut [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 06, 2007

Re: [PHP] Apache asks to save php file?

2007-02-06 Thread Skip Evans
Even do the deinstall I get this: === Checking if misc/php4-calendar already installed === php4-calendar-4.4.4_1 is already installed You may wish to ``make deinstall'' and install this port again by ``make reinstall'' to upgrade it properly. If you really wish to

[PHP] preg_match

2007-02-06 Thread James Lockie
I am trying to use this code to display a button at the root but it always displays the button. :-( if (! (preg_match( /$\/index.php/, $_SERVER['PHP_SELF'] ))) { # display a button -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] preg_match

2007-02-06 Thread Richard Lynch
On Tue, February 6, 2007 7:46 pm, James Lockie wrote: I am trying to use this code to display a button at the root but it always displays the button. :-( if (! (preg_match( /$\/index.php/, $_SERVER['PHP_SELF'] ))) { Without any modifier, $ matches the END of the string. It is impossible

Re: [PHP] preg_match

2007-02-06 Thread Myron Turner
James Lockie wrote: I am trying to use this code to display a button at the root but it always displays the button. :-( if (! (preg_match( /$\/index.php/, $_SERVER['PHP_SELF'] ))) { # display a button You got the end-of-string character ($) in the wrong place: if (! (preg_match(

Re: [PHP] preg_match

2007-02-06 Thread James Lockie
Myron Turner wrote: James Lockie wrote: I am trying to use this code to display a button at the root but it always displays the button. :-( if (! (preg_match( /$\/index.php/, $_SERVER['PHP_SELF'] ))) { # display a button You got the end-of-string character ($) in the wrong place: if

Re: [PHP] _GET('name') truncates

2007-02-06 Thread Richard Lynch
On Tue, February 6, 2007 4:01 pm, Roman Neuhauser wrote: # [EMAIL PROTECTED] / 2007-02-05 18:09:21 -0600: GET args can be truncated at some number, if the server does not want to allow longer args. I believe the minimum compliant limit is 1024 bytes. I may well have been remembering

Re: [PHP] All-in-one PHP Classes

2007-02-06 Thread Richard Lynch
On Tue, February 6, 2007 5:47 am, Tim wrote: Shouldn't these classes be perhaps broken down into usefull parts. Many of them started life as very small classes, and then the Feature Requests started pouring in and... Do feel free to take a class and delete all the bits you're not using, if you

Re: [PHP] Graphs

2007-02-06 Thread Richard Lynch
On Tue, February 6, 2007 5:42 am, Kristian Erendi wrote: I wish to draw graphs on a web page. Can someone tell me which extension or package I should use? Any examples? The answer is the same as it was yesterday. GD JPGraph Okay, somebody posted a third one I forgot already. Did you even

Re: [PHP] Re: file_get_contents

2007-02-06 Thread Richard Lynch
On Tue, February 6, 2007 7:53 am, Colin Guthrie wrote: Steven Macintyre wrote: Hiya, I need to be able to read a file into a string - I have used the above command and it works ... now ... I need to read a file into a string - that requires a username and password to access the

Re: [PHP] PHP book reviewers wanted

2007-02-06 Thread Richard Lynch
On Tue, February 6, 2007 12:04 am, Manuel Lemos wrote: Hello, on 02/06/2007 12:39 AM Richard Lynch said the following: Demonstrating good English writing skills and having published good book reviews in the past gets me preference. gets me preference ??? Me get any money for this? Hey,

[PHP] Opera advice needed!

2007-02-06 Thread William Stokes
Hello, I just noticed when I published a new menu system that it does NOT work in the ISP hosted server. However it works ok on my test server. Here's the test I have done all in same client machine (=unchanged browser settings): My test server: IE6 7-OK Opera 9.02 - OK Firefox -OK ISP

[PHP] PHP4 extensions not loading

2007-02-06 Thread Skip Evans
Hey all, I installed a new server with PHP5, but then had to revert to PHP4 (attempted anyway) on a FreeBSD 6.0 install. I have PHP4 compiled, both the main BSD port of lang/php4 and all of the extensions individually. However, the extensions, including basic ones like MySQL are not

Re: [PHP] PHP4 extensions not loading

2007-02-06 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2007-02-07 00:00:57 -0700: What I need to do is get Apache looking at a /var/db/ports/php4-extensions directory, which I did create with the options file listing all the extensions I built individually. Can someone tell me how this can be done? How I can tell

Re: [PHP] Opera advice needed!

2007-02-06 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2007-02-07 08:32:47 +0200: Hello, I just noticed when I published a new menu system that it does NOT work in the ISP hosted server. However it works ok on my test server. Here's the test I have done all in same client machine (=unchanged browser settings): My test

[PHP] base64-encoding in cookies?

2007-02-06 Thread Fletcher Mattox
Hi, A campus web server (not under my control) returns an authentication string in a cookie named AUTH. The cookie's value is an encrypted, base64 encoded string. Unfortunately, when I examine $_COOKIE['AUTH'], it is clear that all of the '+' characters have been replaced with a ' ' character