<?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>My Science Is Better &#187; zend framework</title>
	<atom:link href="http://www.myscienceisbetter.info/tag/zend-framework/feed" rel="self" type="application/rss+xml" />
	<link>http://www.myscienceisbetter.info</link>
	<description></description>
	<lastBuildDate>Sat, 20 Mar 2010 16:16:09 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Setup ZF using svn externals</title>
		<link>http://www.myscienceisbetter.info/setup-zf-using-svn-externals.html</link>
		<comments>http://www.myscienceisbetter.info/setup-zf-using-svn-externals.html#comments</comments>
		<pubDate>Tue, 19 Jan 2010 10:33:23 +0000</pubDate>
		<dc:creator>Romeo Adrian Cioaba</dc:creator>
				<category><![CDATA[subversion]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[zend framework]]></category>
		<category><![CDATA[svn:externals]]></category>
		<category><![CDATA[zf]]></category>

		<guid isPermaLink="false">http://www.myscienceisbetter.info/?p=131</guid>
		<description><![CDATA[After you create a project with zf tool, put it on SVN, you might want to include inside /library the ZF, but you want to have the bleeding edge all the time. You can include it as a svn external like this:

cd library/
svn propset svn:externals 'Zend http://framework.zend.com/svn/framework/standard/trunk/library/Zend/' .

Next time when you run svn up, your [...]]]></description>
			<content:encoded><![CDATA[<p>After you create a project with zf tool, put it on SVN, you might want to include inside /library the ZF, but you want to have the bleeding edge all the time. You can include it as a svn external like this:</p>
<pre class="brush: bash;">
cd library/
svn propset svn:externals 'Zend http://framework.zend.com/svn/framework/standard/trunk/library/Zend/' .
</pre>
<p>Next time when you run svn up, your project will fetch the latest ZF from it's repo.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.myscienceisbetter.info/setup-zf-using-svn-externals.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setup controllers and actions inside a module using zf tool</title>
		<link>http://www.myscienceisbetter.info/working-with-zf-tool-modules-controllers-and-actions.html</link>
		<comments>http://www.myscienceisbetter.info/working-with-zf-tool-modules-controllers-and-actions.html#comments</comments>
		<pubDate>Sat, 19 Dec 2009 17:19:25 +0000</pubDate>
		<dc:creator>Romeo Adrian Cioaba</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[zend framework]]></category>
		<category><![CDATA[zf modules]]></category>
		<category><![CDATA[zf tool]]></category>

		<guid isPermaLink="false">http://www.myscienceisbetter.info/?p=115</guid>
		<description><![CDATA[I've been trying to move some old code into separate modules for easier use later on. I installed zend framework and zend tool and created a new project:
zf create project myproject
Adding a new module is easy as pie:
zf create module mymodule
This creates the /application/modules/mymodule folder with complete MVC structure inside (controllers, models and views folders).
My [...]]]></description>
			<content:encoded><![CDATA[<p>I've been trying to move some old code into separate modules for easier use later on. I <a title="Install Zend Framework and Zend_Tool using PEAR on Ubuntu" href="http://www.myscienceisbetter.info/install-zend-framework-and-zend_tool-using-pear-on-ubuntu.html">installed zend framework and zend tool</a> and created a new project:</p>
<pre class="brush: bash;">zf create project myproject</pre>
<p>Adding a new module is easy as pie:</p>
<pre class="brush: bash;">zf create module mymodule</pre>
<p>This creates the /application/modules/mymodule folder with complete MVC structure inside (controllers, models and views folders).</p>
<p>My module was not working so after a bit of looking around i've found <a href="http://akrabat.com/zend-framework/bootstrapping-modules-in-zf-1-8/">Akrabat's post</a> that some light on the subject. You have to add to /application/configs.ini the following inside the [production] section:</p>
<pre class="brush: bash;">
# enabling modules
resources.frontController.moduleDirectory = APPLICATION_PATH &quot;/modules&quot;
resources.modules[] = &quot;&quot;
</pre>
<p>Good, now we should have a working module, except we don't have any controllers. Trying to create a controller proved a bit tricky as zf tool would not pleace them in the right place, inside the modules/mymodule/controllers but in the default /application/controllers. The same applies for actions. With a bit of help from TheAshMan on #zftalk i found the right answer:</p>
<pre class="brush: bash;">
# create controller Photos_IndexController at /application/modules/controllers/Photos_IndexController.php
zf create controller Photos_Index 1 mymodule
# create the action view inside the Photos_IndexController
zf create action view Photos_Index 1 mymodule
</pre>
<p>Hope this helps someone as it took me a few hours to figure it out <img src='http://www.myscienceisbetter.info/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.myscienceisbetter.info/working-with-zf-tool-modules-controllers-and-actions.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to update your Twitter status using Zend Framework</title>
		<link>http://www.myscienceisbetter.info/how-to-update-your-twitter-status-using-zend-framework.html</link>
		<comments>http://www.myscienceisbetter.info/how-to-update-your-twitter-status-using-zend-framework.html#comments</comments>
		<pubDate>Tue, 22 Sep 2009 09:30:20 +0000</pubDate>
		<dc:creator>Romeo Adrian Cioaba</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[zend framework]]></category>
		<category><![CDATA[zend_service_twitter]]></category>

		<guid isPermaLink="false">http://www.myscienceisbetter.info/?p=91</guid>
		<description><![CDATA[After reading the NetTuts tutorial on how to update your Twitter status using CodeIgniter, I wanted to show how to update your Twitter status using Zend Framework.
For this tutorial you need to install Zend Framework and Zend_Tool first.
Step 1: setup apache vhost by creating the /etc/apache2/sites-available/twitter as follows:

&#60;VirtualHost *:80&#62;

    ServerAdmin romeo.cioaba@spotonearth.com
  [...]]]></description>
			<content:encoded><![CDATA[<p>After reading the NetTuts tutorial on how to <a href="http://net.tutsplus.com/tutorials/php/how-to-update-your-twitter-status-with-codeigniter/" target="_blank">update your Twitter status using CodeIgniter</a>, I wanted to show <a title="How to update your Twitter status using Zend Framework" href="http://www.myscienceisbetter.info/how-to-update-your-twitter-status-using-zend-framework.html">how to update your Twitter status using Zend Framework</a>.</p>
<p>For this tutorial you need to <a title="Install Zend Framework and Zend_Tool using PEAR on Ubuntu" href="http://www.myscienceisbetter.info/install-zend-framework-and-zend_tool-using-pear-on-ubuntu.html">install Zend Framework and Zend_Tool</a> first.</p>
<p>Step 1: setup apache vhost by creating the /etc/apache2/sites-available/twitter as follows:</p>
<pre class="brush: bash;">
&lt;VirtualHost *:80&gt;

    ServerAdmin romeo.cioaba@spotonearth.com
    DocumentRoot /home/mimir/Zend/workspaces/DefaultWorkspace7/twitter
    ServerName twitter.dev
    ServerAlias www.twitter.dev
    ErrorLog /home/mimir/Zend/workspaces/DefaultWorkspace7/logs/twitter_error_log
    CustomLog /home/mimir/Zend/workspaces/DefaultWorkspace7/logs/twitter_access_log combined

    &lt;Directory &quot;/home/mimir/Zend/workspaces/DefaultWorkspace7/twitter/&quot;&gt;
Options Indexes FollowSymLinks
AllowOverride All
Order allow,deny
Allow from all
    &lt;/Directory&gt;

&lt;/VirtualHost&gt;
</pre>
<p>You will need to change the DocumentRoot and Directory directives to match your configuration.</p>
<p>Step 2: add twitter.dev to your hosts file:</p>
<pre class="brush: bash;">
127.0.0.1	twitter.dev www.twitter.dev
</pre>
<p>Step 3: create the Zend Framework project</p>
<pre class="brush: bash;">
# i switch to my Zend Studio workspace, where apache is reading his sites from:
# cd Zend/workspaces/DefaultWorkspace7/
zf create project twitter
</pre>
<p>Step 4: restart apache</p>
<pre class="brush: bash;">
sudo /etc/init.d/apache2 restart
</pre>
<p>At this point you should have a default Zend Framework project that you can browse at http://twitter.dev/public/. How let's change our status <img src='http://www.myscienceisbetter.info/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Replace the content of IndexController with the following:</p>
<pre class="brush: php;">
&lt;?php
class IndexController extends Zend_Controller_Action
{

    public function init()
    {
        /* Initialize action controller here */
    }

    public function indexAction()
    {
        // we create the form
        $updateForm = new Zend_Form();

        $status = new Zend_Form_Element_Text('status');
        $status-&gt;setLabel('New Twitter Status')
               -&gt;setRequired(true)
               -&gt;addFilter('StripTags')
               -&gt;addFilter('StringTrim')
               -&gt;addValidator('NotEmpty');

        $submit = new Zend_Form_Element_Submit('submit');
        $submit-&gt;setLabel('Update');

        $updateForm-&gt;addElements(array($status, $submit));

        // we send the form to the view
        $this-&gt;view-&gt;updateForm = $updateForm;

        // we check if there was any POST
        if ($this-&gt;getRequest()-&gt;isPost()){
            $formData = $this-&gt;_request-&gt;getPost();
            // checking if the form data is valid (if we have a new status or not)
            if ($this-&gt;view-&gt;updateForm-&gt;isValid($formData)){
                // our form is valid, we can update our status
                $twitterStatus = $formData['status'];

                $twitter = new Zend_Service_Twitter('myusername', 'mypassword');
                $response = $twitter-&gt;status-&gt;update($twitterStatus);
            }
        }

    }

}
</pre>
<p>Also replace the view for the index action of IndexController with:</p>
<pre class="brush: php;">

&lt;h1&gt;Welcome to the Twitter Update Tutorial&lt;/h1&gt;

&lt;?php echo $this-&gt;updateForm?&gt;
</pre>
<p>TADA! You can now check your twitter account and see that twitter status is updated every time you submit the form -:)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.myscienceisbetter.info/how-to-update-your-twitter-status-using-zend-framework.html/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Install Zend Framework and Zend_Tool using PEAR on Ubuntu</title>
		<link>http://www.myscienceisbetter.info/install-zend-framework-and-zend_tool-using-pear-on-ubuntu.html</link>
		<comments>http://www.myscienceisbetter.info/install-zend-framework-and-zend_tool-using-pear-on-ubuntu.html#comments</comments>
		<pubDate>Tue, 22 Sep 2009 08:46:57 +0000</pubDate>
		<dc:creator>Romeo Adrian Cioaba</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[ubuntu]]></category>
		<category><![CDATA[zend framework]]></category>
		<category><![CDATA[zend_tool]]></category>

		<guid isPermaLink="false">http://www.myscienceisbetter.info/?p=87</guid>
		<description><![CDATA[I work every day with Zend Framework and the easiest way i find to install it is by using the PEAR packages offered by the betta channel ZF Campus
Here is what you have to do install Zend Framework and Zend_Tool using PEAR on Ubuntu:

sudo pear channel-discover pear.zfcampus.org
sudo pear install zfcampus/zf
# for some reason the installer [...]]]></description>
			<content:encoded><![CDATA[<p>I work every day with <a title="Zend Framework" href="http://www.myscienceisbetter.info/category/zend-framework">Zend Framework</a> and the easiest way i find to install it is by using the PEAR packages offered by the betta channel <a title="ZF Campus" href="http://pear.zfcampus.org/" target="_blank">ZF Campus</a></p>
<p>Here is what you have to do install <a title="Install Zend Framework and Zend_Tool using PEAR on Ubuntu" href="http://www.myscienceisbetter.info/install-zend-framework-and-zend_tool-using-pear-on-ubuntu.html">Zend Framework and Zend_Tool using PEAR on Ubuntu</a>:</p>
<pre class="brush: bash;">
sudo pear channel-discover pear.zfcampus.org
sudo pear install zfcampus/zf
# for some reason the installer does not correctly link the zf.php and Zend_Tool won't work
# so we need to setup a symlink
sudo ln -s /usr/share/php/zf.php /usr/bin/zf.php
</pre>
<p>That's it! You can now test your install:</p>
<pre class="brush: bash;">
zf show version
</pre>
<p>In my care the output was this one:</p>
<pre class="brush: bash;">
mimir@orion:~$ zf show version
Zend Framework Version: 1.9.2
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.myscienceisbetter.info/install-zend-framework-and-zend_tool-using-pear-on-ubuntu.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Zend Framework tutorials &#8211; RFC</title>
		<link>http://www.myscienceisbetter.info/zend-framework-tutorials-rfc.html</link>
		<comments>http://www.myscienceisbetter.info/zend-framework-tutorials-rfc.html#comments</comments>
		<pubDate>Wed, 25 Mar 2009 01:13:00 +0000</pubDate>
		<dc:creator>Romeo Adrian Cioaba</dc:creator>
				<category><![CDATA[zend framework]]></category>

		<guid isPermaLink="false">http://blog.myscienceisbetter.info/?p=33</guid>
		<description><![CDATA[After a talk on #zftalk I'm thinking to start witting a site that would allow the Zend Framework community to submit learning material.
The site is going to be called Zend Framework Tips
I have a few ideas of my own, but i want to hear more from you.

Here is what i have in mind:
1. should allow [...]]]></description>
			<content:encoded><![CDATA[<p>After a talk on #zftalk I'm thinking to start witting a site that would allow the Zend Framework community to submit learning material.</p>
<p>The site is going to be called <a href="http://www.zftips.com/">Zend Framework Tips</a></p>
<p>I have a few ideas of my own, but i want to hear more from you.</p>
<p><span id="more-33"></span></p>
<p>Here is what i have in mind:<br />
1. should allow people to submit zf snippets (registred or not... in the end we're interested in getting the code outthere.. not in the username)<br />
2. people should be able to edit any code on the site and make notes on the changes<br />
3. people should be able to go to any revision of a snippet<br />
4. the site should have a screencasts section (similar to the one on aptana.tv or nettuts)</p>
<p>more to come</p>
<p>Please comment and add your ideas! What else would you like to see on a tutorial site?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.myscienceisbetter.info/zend-framework-tutorials-rfc.html/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
