Re: Passing flags to functions

From: Date: Tue, 06 Jun 2000 23:48:29 +0000
Subject: Re: Passing flags to functions
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-20405@lists.php.net to get a copy of this message
Andrei Zmievski wrote: > > I'd like to start a discussion on working out a generalized way of > passing flags to internal PHP functions. I've often found myself writing > a function and having to anticipate that it might need to accept some > flags to affect its operation, and it was not immediately clear how > those flags should be accessed. This is a bigger problem when you start > working with functions that take optional arguments, because if you want > to add an argument for flags you'll have to stick it at the end and make > your users pass all intermediate arguments as well, non-required as they > are. I also need something like this if SSL support is to be integrated into the existing socket/reading/writing functions. I can make it an external extension and to be honest I think that would be easiest. On the other hand, people already familiar with fsockopen() and friends will benefit if it's integrated. Any thoughts? -- -------------------------------------- Evan Klinger evan@domainclerk.com President DomainClerk www.domainclerk.com - $13 domain names

« previous php.dev (#20405) next »