[PHP-DEV] Bug #14782 Updated: key_exists renamed to array_key_exists

2002-01-02 Thread mike

ID: 14782
User updated by: [EMAIL PROTECTED]
Reported By: [EMAIL PROTECTED]
Status: Closed
Bug Type: Feature/Change Request
Operating System: all
PHP Version: 4.1.1
Old Assigned To: zak
Assigned To: 
New Comment:

I understand the issue or having functions disappear and then reappear..


We are a application service provider. We provide a content management system and 
application framework written in PHP to our customer's who host their sites on our 
colocated server at Rackspace. Just about every customer is running different version 
of our application. 

To migrate from one version to another is not just a file copy. It involves data base 
migration and changes and also application config changes. All our sites on our server 
are using PHP 4.0.6. To load PHP 4.1.1 means I have to bring all my sites down, load 
php 4.1.1, migrate the data, update each customer's config for the new app and then 
test each site. This is a huge undertaking. The way we normally handle application 
upgrades is to upgrade the customer's site the next time that their site comes in for 
maintenance work. I can understand that changing a function in a single site's scripts 
is not much of an issue, but please consider what this means to an ISP/ASP that is 
running many, possibly hundreds of sites. How an ISP will break many sites by loading 
PHP 4.1.1.

Our latest version of our app uses the key_exists() function. The funciton is what was 
needed for the problem at hand. I had no idea that a PHP function could suddenly 
become an invalid function in the next release of the language.  I can understand 
how an API can be retired. It out lived it's purpose or was buggy, but not function 
name.

I understand the naming consistancy problem that key_exists had, but architecturly how 
does it hurt the PHP to keep an alias for it? You could keep the alias and then put a 
warning on the www.php.net/key_exists page saying that the array_key_exists function 
should be used instead and that the key_exists function. Does an alias affect 
performance or the memory foot print of PHP? Is it just a pointer to the correct 
function?

Please understand that I am arguing this point to protect PHP and my company's 
investment. My company has based it's current and future success on the reliability, 
consistancy, performance, and power of PHP. 

Please make these kind of decisions more cautiously with larger more complex PHP 
applications and ISP/ASPs in mind.

Thank you for your response and concern on these issues.

Mike Boulet
Newfangled Web Factory
www.newfangled.com


Previous Comments:


[2001-12-31 16:59:41] [EMAIL PROTECTED]

As Someone Who Shall Not Be Named Because They Are Also 
On Vacation has pointed out to me off list, it would be a 
bad thing to have functions disappearing and reappearing 
between versions. The function shall stay as is - please 
adjust your scripts accordingly.

Thank you.




[2001-12-31 16:37:26] [EMAIL PROTECTED]

Assigning to myself




[2001-12-31 16:21:14] [EMAIL PROTECTED]

Hi Mike,

Unless one of the developers objects, I will add the alias 
- however, if the change is made, it would not show up 
'til the next release.

I would recommend that you modify your files anyway. It is 
a small amount of work using gawk or vim. :)

Alternately, you can modify your local copy of PHP until 
next release.

Add the following line to ext/standard/basic_functions.c:
  PHP_FALIAS(key_exists, array_key_exists, NULL)

The line should go after the line that looks like:
  PHP_FE(array_key_exists,NULL)

Once you have made the change and saved, recompile PHP.






[2001-12-31 15:33:39] [EMAIL PROTECTED]

I have a very large PHP application running on my Linux web server that uses the 4.0.6 
function key_exists. The problem is that I have 30 copies of this application running 
on the server. If I upgrade my server to php 4.1.1, I will be forced to upgrade all 30 
sites with a new version of my application where array_key_exists is used instead. 
This is a HUGE undertaking.

Is there any way to put the key_exists alias back in so that PHP compatiblity is not 
broken?


Thank you





Edit this bug report at http://bugs.php.net/?id=14782edit=1


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DEV] Bug #14782 Updated: key_exists renamed to array_key_exists

2002-01-02 Thread Zak Greant

Well said. :) Well enough that the developer who made the change has 
asked to have an alias added. Attached is the required patch.

The alias should appear in the next maintenence release of PHP.

--zak

On 2002-2-01 09:10, [EMAIL PROTECTED] wrote:
 ID: 14782
 User updated by: [EMAIL PROTECTED]
 Reported By: [EMAIL PROTECTED]
 Status: Closed
 Bug Type: Feature/Change Request
 Operating System: all
 PHP Version: 4.1.1
 Old Assigned To: zak
 Assigned To:
 New Comment:

 I understand the issue or having functions disappear and then reappear..


[cut]


Index: ext/standard/basic_functions.c
===
RCS file: /repository/php4/ext/standard/basic_functions.c,v
retrieving revision 1.433
retrieving revision 1.434
diff -u -r1.433 -r1.434
--- ext/standard/basic_functions.c	30 Dec 2001 09:36:24 -	1.433
+++ ext/standard/basic_functions.c	2 Jan 2002 21:21:48 -	1.434
@@ -17,7 +17,7 @@
+--+
  */
 
-/* $Id: basic_functions.c,v 1.433 2001/12/30 09:36:24 zak Exp $ */
+/* $Id: basic_functions.c,v 1.434 2002/01/02 21:21:48 zak Exp $ */
 
 #include php.h
 #include php_main.h
@@ -789,6 +789,7 @@
 	/* aliases from array.c */
 	PHP_FALIAS(pos, current,  first_arg_force_ref)
 	PHP_FALIAS(sizeof, count, 	NULL)
+	PHP_FALIAS(key_exists,			array_key_exists,		NULL)
 
 	/* functions from assert.c */
 	PHP_FE(assert,			NULL)


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]


Re: [PHP-DEV] Bug #14782 Updated: key_exists renamed to array_key_exists

2002-01-01 Thread Markus Fischer

On Mon, Dec 31, 2001 at 09:21:15PM -, [EMAIL PROTECTED] wrote : 
 ID: 14782
 Updated by: zak
 Reported By: [EMAIL PROTECTED]
 Old Status: Open
 Status: Feedback
 Bug Type: Feature/Change Request
 Operating System: all
 PHP Version: 4.1.1
 New Comment:
 
 Hi Mike,
 
 Unless one of the developers objects, I will add the alias 
 - however, if the change is made, it would not show up 
 'til the next release.

-1 ... it's too late now. 4.1.0 with, 4.1.1 without, 4.1.x
with ... no, this doesn't make sense IMHO 

-- 
Please always Cc to me when replying to me on the lists.

-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Bug #14782 Updated: key_exists renamed to array_key_exists

2001-12-31 Thread zak

ID: 14782
Updated by: zak
Reported By: [EMAIL PROTECTED]
Old Status: Open
Status: Feedback
Bug Type: Feature/Change Request
Operating System: all
PHP Version: 4.1.1
New Comment:

Hi Mike,

Unless one of the developers objects, I will add the alias 
- however, if the change is made, it would not show up 
'til the next release.

I would recommend that you modify your files anyway. It is 
a small amount of work using gawk or vim. :)

Alternately, you can modify your local copy of PHP until 
next release.

Add the following line to ext/standard/basic_functions.c:
  PHP_FALIAS(key_exists, array_key_exists, NULL)

The line should go after the line that looks like:
  PHP_FE(array_key_exists,NULL)

Once you have made the change and saved, recompile PHP.




Previous Comments:


[2001-12-31 15:33:39] [EMAIL PROTECTED]

I have a very large PHP application running on my Linux web server that uses the 4.0.6 
function key_exists. The problem is that I have 30 copies of this application running 
on the server. If I upgrade my server to php 4.1.1, I will be forced to upgrade all 30 
sites with a new version of my application where array_key_exists is used instead. 
This is a HUGE undertaking.

Is there any way to put the key_exists alias back in so that PHP compatiblity is not 
broken?


Thank you





Edit this bug report at http://bugs.php.net/?id=14782edit=1


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Bug #14782 Updated: key_exists renamed to array_key_exists

2001-12-31 Thread zak

ID: 14782
Updated by: zak
Reported By: [EMAIL PROTECTED]
Status: Feedback
Bug Type: Feature/Change Request
Operating System: all
PHP Version: 4.1.1
Old Assigned To: 
Assigned To: zak
New Comment:

Assigning to myself


Previous Comments:


[2001-12-31 16:21:14] [EMAIL PROTECTED]

Hi Mike,

Unless one of the developers objects, I will add the alias 
- however, if the change is made, it would not show up 
'til the next release.

I would recommend that you modify your files anyway. It is 
a small amount of work using gawk or vim. :)

Alternately, you can modify your local copy of PHP until 
next release.

Add the following line to ext/standard/basic_functions.c:
  PHP_FALIAS(key_exists, array_key_exists, NULL)

The line should go after the line that looks like:
  PHP_FE(array_key_exists,NULL)

Once you have made the change and saved, recompile PHP.






[2001-12-31 15:33:39] [EMAIL PROTECTED]

I have a very large PHP application running on my Linux web server that uses the 4.0.6 
function key_exists. The problem is that I have 30 copies of this application running 
on the server. If I upgrade my server to php 4.1.1, I will be forced to upgrade all 30 
sites with a new version of my application where array_key_exists is used instead. 
This is a HUGE undertaking.

Is there any way to put the key_exists alias back in so that PHP compatiblity is not 
broken?


Thank you





Edit this bug report at http://bugs.php.net/?id=14782edit=1


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DEV] Bug #14782 Updated: key_exists renamed to array_key_exists

2001-12-31 Thread zak

ID: 14782
Updated by: zak
Reported By: [EMAIL PROTECTED]
Old Status: Feedback
Status: Closed
Bug Type: Feature/Change Request
Operating System: all
PHP Version: 4.1.1
Assigned To: zak
New Comment:

As Someone Who Shall Not Be Named Because They Are Also 
On Vacation has pointed out to me off list, it would be a 
bad thing to have functions disappearing and reappearing 
between versions. The function shall stay as is - please 
adjust your scripts accordingly.

Thank you.


Previous Comments:


[2001-12-31 16:37:26] [EMAIL PROTECTED]

Assigning to myself




[2001-12-31 16:21:14] [EMAIL PROTECTED]

Hi Mike,

Unless one of the developers objects, I will add the alias 
- however, if the change is made, it would not show up 
'til the next release.

I would recommend that you modify your files anyway. It is 
a small amount of work using gawk or vim. :)

Alternately, you can modify your local copy of PHP until 
next release.

Add the following line to ext/standard/basic_functions.c:
  PHP_FALIAS(key_exists, array_key_exists, NULL)

The line should go after the line that looks like:
  PHP_FE(array_key_exists,NULL)

Once you have made the change and saved, recompile PHP.






[2001-12-31 15:33:39] [EMAIL PROTECTED]

I have a very large PHP application running on my Linux web server that uses the 4.0.6 
function key_exists. The problem is that I have 30 copies of this application running 
on the server. If I upgrade my server to php 4.1.1, I will be forced to upgrade all 30 
sites with a new version of my application where array_key_exists is used instead. 
This is a HUGE undertaking.

Is there any way to put the key_exists alias back in so that PHP compatiblity is not 
broken?


Thank you





Edit this bug report at http://bugs.php.net/?id=14782edit=1


-- 
PHP Development Mailing List http://www.php.net/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]