php-general Digest 12 Mar 2008 08:28:07 -0000 Issue 5343

2008-03-12 Thread php-general-digest-help
php-general Digest 12 Mar 2008 08:28:07 - Issue 5343 Topics (messages 271313 through 271332): Re: link with database 271313 by: Shawn McKenzie 271314 by: Shawn McKenzie Know a JS list serve 271315 by: Skip Evans 271318 by: Greg Donald Re: Whats faster?

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Thijs Lensselink
Quoting Shelley [EMAIL PROTECTED]: Hi all, I'm searching some file upload progress bar code. But no good result was found. :( So is there anybody please be kind enough to show some code here? Great thanks. -- Regard, Shelley (http://phparch.cn) -- PHP General Mailing List

RE: [PHP] PHP Ajax progress bar

2008-03-12 Thread Mr Webber
I haven't' tried this yet ... so I would appreciate your feedback. -Original Message- From: Thijs Lensselink [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 4:28 AM To: php-general@lists.php.net Subject: Re: [PHP] PHP Ajax progress bar Quoting Shelley [EMAIL PROTECTED]: Hi

RE: [PHP] PHP Ajax progress bar

2008-03-12 Thread Thijs Lensselink
Quoting Mr Webber [EMAIL PROTECTED]: I haven't' tried this yet ... so I would appreciate your feedback. -Original Message- From: Thijs Lensselink [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 4:28 AM To: php-general@lists.php.net Subject: Re: [PHP] PHP Ajax progress bar

[PHP] Parameter

2008-03-12 Thread John Comerford
Hi Folks, I am thinking of putting together a class to handle passing parameters to a class. Basically when you define a class you would define your class to extend the parameter class. The parameter class would be JSON compliant so in the end when you call a class it you could pass the

Re: [PHP] Know a JS list serve

2008-03-12 Thread Frank Arensmeier
11 mar 2008 kl. 22.39 skrev Skip Evans: Hey all, I've been Googling trying to find a JavaScript list serve to post a question to, but have been, embarrassingly, unable to find one. Anyone on one they'd recommend or know of one? Thanks *sigh* Evolt has a rather good list (not too much

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Shelley
Thijs Lensselink 写道: Quoting Mr Webber [EMAIL PROTECTED]: I haven't' tried this yet ... so I would appreciate your feedback. -Original Message- From: Thijs Lensselink [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 4:28 AM To: php-general@lists.php.net Subject: Re: [PHP] PHP

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Thijs Lensselink
Quoting Shelley [EMAIL PROTECTED]: Thijs Lensselink 写道: Quoting Mr Webber [EMAIL PROTECTED]: I haven't' tried this yet ... so I would appreciate your feedback. -Original Message- From: Thijs Lensselink [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 4:28 AM To:

Re: [PHP] Comparing files

2008-03-12 Thread Thijs Lensselink
Quoting mathieu leddet [EMAIL PROTECTED]: Hi all, I have a simple question : how can I ensure that 2 files are identical ? How about this ? 8-- function files_identical($path1, $path2) { return (file_get_contents($path1) ==

Re: [PHP] Comparing files

2008-03-12 Thread Stut
mathieu leddet wrote: I have a simple question : how can I ensure that 2 files are identical ? How about this ? 8-- function files_identical($path1, $path2) { return (file_get_contents($path1) ==

Re: [PHP] Comparing files

2008-03-12 Thread Aschwin Wesselius
mathieu leddet wrote: Hi all, I have a simple question : how can I ensure that 2 files are identical ? How about this ? 8-- function files_identical($path1, $path2) { return (file_get_contents($path1) ==

RE: [PHP] Comparing files

2008-03-12 Thread Edward Kay
-Original Message- From: mathieu leddet [mailto:[EMAIL PROTECTED] Sent: 12 March 2008 11:04 To: php-general@lists.php.net Subject: [PHP] Comparing files Hi all, I have a simple question : how can I ensure that 2 files are identical ? How about this ?

[PHP] Comparing files

2008-03-12 Thread mathieu leddet
Hi all, I have a simple question : how can I ensure that 2 files are identical ? How about this ? 8-- function files_identical($path1, $path2) { return (file_get_contents($path1) == file_get_contents($path2)); }

RE: [PHP] Comparing files

2008-03-12 Thread mathieu leddet
Yes! Thanks a lot, md5_file suits perfectly well my needs. I've read that 'exec'ing the md5 command is faster... I'll see when performance on large files will become an issue. Thanks again, -- Mathieu -Message d'origine- De : Thijs Lensselink [mailto:[EMAIL PROTECTED] Envoyé :

RE: [PHP] Comparing files

2008-03-12 Thread Per Jessen
mathieu leddet wrote: Yes! Thanks a lot, md5_file suits perfectly well my needs. I've read that 'exec'ing the md5 command is faster... I'll see when performance on large files will become an issue. Doing a diff on the files would make absolutely certain - an md5 checksum is not. /Per

RE: [PHP] Comparing files

2008-03-12 Thread Andrés Robinet
-Original Message- From: Edward Kay [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 7:13 AM To: mathieu leddet; php-general@lists.php.net Subject: RE: [PHP] Comparing files -Original Message- From: mathieu leddet [mailto:[EMAIL PROTECTED] Sent: 12 March

[PHP] setcookie

2008-03-12 Thread Tim Daff
Hi, I am learning PHP, I am trying to set a simple cookie: html head titleCookies/title /head body ?php setcookie('test', 45, time()+(60*60*24*7)); ? /body /html Firefox is returning this error:

Re: [PHP] setcookie

2008-03-12 Thread Jean-Christophe Roux
body ?php setcookie('test', 45, time()+(60*60*24*7)); ? from the doc: Cookies are part of the HTTP header, so setcookie() must be called before any output is sent to the browser. This is the same limitation that header() has. http://ca.php.net/cookies -

Re: [PHP] setcookie

2008-03-12 Thread Hiep Nguyen
On Wed, 12 Mar 2008, Tim Daff wrote: Hi, I am learning PHP, I am trying to set a simple cookie: html head titleCookies/title /head body ?php setcookie('test', 45, time()+(60*60*24*7)); ? /body /html Firefox is returning

[PHP] setcookie

2008-03-12 Thread Tim Daff
Thank's for your help Zareef, Hiep, Shiplu and Jean-Christophe -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Know a JS list serve

2008-03-12 Thread Jason Pruim
On Mar 12, 2008, at 4:14 AM, Frank Arensmeier wrote: 11 mar 2008 kl. 22.39 skrev Skip Evans: Hey all, I've been Googling trying to find a JavaScript list serve to post a question to, but have been, embarrassingly, unable to find one. Anyone on one they'd recommend or know of one?

RE: [PHP] Comparing files

2008-03-12 Thread Edward Kay
-Original Message- From: Andrés Robinet [mailto:[EMAIL PROTECTED] Sent: 12 March 2008 12:33 To: 'Edward Kay'; 'mathieu leddet'; php-general@lists.php.net Subject: RE: [PHP] Comparing files -Original Message- From: Edward Kay [mailto:[EMAIL PROTECTED] Sent: Wednesday,

Re: [PHP] setcookie

2008-03-12 Thread Richard Heyes
Firefox is returning this error: Warning: Cannot modify header information - headers already sent by (output started at /Users/Daff/Sites/php_sandbox/cookies.php:7) in /Users/Daff/Sites/php_sandbox/cookies.php on line 7 You must use set cookie() before you send any output to the browser,

Re: [PHP] setcookie

2008-03-12 Thread Wolf
Tim Daff wrote: Hi, I am learning PHP, I am trying to set a simple cookie: html head titleCookies/title /head body ?php setcookie('test', 45, time()+(60*60*24*7)); ? /body /html Firefox is returning this error: Warning: Cannot modify header

RE: [PHP] Comparing files

2008-03-12 Thread Thijs Lensselink
Quoting Andrés Robinet [EMAIL PROTECTED]: -Original Message- From: Edward Kay [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 7:13 AM To: mathieu leddet; php-general@lists.php.net Subject: RE: [PHP] Comparing files -Original Message- From: mathieu leddet

Re: [PHP] setcookie

2008-03-12 Thread Shiplu
Even you cant put a space before ?php tag. the following code will throw the same error. | ?php | setcookie(); | ? Because I prepend a space for each line But this will be okay |?php | setcookie(); | ? This is a very common mistake and very very hard to find. On Wed, Mar 12, 2008 at 7:53 AM,

Re: [PHP] setcookie

2008-03-12 Thread Ray Hauge
Wolf wrote: Tim Daff wrote: Hi, I am learning PHP, I am trying to set a simple cookie: html head titleCookies/title /head body ?php setcookie('test', 45, time()+(60*60*24*7)); ? /body /html Firefox is returning this error: Warning: Cannot

Re: [PHP] setcookie

2008-03-12 Thread Zareef Ahmed
As a dirty trick you can put following line on the top of your script, it will work ob_start(); But you should try to know why it is not working, and what exactly ob_start will impact your application and What is the thing called Output Buffering. Zareef Ahmed On 3/12/08, Hiep Nguyen [EMAIL

[PHP] What's wrong the __autoload()?

2008-03-12 Thread Gustavo Narea
Hello all, I'm wondering what's wrong with the use of __autoload(), since I see that projects like the Zend Framework don't use it and prefer to require_once each required file. Thanks in advance. -- Gustavo Narea. http://gustavonarea.net/ Get GNU/Linux! http://www.getgnulinux.org/ -- PHP

[PHP] best practices in error handling in PHP

2008-03-12 Thread It Maq
Hi, I want to know what is the best solution for handling errors. After reading some documents dealing with the subject, i have three options: * Using a class for error handling * Using PEAR error object * Using try and catch exceptions The error handling i want to implement will be done in a

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Richard Heyes
I'm wondering what's wrong with the use of __autoload(), since I see that projects like the Zend Framework don't use it and prefer to require_once each required file. Things that happen without you explicitly causing them (ie require() et al) can lead to confusion. For example a junior

[PHP] mail function and headers

2008-03-12 Thread Alain Roger
Hi, i'm playing a little bit with the mail function from PHP 5.2.4 and email headers. here is a snippet of my code: $headers = 'From: '.$email. .$fromname. \r\n.'Reply-To:'.$email.\r\n.'X-Mailer: PHP/' . phpversion(); if (mail($to, $subject, $body,$headers)) { ... } where: $fromname =

Re: [PHP] best practices in error handling in PHP

2008-03-12 Thread Richard Heyes
It Maq wrote: I want to know what is the best solution for handling errors. After reading some documents dealing with the subject, i have three options: * Using a class for error handling No point IMO when you could use either the below two. * Using PEAR error object I wouldn't advise

Re: [PHP] best practices in error handling in PHP

2008-03-12 Thread Christoph Boget
I want to know what is the best solution for handling errors. After reading some documents dealing with the subject, i have three options: * Using a class for error handling * Using PEAR error object * Using try and catch exceptions The error handling i want to implement will be done

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Philip Thompson
On Mar 12, 2008, at 5:02 AM, Thijs Lensselink wrote: Thijs Lensselink 写道: How do you pronounce your name? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] best practices in error handling in PHP

2008-03-12 Thread It Maq
Yes you are right i can use trigger_error that will use the function that handles errors from my class. Thanks - Original Message From: Christoph Boget [EMAIL PROTECTED] To: It Maq [EMAIL PROTECTED] Cc: php-general@lists.php.net Sent: Wednesday, March 12, 2008 10:31:07 AM Subject: Re:

Re: [PHP] best practices in error handling in PHP

2008-03-12 Thread Zoltán Németh
2008. 03. 12, szerda keltezéssel 07.18-kor It Maq ezt írta: Hi, I want to know what is the best solution for handling errors. After reading some documents dealing with the subject, i have three options: * Using a class for error handling * Using PEAR error object * Using try and catch

Re: [PHP] best practices in error handling in PHP

2008-03-12 Thread It Maq
I mean using calling trigger_error from the catch{} Yes you are right i can use trigger_error that will use the function that handles errors from my class. Thanks - Original Message From: Christoph Boget [EMAIL PROTECTED] To: It Maq [EMAIL PROTECTED] Cc:

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Thijs Lensselink
Quoting Philip Thompson [EMAIL PROTECTED]: On Mar 12, 2008, at 5:02 AM, Thijs Lensselink wrote: Thijs Lensselink 写道: How do you pronounce your name? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Well.. how to explain this one...

[PHP] Re: A Quick Reminder....

2008-03-12 Thread Daniel Brown
Because then it screws up message formatting. On Wed, Mar 12, 2008 at 10:54 AM, Daniel Brown [EMAIL PROTECTED] wrote: Please don't top-post! ;-P -- /Dan Daniel P. Brown Senior Unix Geek ? while(1) { $me = $mind--; sleep(86400); } ? -- /Dan Daniel P. Brown Senior Unix

[PHP] Re: A Quick Reminder....

2008-03-12 Thread Daniel Brown
Especially in the archives. On Wed, Mar 12, 2008 at 10:55 AM, Daniel Brown [EMAIL PROTECTED] wrote: Because then it screws up message formatting. On Wed, Mar 12, 2008 at 10:54 AM, Daniel Brown [EMAIL PROTECTED] wrote: Please don't top-post! ;-P -- /Dan

[PHP] A Quick Reminder....

2008-03-12 Thread Daniel Brown
Please don't top-post! ;-P -- /Dan Daniel P. Brown Senior Unix Geek ? while(1) { $me = $mind--; sleep(86400); } ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] mail function and headers

2008-03-12 Thread Daniel Brown
On Wed, Mar 12, 2008 at 10:28 AM, Alain Roger [EMAIL PROTECTED] wrote: Hi, i'm playing a little bit with the mail function from PHP 5.2.4 and email headers. here is a snippet of my code: $headers = 'From: '.$email. .$fromname. \r\n.'Reply-To:'.$email.\r\n.'X-Mailer: PHP/' .

Re: [PHP] Timezone management

2008-03-12 Thread Jim Lucas
Lamonte H wrote: After a while of studying different softwares, I've still been getting confused on how to make a timezone management script to display time in different time zones. Like right now im in -0600 CST GMT, how would I create a script that would work on any server that would allow

Re: [PHP] Timezone management

2008-03-12 Thread Daniel Brown
On Wed, Mar 12, 2008 at 10:50 AM, Jim Lucas [EMAIL PROTECTED] wrote: Lamonte H wrote: After a while of studying different softwares, I've still been getting confused on how to make a timezone management script to display time in different time zones. Like right now im in -0600 CST

Re: [PHP] A Quick Reminder....

2008-03-12 Thread TG
I call TROLL on Dan! :) I top post for what I consider to be legitmate reasons just like you bottom post for reasons you consider to be legitmate. Can't we all just get along? How about something OT that we can argue about... driving on the left side of the road versus the right side.

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Philip Thompson
On Mar 12, 2008, at 9:52 AM, Thijs Lensselink wrote: Quoting Philip Thompson [EMAIL PROTECTED]: On Mar 12, 2008, at 5:02 AM, Thijs Lensselink wrote: Thijs Lensselink 写道: How do you pronounce your name? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] A Quick Reminder....

2008-03-12 Thread Daniel Brown
On Wed, Mar 12, 2008 at 11:01 AM, TG [EMAIL PROTECTED] wrote: How about something OT that we can argue about... driving on the left side of the road versus the right side. How does your country compare? Here in Pennsyltucky, a lot of people drive on the left, despite the fact that the

Re: [PHP] mail function and headers

2008-03-12 Thread spacemarc
2008/3/12, Daniel Brown [EMAIL PROTECTED]: You have the From: header parameters reversed. Try this: ? $headers = From: .$fromname. .$email.\r\n; $headers .= Reply-To: .$email.\r\n; $headers .= X-Mailer: PHP/.phpversion().\r\n; /* */ ? you can add these headers:

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Daniel Brown
On Wed, Mar 12, 2008 at 11:03 AM, Philip Thompson [EMAIL PROTECTED] wrote: On Mar 12, 2008, at 9:52 AM, Thijs Lensselink wrote: Quoting Philip Thompson [EMAIL PROTECTED]: How do you pronounce your name? Well.. how to explain this one... thijs : T + [ice] Which is

Re: [PHP] A Quick Reminder....

2008-03-12 Thread Aschwin Wesselius
Daniel Brown wrote: On Wed, Mar 12, 2008 at 11:01 AM, TG [EMAIL PROTECTED] wrote: How about something OT that we can argue about... driving on the left side of the road versus the right side. How does your country compare? Here in Pennsyltucky, a lot of people drive on the

Re: [PHP] A Quick Reminder....

2008-03-12 Thread Jason Pruim
On Mar 12, 2008, at 11:06 AM, Daniel Brown wrote: On Wed, Mar 12, 2008 at 11:01 AM, TG [EMAIL PROTECTED] wrote: How about something OT that we can argue about... driving on the left side of the road versus the right side. How does your country compare? Here in Pennsyltucky, a lot

Re: [PHP] PHP Ajax progress bar

2008-03-12 Thread Thijs Lensselink
Quoting Daniel Brown [EMAIL PROTECTED]: On Wed, Mar 12, 2008 at 11:03 AM, Philip Thompson [EMAIL PROTECTED] wrote: On Mar 12, 2008, at 9:52 AM, Thijs Lensselink wrote: Quoting Philip Thompson [EMAIL PROTECTED]: How do you pronounce your name? Well.. how to explain this one...

[PHP] Re: A Quick Reminder....

2008-03-12 Thread Daniel Brown
On Wed, Mar 12, 2008 at 10:55 AM, Daniel Brown [EMAIL PROTECTED] wrote: Especially in the archives. Or worse yet, when someone else bottom-posts correctly and doesn't clip the remaining conversation. On Wed, Mar 12, 2008 at 10:55 AM, Daniel Brown [EMAIL PROTECTED] wrote:

Re: [PHP] A Quick Reminder....

2008-03-12 Thread Wolf
Jason Pruim [EMAIL PROTECTED] wrote: On Mar 12, 2008, at 11:06 AM, Daniel Brown wrote: On Wed, Mar 12, 2008 at 11:01 AM, TG [EMAIL PROTECTED] wrote: How about something OT that we can argue about... driving on the left side of the road versus the right side. How does

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: I'm wondering what's wrong with the use of __autoload(), since I see that projects like the Zend Framework don't use it and prefer to require_once each required file. Things that happen without you explicitly causing them (ie require()

Re: [PHP] mail function and headers

2008-03-12 Thread Alain Roger
ok i will try... what about UTF-8 to ensure unicode ? my website and especially the form which will send this email, will be filled in by several nationalities... spanish, english, french, slovak, german,,... so isn't it easier to set up utf-8 ? A. On Wed, Mar 12, 2008 at 4:11 PM, spacemarc

Fwd: [PHP] mail function and headers

2008-03-12 Thread Alain Roger
ok i will try... what about UTF-8 to ensure unicode ? my website and especially the form which will send this email, will be filled in by several nationalities... spanish, english, french, slovak, german,,... so isn't it easier to set up utf-8 ? A. On Wed, Mar 12, 2008 at 4:11 PM, spacemarc

Re: [PHP] strtotime( 'last Sunday' ) and republicans

2008-03-12 Thread Greg Donald
On 3/10/08, Wolf [EMAIL PROTECTED] wrote: Watch throwing that blame around there Greg, you get to thank the democrats for NAFTA and the hurting the heartlands No matter where we draw the borders or put the roads and highways, it's still just the one planet, with the same finite resources we

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Robert Cummings
On Wed, 2008-03-12 at 10:33 -0500, Greg Donald wrote: On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: I'm wondering what's wrong with the use of __autoload(), since I see that projects like the Zend Framework don't use it and prefer to require_once each required file. Things

Re: [PHP] mail function and headers

2008-03-12 Thread Alain Roger
ok, so this is what i got and it is still remaining... :-( Received: from serdev ([127.0.0.1]) by home.com with MailEnable ESMTP; Wed, 12 Mar 2008 16:40:18 +0100 Date: Wed, 12 Mar 2008 16:40:18 +0100 Subject: subject 3 To: [EMAIL PROTECTED] From: raf, news [EMAIL PROTECTED] Reply-To: [EMAIL

Re: [PHP] A Quick Reminder....

2008-03-12 Thread Per Jessen
Daniel Brown wrote: Here in Pennsyltucky, a lot of people drive on the left, despite the fact that the whole US is supposed to drive on the right. It usually doesn't turn out very good. .:shakes head, solemnly:. Don't worry Dan, evolution will sort that out eventually. /Per Jessen,

RE: [PHP] A Quick Reminder....

2008-03-12 Thread Andrés Robinet
I don't know... but... -Original Message- From: Wolf [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 11:30 AM To: Jason Pruim Cc: TG; Daniel Brown; PHP General List Subject: Re: [PHP] A Quick Reminder Jason Pruim [EMAIL PROTECTED] wrote: On Mar 12, 2008,

Re: [PHP] A Quick Reminder....

2008-03-12 Thread TG
RFC1855/FYI28: ftp://ftp.rfc-editor.org/in-notes/rfc1855.txt ftp://ftp.rfc-editor.org/in-notes/fyi/fyi28.txt Found via the RFC-Editor archive search: http://www.rfc-editor.org/ Ok, so this RFC discourages top posting, but it was also written 13 years ago when Usenet and other threaded/flat

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Robert Cummings [EMAIL PROTECTED] wrote: But then you'd end up with something like Ruby on Rails... and we all know about Ruby on Rails *VOMIT*. You clearly don't know much about it or else you wouldn't be bashing it. Period. Just admit the fact that you're resistant to learn

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Richard Heyes
For example a junior developer who doesn't know of its existence and is new to a job is less likely to admit ignorance and ask how a class is being defined when __autoload() is being used. That's a the dumbest reason I've ever heard to not use a given language feature. It's a perfectly

RE: [PHP] A Quick Reminder....

2008-03-12 Thread TG
- Original Message - From: Andrés Robinet [EMAIL PROTECTED] To: 'Wolf' [EMAIL PROTECTED], 'Jason Pruim' [EMAIL PROTECTED] Cc: 'TG' [EMAIL PROTECTED], 'Daniel Brown' [EMAIL PROTECTED], 'PHP General List' php-general@lists.php.net Date: Wed, 12 Mar 2008 11:58:26 -0400 How

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: It's a perfectly viable business reason. No it's not. I guess you need a business scenario to wrap your head around the idiocy. Here you go: Imagine at Blizzard one morning, Hey guys, we're not going to be able to use function pointers on the

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Eric Butera
On Wed, Mar 12, 2008 at 10:05 AM, Gustavo Narea [EMAIL PROTECTED] wrote: Hello all, I'm wondering what's wrong with the use of __autoload(), since I see that projects like the Zend Framework don't use it and prefer to require_once each required file. Thanks in advance. -- Gustavo

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Richard Heyes
It's a perfectly viable business reason. No it's not. I guess you need a business scenario to wrap your head around the idiocy. Here you go: Imagine at Blizzard one morning, Hey guys, we're not going to be able to use function pointers on the new Diablo III like we had planned to do, the new

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Zoltán Németh
2008. 03. 12, szerda keltezéssel 11.12-kor Greg Donald ezt írta: On 3/12/08, Robert Cummings [EMAIL PROTECTED] wrote: But then you'd end up with something like Ruby on Rails... and we all know about Ruby on Rails *VOMIT*. You clearly don't know much about it or else you wouldn't be

Re: [PHP] A Quick Reminder....

2008-03-12 Thread Ray Hauge
Jason Pruim wrote: On Mar 12, 2008, at 11:06 AM, Daniel Brown wrote: On Wed, Mar 12, 2008 at 11:01 AM, TG [EMAIL PROTECTED] wrote: How about something OT that we can argue about... driving on the left side of the road versus the right side. How does your country compare? Here in

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: That's not quite the situation. Finding good developers isn't easy, so lots of companies will go for acceptable ones, who are less likely to know of __autoloads existence. Hence, using __autoload is unwise. A lesser developer should be paid

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Zoltán Németh [EMAIL PROTECTED] wrote: but I strongly think that Ruby as a language just plain sucks ;) And exactly how many projects do you have under your belt to allow you to develop this opinion? What's the url to any one of them? Unlike you I actually have thousands of lines

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: No it's not. It's not like require_once() is a hassle to type/use anyhow. Things like editor macros and templates help out enormously and by using them over __auto load you (a business) could save yourself a lot of time and hence money.

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Robert Cummings [EMAIL PROTECTED] wrote: Imagine at Blizzard one morning, Hey guys, we're not going to be able to use function pointers on the new Diablo III like we had planned to do, the new hires down the hall don't understand them very well so just don't use them, OK?

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Zoltán Németh
2008. 03. 12, szerda keltezéssel 12.12-kor Greg Donald ezt írta: On 3/12/08, Zoltán Németh [EMAIL PROTECTED] wrote: but I strongly think that Ruby as a language just plain sucks ;) And exactly how many projects do you have under your belt to allow you to develop this opinion? What's the

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Robert Cummings
On Wed, 2008-03-12 at 11:12 -0500, Greg Donald wrote: On 3/12/08, Robert Cummings [EMAIL PROTECTED] wrote: But then you'd end up with something like Ruby on Rails... and we all know about Ruby on Rails *VOMIT*. You clearly don't know much about it or else you wouldn't be bashing it.

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Richard Heyes
Greg Donald wrote: On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: That's not quite the situation. Finding good developers isn't easy, so lots of companies will go for acceptable ones, who are less likely to know of __autoloads existence. Hence, using __autoload is unwise. A lesser

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Wolf
Richard Heyes [EMAIL PROTECTED] wrote: Greg Donald wrote: On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: That's not quite the situation. Finding good developers isn't easy, so lots of companies will go for acceptable ones, who are less likely to know of __autoloads existence.

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Robert Cummings
On Wed, 2008-03-12 at 11:26 -0500, Greg Donald wrote: On 3/12/08, Richard Heyes [EMAIL PROTECTED] wrote: It's a perfectly viable business reason. No it's not. I guess you need a business scenario to wrap your head around the idiocy. Here you go: Imagine at Blizzard one morning, Hey

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Robert Cummings
On Wed, 2008-03-12 at 18:21 +0100, Zoltán Németh wrote: 2008. 03. 12, szerda keltezéssel 12.12-kor Greg Donald ezt írta: On 3/12/08, Zoltán Németh [EMAIL PROTECTED] wrote: but I strongly think that Ruby as a language just plain sucks ;) And exactly how many projects do you have

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Stut
On 12 Mar 2008, at 17:31, Wolf wrote: Richard Heyes [EMAIL PROTECTED] wrote: Greg Donald wrote: You're gonna restrict the entire development team from using a given feature just because you don't want to invest 20 minutes in getting your newbie developer up to spead? That's pure

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Zoltán Németh [EMAIL PROTECTED] wrote: ok, I admit I don't have experience with Ruby but I have experience with php. and I don't have experience with Ruby because I read some manuals and example codes and whatnot and I just could not get to like it at all. That's a lot

Re: [PHP] Storing values between multiple page forms

2008-03-12 Thread Jim Lucas
Matty Sarro wrote: Yeah, I'm working on this with the hopes of it turning into a full module for a larger project I'm working on... but I'm still a bit of a noob :) Thanks for the assistance guys! On Tue, Mar 11, 2008 at 11:48 AM, Daniel Brown [EMAIL PROTECTED] wrote: On Tue, Mar 11, 2008 at

Re: [PHP] Storing values between multiple page forms

2008-03-12 Thread Daniel Brown
On Wed, Mar 12, 2008 at 2:37 PM, Jim Lucas [EMAIL PROTECTED] wrote: If you are going to follow Daniel's example, since you could potentially be working with more then one server on any given order, you might want to look at using a multi-dimensional array to store your values in. An

[PHP] PHP CLI neat errors!

2008-03-12 Thread Steve Finkelstein
So, I use a Mac to develop with. I used to host Zend Core on my box, until I switched to the MAMP PRO framework. Unfortunately somewhere in between, this lovely issue started occuring with my CLI binary of PHP: foo:~ sf$ php -l dyld: NSLinkModule() error dyld: Symbol not found: _zend_extensions

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Zoltán Németh
2008. 03. 12, szerda keltezéssel 13.27-kor Greg Donald ezt írta: On 3/12/08, Zoltán Németh [EMAIL PROTECTED] wrote: ok, I admit I don't have experience with Ruby but I have experience with php. and I don't have experience with Ruby because I read some manuals and example codes and whatnot

RE: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Andrés Robinet
-Original Message- From: Robert Cummings [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 1:51 PM To: Zoltán Németh Cc: Greg Donald; php-general@lists.php.net Subject: Re: [PHP] What's wrong the __autoload()? On Wed, 2008-03-12 at 18:21 +0100, Zoltán Németh wrote:

RE: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Stephane Ulysse
Anyone know any PHP Developers who are looking for employment -Original Message- From: Andrés Robinet [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 2:53 PM To: 'Robert Cummings'; 'Zoltán Németh' Cc: 'Greg Donald'; php-general@lists.php.net Subject: RE: [PHP] What's wrong the

RE: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Zoltán Németh
2008. 03. 12, szerda keltezéssel 15.07-kor Stephane Ulysse ezt írta: Anyone know any PHP Developers who are looking for employment don't hijack other people's threads, start your own if you want to ask anything. and job offers should contain some information about the job and the employer, and

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Nathan Nobbe
On Wed, Mar 12, 2008 at 2:53 PM, Andrés Robinet [EMAIL PROTECTED] wrote: I think __autoload would make much more sense if it worked like an event registration feature. Such as: function myAutoloadCallback($className) { if ($className == 'ShakeItBaby') { require_once

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Zoltán Németh [EMAIL PROTECTED] wrote: I can't really think of a case where I would want to modify the class definition of an instantiated object You can't very well think to walk if you don't have legs. -- Greg Donald http://destiney.com/ -- PHP General Mailing List

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Robert Cummings
On Wed, 2008-03-12 at 14:09 -0500, Greg Donald wrote: On 3/12/08, Zoltán Németh [EMAIL PROTECTED] wrote: I can't really think of a case where I would want to modify the class definition of an instantiated object You can't very well think to walk if you don't have legs. You make it

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Zoltán Németh
2008. 03. 12, szerda keltezéssel 15.20-kor Robert Cummings ezt írta: Even JavaScript has it. oh yes, I could have thought of that. in JS you can assign a function to a property or variable at runtime, even I did something similar, when I assign the action functions of the buttons of a modal

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Nathan Nobbe
On Wed, Mar 12, 2008 at 3:35 PM, Zoltán Németh [EMAIL PROTECTED] wrote: 2008. 03. 12, szerda keltezéssel 15.20-kor Robert Cummings ezt írta: Even JavaScript has it. oh yes, I could have thought of that. in JS you can assign a function to a property or variable at runtime, even I did

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Greg Donald
On 3/12/08, Robert Cummings [EMAIL PROTECTED] wrote: You make it sound like this stuff is new or something. Obviously to some it is. Just in this thread we had a person claim to only know PHP, C, and Java, none of which have any functional language capabilities built in. Lisp and other

RE: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Andrés Robinet
-Original Message- From: Nathan Nobbe [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 12, 2008 3:08 PM To: Andrés Robinet Cc: Robert Cummings; Zoltán Németh; Greg Donald; php-general@lists.php.net Subject: Re: [PHP] What's wrong the __autoload()? On Wed, Mar 12, 2008 at 2:53 PM,

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Aschwin Wesselius
Greg Donald wrote: Here, let me dumb-it-down a bit: PHP doesn't have much in the way of meta-programming capabilities. Therefore one would not find it a natural thought to do much meta-programming in PHP, unless one already knew of a language where such support exists. A different example

Re: [PHP] What's wrong the __autoload()?

2008-03-12 Thread Nathan Nobbe
On Wed, Mar 12, 2008 at 3:59 PM, Greg Donald [EMAIL PROTECTED] wrote: Lisp and other functional languages have had it for decades. Even JavaScript has it. I'm sorry, I lost context, what missing PHP language feature are you referring to as it? functional capabilities, in particular the

  1   2   >