Re: PEAR Account Request: dostick
| From: | Jackson Miller | Date: | Thu, 22 Apr 2004 02:05:49 +0000 |
| Subject: | Re: PEAR Account Request: dostick | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-28242@lists.php.net to get a copy of this message | ||
On Wednesday 21 April 2004 12:34, Lorenzo Alberton wrote:
> On 21 Apr 2004 16:23:40 -0000, Roman Dostovalov wrote:
> 1) DB_QueryTool is supposed to be extended by custom classes.
>
> >From the example you gave, it looks like you want to use it without
>
> subclassing it? If so, why? It's not exactly the way this class was
> designed to work...
This may be getting off-topic, but I use DB_QT without subclassing it. The
reason for this is that I just wanted to use DB_QT to provide a complex
search query method within one of my existing libraries and didn't want
another file in my class tree. There is no patch needed to use DB_QT without
extending it. You simple do:
require_once('DB/QueryTool.php');
$query =& new DB_QueryTool();
$query->setDbInstance($db); // use existing db connection
-Jackson