Wordpress = Site Admin Made Easy

clixcorp.com

February 2nd, 2010 at 12:16 am

Wordpress Classes.php, Queries or Request URI’s?

in: Queries

It took me a long while to realize that a wordpress query is not a db query.  It’s the entire WP class dedicated to decoding the Request URI, (or the url if you will).  It’s hard enough keeping up with the world coding community on cms syntax, but this one is one I guess I’ll have to live with; (In classes.php the words of ‘black magic’ are mentioned).

What’s strange is the ton of code dealing with parsing the URI, as well as the limited amount of hooks embedded in classes.php and query.php.   Simplicity is golden, and this one will definitely leave you scratching your head.   That said, I set out to do some playing around with them to see what they (the hooks) would provide a plugin developer.  Coming from years of perl, the limited explanations of how to work with php objects and multi-dimensional arrays were trying my patience, especially when attempting to combine that with the wordpress ‘query’ model=>as a $wpdb->object.

So I just took someone’s existing code from php.net, and developed my own ‘noob developer’ plugin to display the objects in a simple (text) array key=>value format, for the instances in classes.php where hooks were planted.

Yikes on the results! Well, this is easier said than done, but why on earth did they use the same exact format of an .htaccess file, to implement an almost unlimited solution in wordpress?  To accomodate Windows Servers?

And that goes to my next point, why are posts, also named ‘categories’?  I just released the clix-post-category-exclusion plug-in, and in looking over previous ‘exlusion’ (tagged/termed) plug-ins online, one finds that most are doing all the same thing… excluding posts from posts/categories (especially in template mods) – and – because of the recommended url structures from codex.wordpress, (to limit the size of the _transient_rewrite_rules entry and parsing thereof), I know the answer… I really do – it’s because wordpress was designed as a blogging platform, and NOT as a cms, although everybody wants to use it as one – and WP team development 2010, probably want to keep it that way.

Do I blame them?  I want to.  But I shouldn’t.  They started out with nothing, looking to achieve a goal… to become the best and most utilized blogging platform on the planet.  Everything you see here is my opinion -  ‘in hindsight’.   It’s what I think it should’ve been started as, instead of what I think it could do.

That said, (which is a lot once you read into it),  we’re working on a new version of classes.php and a better widget for the future for wordpress.  One that will allow you to have – your site, your way, and… your structure.  The WordPress CMS Engine.  There are millions of users/sites that could benefit, and this is where we’re going.

Hang tight for the next plug-in, it’ll rock your world!




-

Comments are closed.

Query Count: 36 queries. 0.165 seconds.