...

View Full Version : Help with variable variables in mySQL connection class



coasters2k
06-18-2006, 05:38 PM
I'm using a simple mySQL database class to connect and query my database to make it as simple as possible to connect to different databases down the line...

I thought the solution to my problem would be introducing variable variables to have the query results specify which query it wants but its proving difficult with all the $this-> class stuff and whatnot...

Help? Thanks!

GJay
06-18-2006, 06:35 PM
why not return the resultset when query() is called, and have your other functions accept that as an argument (perhaps default to the most-recent if none is passed?)
Or make a new 'ResultSet' class that implements the resultset functions you want?

coasters2k
06-18-2006, 08:18 PM
Doh! That seems like a much easier solution. Thanks!



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum