[PHP-DEV] php-dev summaries (Re: [PHP-DEV] suggestions for ze2)

2003-01-14 Thread Leon Atkinson
Actually, I think it's a good idea to make a summary of all those discussions What about an always available discussion documentation on php.net ? Avi Lewin writes an excellent weekly column that summarizes discussions on this list. http://www.zend.com/zend/week/index.php Leon -- PHP

Re: [PHP-DEV] when PHP code causes crash due to bad input, is it a bug?

2003-01-10 Thread Leon Atkinson
Thanks for sticking with the issue, Greg. If I may make an objective observation... Random users constantly submit issues to the bug database that are clearly not problems with PHP, issues that are better addressed in the mailing lists. I imagine it must be frustrating to the QA team to have

[PHP-DEV] patch for libgd/gd.c (gdImageRotate90 x,y transposed)

2003-01-09 Thread Leon Atkinson
This function isn't making the new image with the right dimensions. # cvs diff ext/gd/libgd/gd.c Index: ext/gd/libgd/gd.c === RCS file: /repository/php4/ext/gd/libgd/gd.c,v retrieving revision 1.39 diff -u -r1.39 gd.c ---

[PHP-DEV] Is exif_tagname() useful?

2003-01-07 Thread Leon Atkinson
The undocumented function exif_tagname() does lookups on the table tag_table_IFD which matches IDF0 tags to human-readable names. Considering exif_read_data() already uses this table, is there a reason to have this function around? Debugging? --- Leon Atkinson http://www.leonatkinson.com

[PHP-DEV] imageline drawing twice

2003-01-07 Thread Leon Atkinson
It looks like imageline() draws the line twice. RCS file: /repository/php4/ext/gd/gd.c,v retrieving revision 1.241 diff -u -r1.241 gd.c --- ext/gd/gd.c 31 Dec 2002 16:06:39 - 1.241 +++ ext/gd/gd.c 7 Jan 2003 21:54:37 - @@ -2149,8 +2149,7 @@ else #endif

Re: [PHP-DEV] Generic expressions interpolation in strings

2003-01-06 Thread Leon Atkinson
print END table trtdName:/tdtd{$= text2html($data['name']) }/td/tr trtdAddress:/tdtdinput type=text value={$= htmlspecialchars($data['address']) }/td/tr /table END; Federico, you can always do this: ? table trtdName:/tdtd?= text2html($data['name']) ?/td/tr trtdAddress:/tdtdinput type=text

Re: [PHP-DEV] Designing for PHP4 with PHP5 in mind...

2003-01-06 Thread Leon Atkinson
and assignments. For example: ? class a {} function c($c) { $c-name = 'C'; } $a = new a; $b = $a; $a-name = A; print($a-name); $b-name = B; print($a-name); c($a); print($a-name); ? In ZE1 you get AAA. In ZE2 you get ABC. Leon --- Leon Atkinson http

Re: [PHP-DEV] string functions

2003-01-05 Thread Leon Atkinson
Because this behavior is not documented For the record, it is documented: http://www.php.net/manual/en/function.strstr.php If needle is not a string, it is converted to an integer and applied as the ordinal value of a character. And I'm sure it's worked this way for at least three years.

Re: [PHP-DEV] PHP Look Back 2002

2002-12-30 Thread Leon Atkinson
A friend of mine had an uncle who taught dancing to middle-aged couples. One day he visited some lessons and noticed that all the couples were fussing, stepping on each other's feet and arguing. When he asked, what gives? his uncle told him, if you're not fighting, you're not dancing. (It may

Re: [PHP-DEV] Warning in wrong parameter

2002-12-24 Thread Leon Atkinson
Is there any possibility that PHP return me a warning with the message (e.g.) Warning parameter number for [function name] in [page.php] line [line number] ??? If you really need this behavior, do something like assert('func_num_args() == 1'); That should generate the warning you describe if

Re: [PHP-DEV] RC4: ground rules

2002-12-21 Thread Leon Atkinson
Possible values are: - php_auth_exposure=user Only PHP_AUTH_USER is exposed. - php_auth_exposure=pw Only PHP_AUTH_PW is exposed - php_auth_exposure=user,pw Both PHP_AUTH_USER and PHP_AUTH_PW are exposeed Moriyoshi, have you considered using constants here instead of strings? For

Re: [PHP-DEV] RC4: ground rules

2002-12-21 Thread Leon Atkinson
There is no difference here, both are strings anyway. And the latest option AUTH_EXPOSE_USER | AUTH_EXPOSE_PW wont work in an httpd.conf file. Also, this is NOT the style we have in php.ini. I don't see any valid point to use this thing. Derick, you may have a point about it not being as

Re: [PHP-DEV] CGI and CLI (compromise proposal)

2002-12-19 Thread Leon Atkinson
After having consulted with Andrei, Derick and others on irc here is a proposal for a compromise: On Unix: 1. Both cgi and cli are built as 'php' in their respective sapi directories (pretty much as it is today except that cgi gets renamed back from php-cgi to just php). 2. Make install

Re: [PHP-DEV] php.exe - php-cgi.exe

2002-12-10 Thread Leon Atkinson
out on a limb Would it be a tragedy to name both the CLI and CGI versions php on UNIX and php.exe on Windows? Yes, it's a support nightmare. limb broken=yes / I defer to you. Leon -- PHP Development Mailing List http://www.php.net/ To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP-DEV] php.exe - php-cgi.exe

2002-12-10 Thread Leon Atkinson
P.S. I wish people were following this list more closely so that we don't have to discuss same issues over and over again. But it's fun to argue over the same things every six months! :P Leon -- PHP Development Mailing List http://www.php.net/ To unsubscribe, visit:

Re: [PHP-DEV] php.exe - php-cgi.exe

2002-12-09 Thread Leon Atkinson
out on a limb Would it be a tragedy to name both the CLI and CGI versions php on UNIX and php.exe on Windows? On UNIX, it doesn't seem like there'd be much confusion because make install would put sapi/cli/php in /usr/local/bin and sapi/cgi/php in /usr/local/apache/cgi-bin. For the Windows

Re: [PHP-DEV] php.exe - php-cgi.exe

2002-12-09 Thread Leon Atkinson
As Leon has suggested, why not just compile the variants into different directories? Say add a cli/ (since the CLI is newer). Only one directory would go into the PATH (presumably). That would also affect the ini setting for extension_dir. The default value is ./ indicating the same

[PHP-DEV] Making NULL a scalar

2002-11-21 Thread Leon Atkinson
? I'm not sure if this has negative BC issues. I don't feel particularly passionate about this issue, it just occurred to me as I was reviewing the function. Comments? Thanks, Leon --- Leon Atkinson http://www.leonatkinson.com/ -- PHP Development Mailing List http://www.php.net/ To unsubscribe

[PHP-DEV] is_callable Bug 20216

2002-11-18 Thread Leon Atkinson
static method, this is not the case. ? class a { var $c; function b() { return($this-c); } } $d = new a; if(is_callable(array($d, 'b'), FALSE, $name)) { print($name); } ? Thanks! --- Leon Atkinson http://www.leonatkinson.com/ -- PHP Development Mailing

Re: [PHP-DEV] is_callable Bug 20216

2002-11-18 Thread Leon Atkinson
The second argument seems to be for checking syntax only, but I can't figure out how to make is_callable return FALSE when the second argument is TRUE. Try this: var_dump(is_callable(array(1,2), true)); Hmm...OK. Yes, that does make is_callable return false. Can you explain the logic

Re: [PHP-DEV] PHP and Threading

2002-11-15 Thread Leon Atkinson
I was wondering, is PHP in future going to support threading? This would be a very nice feature. I'am currently working on this project of mine, a FTP Server build in PHP which serve MySQL database records. It actually does work very nice, also multiple clients at the same time. It supports

Re: [PHP-DEV] abstract functions

2002-11-09 Thread Leon Atkinson
How about testing for the parent? Such as: ? class AbstractClassException { } class MyClass { var $salutation; function MyClass() { if(!get_parent_class($this)) { throw new AbstractClassException(); } $this-salutation = 'Hello'; } function

[PHP-DEV] Is socket_create_pair() useful?

2002-11-08 Thread Leon Atkinson
I understand how (in C) socketpair() is useful if I can fork(). It's not obvious what I can do with the two sockets that socket_create_pair() creates. What am I missing? Thanks, Leon --- Leon Atkinson http://www.leonatkinson.com/ -- PHP Development Mailing List http://www.php.net