[wp-hackers] 2.4 idea: query/display logic split in admin tools

Stephane Daury wordpress at tekartist.org
Sun Nov 18 02:26:17 GMT 2007


Working on WPhone, I often wished that the query and display logics  
were separated, or the recordset returned, in some of the admin  
listing tools.

For example, in /wp-admin/categories.php, the tools makes use of the  
cat_rows() convenience function. The latter both fetches and echos the  
recordset in the desired html format.

As convenient as the above is, making the unformatted recordset  
available to 3rd-party developers would let us further process the  
information, and extend features, without having to replicate the same  
query. Definitely better for performance/security, and so much more.

Same goes for the WP_User_Search class in /wp-admin/users.php, which  
could be so useful to others if not so *aggressive* (echos only) in  
its constructor.

This would be immediately be very helpful to our plugin, but I would  
say would also open the door to other features, such as visualization  
(graphs, img generation, etc).

Opinions? Ideas? Worth a patch/ticket?

Stephane




More information about the wp-hackers mailing list