Over the last few months, I’ve made a number of changes to the look and feel of the website. Starting with the front page’s “Fluidity” theme, which is an experiment in modern free-flowing web design, most of the blogs here have gotten new themes, all very different. My CakePHP blog has gotten a CakePHP.org0-inspired face lift in the last two months or so. Last summer, I designed the Design blog’s Groovy theme. And just today, I released the Roaring Twenties theme that now graces the Plugins blog.
It became very apparent to me in the last week since releasing the WP-Tabbity plugin that this particular blog’s theme was getting a little long in the tooth. By my count, probably at least four years old! Worse, it suffered from the assumption – entirely reasonable four years ago – of monitors all being roughly the same dimensions they’d been for ninety years of television history to that point. Left-aligned websites looked fine then, but wow! they don’t any more on wide-screens!
Subscribe to the HolisticNetworking.Net feed

It happens from time to time that we need to associate Models which do not share a common key. An example of this is when I needed to associate pages with templates in a complex join where the PageSettings Model has a primary key of pageid and the PageTemplate Model has a primary key of template_id. We cannot use the primaryKey index of the association array to indicate the relationship, so we need to bypass that index altogether and instead use 'conditions' to specify the relationship as follows:
[php]
var $hasOne = array('PageTemplate' => array('foreignKey' => false,
'conditions' => array('PageSettings.page_template = PageTemplate.template_id')));
[/php]
Note also that the 'conditions' clause is set using explicit conditions, inasmuch as we are stating that the PageSettings.page_template in the current query should be the same as the PageTemplate.template_id value. I've personally been confused in the past, thinking that the 'PageSettings.page_template' => 'PageTemplate.template_id' formula would naturally be the preferred way of forming the condition in CakePHP. Certainly, that would make sense based on convention, but for reasons I'm not familiar with, this is not how they do it.
» Continue Reading....

I love my Droid Eris, it's the neatest little toy I've bought myself in years and years. But it does have one disadvantage, which is that the high-power consumption means that the battery doesn't last very long. And when you've got a job out here in the sticks, the phone starts roaming and you really lose battery power. At this point, its like I'm driving an "A Car," with my phone running out of juice about 7pm every night.
What's an A Car? Well, during the rationing of World War II, they assigned every car in the country with a letter, A, B or C, that dictated when the car was eligible to get gasoline. A Cars got gas on Monday and Tuesday, B Cars got gas on Wednesday and Thursday and C Cars got gas on Friday and Saturday. In those days, everything was closed on Sunday.
Well, as you can clearly surmise, those cars that got gas on Monday and Tuesday would be at their lowest point on Friday and Saturday, which meant A Car drivers generally got stuck at home or else had to tool around in someone else's ride. C Cars were the cars to have.
But, this is
» Continue Reading....
Summary: Maintains a list of global terms.
Detail: This very complex and flexible function matches a $term_id passed to it and if no global term exists for this term, creates one. It then returns the global term_id to the requesting function. Checks to see if global terms are enabled before performing this action.
» Continue Reading....
Array
(
[0] => Array
(
[blog_id] => 13
[blog_link] => http://holisticnetworking.net/cake
[blog_name] => The Bumbling Baker
[post_title] => Associating Models Without a primaryKey in Common
[display_name] => Thomas Belknap
[post_author] => tbelknap@holisticnetworking.net
[post_content] => It happens from time to time that we need to associate Models which do not share a common key. An example of this is when I needed to associate pages with templates in a complex join where the PageSettings Model has a primary key of pageid and the PageTemplate Model has a primary key of template_id. We cannot use the primaryKey index of the association array to indicate the relationship, so we need to bypass that index altogether and instead use 'conditions' to specify the relationship as follows:
[php]
var $hasOne = array('PageTemplate' => array('foreignKey' => false,
'conditions' => array('PageSettings.page_template = PageTemplate.template_id')));
[/php]
Note also that the 'conditions' clause is set using explicit conditions, inasmuch as we are stating that the PageSettings.page_template in the current query should be the same as the PageTemplate.template_id value. I've personally been confused in the past, thinking that the 'PageSettings.page_template' => 'PageTemplate.template_id' formula would naturally be the preferred way of forming the condition in CakePHP. Certainly, that would make sense based on convention, but for reasons I'm not familiar with, this is not how they do it.
[post_link] => http://holisticnetworking.net/cake/2010/07/associating-models-without-a-primarykey-in-common/
[image_rec] => http://holisticnetworking.net/wp-content/themes/hn_30_fluidity/images/logo_silver_180x135.gif
[image_sqr] => /wp-content/themes/tonbo-home/images/dfe_stamp_80x80.gif
[image_med] => /wp-content/themes/hn_30_fluidity/images/baker_blog_image.gif
)
[1] => Array
(
[blog_id] => 1
[blog_link] => http://holisticnetworking.net
[blog_name] => HolisticNetworking.Net
[post_title] => A Droid in the Country: Driving the "A Car"
[display_name] => Thomas Belknap
[post_author] => tbelknap@holisticnetworking.net
[post_content] => I love my Droid Eris, it's the neatest little toy I've bought myself in years and years. But it does have one disadvantage, which is that the high-power consumption means that the battery doesn't last very long. And when you've got a job out here in the sticks, the phone starts roaming and you really lose battery power. At this point, its like I'm driving an "A Car," with my phone running out of juice about 7pm every night.
What's an A Car? Well, during the rationing of World War II, they assigned every car in the country with a letter, A, B or C, that dictated when the car was eligible to get gasoline. A Cars got gas on Monday and Tuesday, B Cars got gas on Wednesday and Thursday and C Cars got gas on Friday and Saturday. In those days, everything was closed on Sunday.
Well, as you can clearly surmise, those cars that got gas on Monday and Tuesday would be at their lowest point on Friday and Saturday, which meant A Car drivers generally got stuck at home or else had to tool around in someone else's ride. C Cars were the cars to have.
But, this is
[post_link] => http://holisticnetworking.net/blog/2010/06/24/a-droid-in-the-country-driving-the-a-car/
[image_rec] => /wp-content/themes/hn_30_fluidity/images/HN_Home_blogImage.gif
[image_sqr] => /wp-content/themes/hn_30_fluidity/images/HN_Home_blogImage.gif
[image_med] => /wp-content/themes/hn_30_fluidity/images/HN_Home_blogImage.gif
)
[2] => Array
(
[blog_id] => 6
[blog_link] => http://holisticnetworking.net/plugins
[blog_name] => HN.Net WordPress Plugins
[post_title] => global_terms( $term_id, $deprecated = '' )
[display_name] => Thomas Belknap
[post_author] => tbelknap@holisticnetworking.net
[post_content] => Summary: Maintains a list of global terms.
Detail: This very complex and flexible function matches a $term_id passed to it and if no global term exists for this term, creates one. It then returns the global term_id to the requesting function. Checks to see if global terms are enabled before performing this action.
[post_link] => http://holisticnetworking.net/plugins/2010/06/20/global_terms-term_id-deprecated/
[image_rec] => http://holisticnetworking.net/wp-content/themes/hn_30_fluidity/images/logo_silver_180x135.gif
[image_sqr] => /wp-content/themes/tonbo-home/images/dfe_stamp_80x80.gif
[image_med] => wp-content/themes/hn_30_fluidity/images/hn_plugins_blog_image.gif
)
)