I am trying to extend the mysqli class to make a helper class that will abstract away some of the complexities. One of the main things I want to accomplish is to make use of prepared statements.
I don’t really know where to start, or how to handle input and output properly in one class. Another problem is that I am unable to output data as an array while using prepared statements.
I could really use a simple example to point me in the right direction.
Check out the implementation of Zend_Db, and in particular,
Zend_Db_Select. In fact, you might just opt to use that instead of developing your own. Examples: