[dev] fixed valigns and such
Derek P. Moore
derekm at hackunix.org
Tue Nov 23 11:27:21 PST 2004
> Because you're using a version of PHP that is older than the documented
> minimum version required for Horde 3.0+.
Really? I'm using PHP 4.3.9. And horde/docs/INSTALL in HEAD says, "2. PHP
4.3.0 or above." And I wouldn't have been using a much older version of PHP
when I had to make that change to the script. (I actually made the change to
migrate_user_categories.php over a month ago [I use Fedora Raw Hide, so things
do evolve rather quickly].)
When I was trying to debug the situation, I saw no mention of "STDIN"
in the PHP
manual for fgets and fopen.
http://us2.php.net/manual/en/function.fgets.php
http://us2.php.net/manual/en/function.fopen.php
Today, I found and read:
http://us2.php.net/manual/en/features.commandline.php
However, that manual page does basically say that you can't be sure whether an
end-user's /usr/bin/php is going to be a CGI or CLI binary. It appears some
users have CGI binaries and some CLI binaries, depending on their needs.
Fedora Raw Hide's PHP RPMs ship the CGI php binary. I suppose this makes a
level of sense, though. It allows Fedora users to install non-Apache web
servers and still benefit from PHP via CGI without having to recompile.
I propose that, under these officially documented circumstances, the Horde
project cannot assume as to whether the user has a CGI or CLI php binary. As
the CGI binary does not have the extra "CLI specific Constants", those
constants should be avoided for the benefit of all users. Especially when
those constants are superfluous to the PHP language itself; and the
alternative
is just as readable, maintainable, and legal, with the benefit that it
works for
everyone.
Thanks,
Derek
PS: Again, sorry for the unspecific nature of the patch. I was
assuming it was
short enough to speak for itself. But I see the point of providing
keywords in
the subject and body of emails for future users' searches of the
archives. I'm
usually verbose, anyway, so I'll try to keep that up.
More information about the dev
mailing list