W dniu 2014-11-29 16:37, Maciej Sobaczewski pisze:
W dniu 2014-11-29 08:19, Hannes Magnusson pisze:
On Fri, Nov 28, 2014 at 10:14 PM, <[email protected]> wrote:
Commit: 41ddbc8f0568eb6be46c065897d5c7465d2cad82
Author: Sobak <[email protected]> Sat, 29 Nov 2014
07:14:15 +0100
Parents: fd9f82d0fb52153cee81727fb9ca47235235af2d
Branches: master
Link:
http://git.php.net/?p=web/bugs.git;a=commitdiff;h=41ddbc8f0568eb6be46c065897d5c7465d2cad82
Log:
Fix bug #68405 (The PHP version dropdown doesn't show PHP versions
after a
form error)
require_once caused a problem here, so file needs to be included earlier
and reused by those two functions
<http://www.php.net/unsub.php>
Or... Rather then adding more globals... Drop the _once ?
Let individual functions that need that list include the file :]
-Hannes
Hello Hannes,
I'm also not in favor of globals, but php_versions.php declares new
function and including this file twice causes an error (redeclaration of
function). Probably the best idea would be to pass $versions using
parameter, but it would introduce inconsistency.
I'm not happy with my solution and totally open for better ideas :)
Cheers,
Maciej.
Another option would be, obviously, to place buildVersions() in if
(function_exists(...)) block, but it seems like treating synptoms
instead of causes.
--
PHP Webmaster List Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php