Overriding Built-In Functions and making db connection local

Overriding Built-In Functions and making db connection local

am 19.02.2009 20:52:05 von brownbull

Hello,

I'm searching for a possibility to override build-in function.PECL APD isn't a possible solution for me. Is there any other possibility to override a built-in function or to disallow the call without manipulation the php.ini?

My second problem is that it is needed for a special framework that the conenction to a database isn't set global. I need it to ensure that every databasecall is through my class.
Is there any possibility for this?

--
Psssst! Schon vom neuen GMX MultiMessenger gehört? Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger01

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Re: Overriding Built-In Functions and making db connectionlocal

am 19.02.2009 22:35:49 von dmagick

brownbull@gmx.net wrote:
> Hello,
>
> I'm searching for a possibility to override build-in function.PECL APD isn't a possible solution for me. Is there any other possibility to override a built-in function or to disallow the call without manipulation the php.ini?

You can't override existing functions (whether they're built in php ones
or ones you make up yourself).

> My second problem is that it is needed for a special framework that the conenction to a database isn't set global. I need it to ensure that every databasecall is through my class.
> Is there any possibility for this?

Nope. You can't just disable the function because your class needs to
make it, and disable_functions disables that function everywhere, you
can't tell it to do it for every file but "x.php".

--
Postgresql & php tutorials
http://www.designmagick.com/


--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php