On Wed, 30 Jun 2004 14:20:52 -0400, [EMAIL PROTECTED]
<[EMAIL PROTECTED]> wrote:
> I have some procedural code that i'm wanting to convert into classes(and
> i'm a bit greeen to OOP), hopefully to offer them to the PHP community.
> keep all my config data in arrays of arrays, which i'd like to keep when
> move to a class model, but can't seem to find out the correct defintion
> for example, here is a portion of the array storing connection info to a
> mssql db(keeping it in db land)
> $srvr['etime'] = array();
> $srvr['etime']['server'] = '22.214.171.124:1433';
> $srvr['etime']['db'] = 'dbmaster';
> $srvr['etime']['user'] = 'uname';
> $srvr['etime']['pass'] = 'pword';
> $srvr['etime']['title'] = 'eTime';
> $srvr['etime']['dfltch'] = 'N';
> $srvr['etime']['optional'] = false;
>> var $srvr = array('etime' => array('server' => '126.96.36.199:1433',
>> 'db' => 'dbmaster',
>> 'atime' => 'a value');
oh okay, thanks. thats what i needed.
>> BTW, this looks like DB abstraction data. Have you looked into PEAR
>> DB, MDB, DB_DataObject, etc?
Its actually not DB Abstration data( i do use ADODB for that ). This is
one db server and the rest of the servers in this code are ldap and ssh
connections to other servers(*nix and NT), but i wanted to keep it
db-related, if only slightly.
> How would this need to be defined at the top of a class to taken on as a
> class variable/array. Am i thinking of this wrong?
> I can add them all as scalar variables, but i'd rather work with arrays,
> i use the arrays to loop for other functions. I've tried a variety of
> syntaxes, but keep getting parse errors.
> thanks for any info you can provide.
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
paperCrane --Justin Patrin--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php