<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Query7 &#187; Zend</title>
	<atom:link href="http://query7.com/category/zend/feed" rel="self" type="application/rss+xml" />
	<link>http://query7.com</link>
	<description>PHP, Javascript, Python and Web Development</description>
	<lastBuildDate>Sat, 25 Jun 2011 21:29:51 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.4</generator>
		<item>
		<title>Internationalization and Partial Rendering in the CodeIgniter Framework</title>
		<link>http://query7.com/internationalization-and-partial-rendering-in-the-codeigniter-framework</link>
		<comments>http://query7.com/internationalization-and-partial-rendering-in-the-codeigniter-framework#comments</comments>
		<pubDate>Mon, 06 Sep 2010 16:59:10 +0000</pubDate>
		<dc:creator>Prakash Mohanty</dc:creator>
				<category><![CDATA[Code Igniter]]></category>
		<category><![CDATA[Tutorials]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Zend]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[codeigniter]]></category>
		<category><![CDATA[localization]]></category>
		<category><![CDATA[multi-language]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[Zend Framework]]></category>

		<guid isPermaLink="false">http://www.webdevelopmentbits.com/?p=678</guid>
		<description><![CDATA[As experienced Web developers, it won’t shock you to find literally thousands of comparisons between CodeIgniter and the other popular frameworks you may be considering for your site. Each framework has its good and, ummm… less good points, but]]></description>
			<content:encoded><![CDATA[<p>As experienced Web developers, it won’t shock you to find literally thousands of comparisons between <a href="http://codeigniter.com/">CodeIgniter</a> and the other popular frameworks you may be considering for your site. Each framework has its good and, ummm… <em>less good </em>points, but let’s say you’re wedded to CodeIgniter for whatever reason, and you’ve got a few languages you’re tasked with supporting so you’re getting set to work on internationalization. So you go back and refresh your memory of just how to do that, and you begin coming across certain sites saying that CodeIgniter doesn&#8217;t support internationalization. So you begin to ponder ditching CodeIgniter, since you’re aces in a couple other frameworks, but that would be a mistake. CodeIgniter is a genius framework, and well optimized for so many other tasks that it’s worth sticking with. Plus, we have a nifty solution to your CodeIgniter internationalization issues.</p>
<p>If you’re going to be developing a multi-language site, then when you’re setting up your CMS, from the beginning be sure to go for a CodeIgniter CMS like CI-CMS or Pyro CMS in order to minimize languages issues down the road. {The <a href="http://www.zend.com/en/">Zend</a> framework, with its strong partial rendering, may seem like a better option in a pinch, but CodeIgniter trumps Zend in other crucial areas, so it’s worth sticking with.}</p>
<p>With CodeIgniter it makes great sense to build in modular separation (you can find the library <a href="http://maestric.com/doc/php/codeigniter_i18n">here</a>), though at first glace I’ll agree it looks like a tough implementation.</p>
<p>As you scan the library article, the lines to put most emphasis on will naturally deal with switching languages.</p>
<p>For example, you’ll find in the Notes section of the above library site:</p>
<pre>&lt;?php

anchor($this-&gt;lang-&gt;switch_uri('fr'),'Display current page in French');
$lang['about.gender'] = "Je suis un homme";

?&gt;</pre>
<p>Plug the lines below into your route.php and config.php files.</p>
<p>In config/route.php :</p>
<pre>&lt;?php

$route['^fr/(.+)$'] = "$1";

$route['^en/(.+)$'] = "$1";

// '/en' and '/fr' URIs -&gt; use default controller

$route['^fr$'] = $route['default_controller'];

$route['^en$'] = $route['default_controller'];

?&gt;</pre>
<p>In config/config.php,</p>
<p>$config['base_url']  must correspond to your configuration. For example,</p>
<pre>&lt;?php

$config['index_page'] = "";

?&gt;</pre>
<p>Creating the language file in system/application/language/english/about_lang.php was already clear to you.</p>
<pre>&lt;?php

$lang['about.gender'] = "I'm a man";
$lang['about.gender'] = "Je suis un homme";

?&gt;</pre>
<p>The controller part at</p>
<p>system/application/controllers/about.php should also be clear to you.</p>
<p>In the index function</p>
<pre>&lt;?php

$this-&gt;load-&gt;helper('language');

$this-&gt;load-&gt;helper('url');

// load language file‚

$this-&gt;lang-&gt;load('about');

$this-&gt;load-&gt;view('about');

?&gt;</pre>
<p>Once you&#8217;re done with these, browse to the welcome module on your local machine at http://localhost/ci/fr/welcome/test.<br />
You should find the language lines show up as expected.</p>
<p>Be sure to hit the CodeIgniter <a href="http://codeigniter.com/wiki/Language_Translation/">resource site</a> for some really useful, ready made down loadable translation files in zip format. This’ll save you heaps of time and work. Once you’ve extracted these zip archives, you’ll find files named as in the <em>about_lang.php </em>as above.</p>
<p>Next, while looking into partial rendering, we come across <a href="http://codeigniter.com/wiki/View_Object_PHP5/">this site</a>, which brings us more clarity.</p>
<pre>&lt;?php

$this-&gt;view-&gt;layout = 'master_layout_file'; // or leave this empty to render partials only

//Add a partial file and (optional) $data‚

$header = $this-&gt;view-&gt;load('header','header_file',$data);

// subheader‚

$header-&gt;load('sub_header','sub_header_file',$data);

$header-&gt;set($data);

$this-&gt;view-&gt;render();

?&gt;</pre>
<p>Now let’s render the partials in our master template:</p>
<pre>&lt;?php $header-&gt;render();?&gt;;</pre>
<p>And that&#8217;s about it. Pretty simple, right?</p>
<p>Before closing, just a brief note: PyroCMS is a multilingual CodeIgniter CMS with built-in language configuration options you can tailor to your site. You can find language settings inside the admin panel, and while the implementation will be similar to the approach we’ve outlined above it may not be an exact match.</p>
<p>Well, that&#8217;s it!  Thanks for reading, and I hope this helps.  If you have any questions about this specific tutorial or any other issues re: web development with CodeIgniter, Zend, or whatever else, drop us a line any time from our contact page!</p>
<p>Prakash R. Mohanty</p>
<p>Senior Software Engineer<br />
Sourcebits Technologies</p>
]]></content:encoded>
			<wfw:commentRss>http://query7.com/internationalization-and-partial-rendering-in-the-codeigniter-framework/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Zend Framework &#8211; Sourcebits Contribution Team</title>
		<link>http://query7.com/zend-framework-sourcebits-contribution-team</link>
		<comments>http://query7.com/zend-framework-sourcebits-contribution-team#comments</comments>
		<pubDate>Tue, 24 Mar 2009 11:35:09 +0000</pubDate>
		<dc:creator>Ramses Paiva</dc:creator>
				<category><![CDATA[Web 2.0]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Zend]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Contributors]]></category>
		<category><![CDATA[Sourcebits]]></category>
		<category><![CDATA[Zend Framework]]></category>

		<guid isPermaLink="false">http://www.webdevelopmentbits.com/?p=89</guid>
		<description><![CDATA[<p>Sourcebits is investing efforts for making one of the best PHP frameworks even better. With a whole team of talented and skilled developers, we&#8217;re contributing to the framework using the best proven components we have developed based on our experience using the Zend Framework on our projects.</p>
<p>You can check out the proposals we have already submmitted for review here:<br />
* <a href="http://framework.zend.com/wiki/display/ZFPROP/Zend_Calendar+-+Ramses+Paiva">Zend Calendar</a>.<br />
* <a href="http://framework.zend.com/wiki/display/ZFPROP/Zend_Template+-+Ramses+Paiva">Zend Template</a>.</p>
<p>Hope you&#8217;ll enjoy! <img src='http://query7.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></description>
			<content:encoded><![CDATA[<p>Sourcebits is investing efforts for making one of the best PHP frameworks even better. With a whole team of talented and skilled developers, we&#8217;re contributing to the framework using the best proven components we have developed based on our experience using the Zend Framework on our projects.</p>
<p>You can check out the proposals we have already submmitted for review here:<br />
* <a href="http://framework.zend.com/wiki/display/ZFPROP/Zend_Calendar+-+Ramses+Paiva">Zend Calendar</a>.<br />
* <a href="http://framework.zend.com/wiki/display/ZFPROP/Zend_Template+-+Ramses+Paiva">Zend Template</a>.</p>
<p>Hope you&#8217;ll enjoy! <img src='http://query7.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://query7.com/zend-framework-sourcebits-contribution-team/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Philosophy of Object Oriented Programming and Software Design</title>
		<link>http://query7.com/philosophy-of-object-oriented-programming-and-software-design</link>
		<comments>http://query7.com/philosophy-of-object-oriented-programming-and-software-design#comments</comments>
		<pubDate>Sat, 01 Nov 2008 14:33:25 +0000</pubDate>
		<dc:creator>yaapa</dc:creator>
				<category><![CDATA[ActionScript]]></category>
		<category><![CDATA[Best Practices]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Flash]]></category>
		<category><![CDATA[Flex]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[Ruby on Rails]]></category>
		<category><![CDATA[Web 2.0]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[Zend]]></category>
		<category><![CDATA[jQuery]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[Object-Oriented Programming]]></category>
		<category><![CDATA[philosophy]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://www.webdevelopmentbits.com/?p=241</guid>
		<description><![CDATA[Now, I am no expert in OOP or software design, but here's a philosophy which might help you make the most of what you know about OOP and software design.]]></description>
			<content:encoded><![CDATA[<p>Now, I am no expert in OOP or software design, but here&#8217;s a philosophy which might help you make the most of what you know about OOP and software design. I have observed and have read reports that people absorb most information when it&#8217;s presented in lists, preferably bulleted. So without any further ramling, I present you my bulleted philosophy of OOP and Software Design.</p>
<ul>
<li>It&#8217;s not how much and what you know; but what you can do with what you know, which&#8217;s important.</li>
</ul>
<ul>
<li>Ability to implement Polymorphism, Inheritance, private, public namespaces, static methods etc is no guarantee you are a good OO developer.</li>
</ul>
<ul>
<li>OOP is useless if you don&#8217;t use it to create good software design (architecture).</li>
</ul>
<ul>
<li>Using packages, classes, etc does not guarantee good software design.</li>
</ul>
<ul>
<li>When designing your software, think of it as an electronic device you are designing.</li>
</ul>
<ul>
<li>Sketch out the &#8216;electronic device&#8217;. Label the different components, list their functionalities.</li>
</ul>
<ul>
<li>Stay hungry, stay foolish.</li>
</ul>
<p>That&#8217;s it for today. I hope you are blessed with more knowledge, and the ability to make the best use of them.  Adios!</p>
]]></content:encoded>
			<wfw:commentRss>http://query7.com/philosophy-of-object-oriented-programming-and-software-design/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>

