<?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>Internet Business Resources</title>
	<atom:link href="http://www.ibresources.com/feed" rel="self" type="application/rss+xml" />
	<link>http://www.ibresources.com</link>
	<description></description>
	<lastBuildDate>Sat, 30 Jul 2011 09:10:23 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Tutorial: Using Propel with DooPHP</title>
		<link>http://www.ibresources.com/technical/programming/using-propel-with-doophp-tutorial</link>
		<comments>http://www.ibresources.com/technical/programming/using-propel-with-doophp-tutorial#comments</comments>
		<pubDate>Sat, 30 Jul 2011 08:50:29 +0000</pubDate>
		<dc:creator>Internet Business Resources</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[doophp]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[propel]]></category>

		<guid isPermaLink="false">http://www.ibresources.com/?p=59</guid>
		<description><![CDATA[This is a tutorial on how to integrate Propel with DooPHP, giving you the power of an extremely fast and easy to use PHP MVC framework together with a powerful ORM. You will discover how easy it is to integrate a third-party ORM library with DooPHP, and you should be able to use this as <a href='http://www.ibresources.com/technical/programming/using-propel-with-doophp-tutorial'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>This is a tutorial on how to integrate Propel with DooPHP, giving you the power of an extremely fast and easy to use PHP MVC framework together with a powerful ORM.</p>
<p>You will discover how easy it is to integrate a third-party ORM library with DooPHP, and you should be able to use this as a model to integrate other libraries with your DooPHP project.</p>
<p><strong>Step 1 &#8211; Directory structure</strong></p>
<p>In DooPHP, all code should go into a &#8216;protected&#8217; directory. This can be held within or outside your normal web path. I normally create it within my web path but protect the directory through .htaccess or Nginx configuration.</p>
<p>Next, you create a directory called protected/orm &#8211; all your Propel configuration goes in there.</p>
<p><strong>Step 2 &#8211; build.properties</strong></p>
<p>You will need to define a build.properties file in the orm directory. I presume you know how to create Propel configuration and schema files as this tutorial only concentrates on making Propel work with DooPHP.</p>
<p>The important parts of build.properties for this tutorial are as follows:</p>
<p><code>propel.project = my_propel_project<br />
propel.output.dir = ${propel.project.dir}/../model/propel<br />
propel.php.dir = ${propel.output.dir}/classes<br />
propel.phpconf.dir = ${propel.output.dir}/conf<br />
propel.sql.dir = ${propel.project.dir}/sql</code></p>
<p>This will ensure the classes themselves go into a directory calles protected/model/propel so you can easily keep them apart from your own DooPHP models, whilst the generated SQL goes into protected/orm/sql. </p>
<p><strong>Step 3 &#8211; Set default Propel configuration options</strong></p>
<p>Define the path to Propel runtime as well as the name of the project in your protected/config/common.conf.php file:</p>
<pre class="brush: php; title: ; notranslate">$config['propel_path'] = $config['SITE_PATH'] . 'protected/class/propel-runtime-1.6/';
$config['propel_default_project'] = 'my_propel_project';</pre>
<p>I store the Propel runtime with each individual project, in the class directory with all my other classes &#8211; but just in case I want it stored elsewhere the path is defined above.</p>
<p>Where does the Propel Default Project name come from? It&#8217;s taken from the &#8220;propel.project = my_propel_project&#8221; configuration in build.properties in Step 2 above.</p>
<p><strong>Step 4 &#8211; Create a Propel loader class</strong></p>
<p>Store this as <strong>protected/class/InitPropel.php</strong>:</p>
<pre class="brush: php; title: ; notranslate">&lt;?php
/*
 * Copyright (C) 2011 I B Resources. All rights reserved.
 * Released for use in any personal or commercial project.
 * No attribution required, but link to
 * http://www.ibresources.com/ would be appreciated.
 */

// Include the main Propel script
require_once(Doo::conf()-&gt;propel_path . 'Propel.php');

class InitPropel {

  static $_propelLoaded = false;

  /**
   *
   * Initialise Propel
   *
   * Format:
   *   InitPropel::init();
   *
   * @static
   * @return bool
   */
  static public function init($dataSource = null) {

    if (self::$_propelLoaded) {
      return false;
    }

    if (!Propel::isInit()) {
      // Initialize Propel with the runtime configuration
      Propel::init(Doo::conf()-&gt;SITE_PATH . &quot;protected/model/propel/conf/{$dataSource}-conf.php&quot;);
      set_include_path(Doo::conf()-&gt;SITE_PATH . &quot;protected/model/propel/classes/&quot; . PATH_SEPARATOR . get_include_path());
    }
    self::$_propelLoaded = true;
    return true;
  }

}

InitPropel::init(Doo::conf()-&gt;propel_default_project);</pre>
<p><strong>Step 5 &#8211; Call it in your code</strong></p>
<p>Using Propel now becomes very easy. Just call the class in your controller:</p>
<pre class="brush: php; title: ; notranslate">class AdminController {

  public function listUsers() {
    Doo::loadClass('InitPropel');

    // Next bit assumes you have a 'user' table definition, of course!
    $users = UserQuery::create()
               -&gt;find();
  }

}</pre>
<p>You can also load the class in <strong>beforeRun</strong> so you don&#8217;t have to call it in every function in your controller.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ibresources.com/technical/programming/using-propel-with-doophp-tutorial/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fastest Webserver Performance</title>
		<link>http://www.ibresources.com/technical/fastest-webserver-performance</link>
		<comments>http://www.ibresources.com/technical/fastest-webserver-performance#comments</comments>
		<pubDate>Sun, 24 Jul 2011 14:20:25 +0000</pubDate>
		<dc:creator>Internet Business Resources</dc:creator>
				<category><![CDATA[Technical]]></category>
		<category><![CDATA[apc]]></category>
		<category><![CDATA[nginx]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[php-fpm]]></category>
		<category><![CDATA[varnish]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.ibresources.com/?p=44</guid>
		<description><![CDATA[Ok, this article is for those who run their own server, whether it&#8217;s a Virtual Private Server or a dedicated server. There&#8217;s lots of articles available on how to set up each of these, but I thought for now I&#8217;ll just make a statement on what the best server setup is, then I&#8217;ll expand on <a href='http://www.ibresources.com/technical/fastest-webserver-performance'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>Ok, this article is for those who run their own server, whether it&#8217;s a Virtual Private Server or a dedicated server.</p>
<p>There&#8217;s lots of articles available on how to set up each of these, but I thought for now I&#8217;ll just make a statement on what the best server setup is, then I&#8217;ll expand on my own setup in later articles.</p>
<p><img src="http://www.ibresources.com/wp-content/uploads/2011/07/nginx-logo1-e1311518184400.png" alt="" title="Nginx Logo" width="200" height="51" class="alignright size-full wp-image-48" />Webserver: <a href="http://wiki.nginx.org/">Nginx</a> &#8211; incredibly fast, simply blows Apache out of the water.</p>
<p>PHP: v5.3.6 in <a href="http://php.net/">PHP-FPM</a> mode, with APC.</p>
<p>Front-End Cache: <a href="https://www.varnish-cache.org/">Varnish</a> &#8211; will speed up serving your website incredibly, which will help the visitor experience and help boost your search engine ranking.</p>
<p>CMS: <a href="http://wordpress.org/">WordPress</a> &#8211; yes, that old favourite. Make sure you use the plugin W3 Total Cache which can also refresh  Varnish for you.</p>
<p>Ok, that was just a quick list. Later there will be a short tutorial explaining the setup of these.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ibresources.com/technical/fastest-webserver-performance/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Flexible &amp; Powerful WordPress Theme</title>
		<link>http://www.ibresources.com/website/flexible-powerful-wordpress-theme</link>
		<comments>http://www.ibresources.com/website/flexible-powerful-wordpress-theme#comments</comments>
		<pubDate>Sun, 24 Jul 2011 13:13:09 +0000</pubDate>
		<dc:creator>Internet Business Resources</dc:creator>
				<category><![CDATA[Website]]></category>
		<category><![CDATA[theme]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">http://www.ibresources.com/?p=34</guid>
		<description><![CDATA[I think it&#8217;s only appropriate that I kick off with the first post about the WordPress theme I am using. Yes, it might change later &#8211; but for a start-up blog it&#8217;s pretty awesome. It&#8217;s the Suffusion WordPress Theme. When you create a WordPress site, it&#8217;s important to get a proper theme up, or something <a href='http://www.ibresources.com/website/flexible-powerful-wordpress-theme'>[...]</a>]]></description>
			<content:encoded><![CDATA[<p>I think it&#8217;s only appropriate that I kick off with the first post about the WordPress theme I am using. Yes, it might change later &#8211; but for a start-up blog it&#8217;s pretty awesome.</p>
<p>It&#8217;s the <a href="http://aquoid.com/news/themes/suffusion/">Suffusion WordPress Theme</a>.</p>
<p>When you create a WordPress site, it&#8217;s important to get a proper theme up, or something you can get started with but gives you lots of flexibility later.</p>
<p>I looked at Thesis, Genesis and Headway &#8211; and they are all great. But, of course, they cost a bit of money.</p>
<p><img class="alignright size-medium wp-image-35" title="Suffusion Widgets" src="http://www.ibresources.com/wp-content/uploads/2011/07/widgets1-256x300.jpg" alt="" width="256" height="300" />No, don&#8217;t misunderstand me. If you got cash to splash, I&#8217;d recommend either Thesis or Genesis as they are both great themes, and give you a lot of flexibility. But you should also consider the <a href="http://aquoid.com/news/themes/suffusion/">Suffusion WordPress Theme</a>. If you&#8217;re a novice it might not be suitable, as it&#8217;s very, very flexible and have a LOT of options. The author even shows, in big letters, &#8220;DON&#8217;T PANIC&#8221; on the theme settings page.</p>
<p>But if you have any clue about WordPress and have looked into themes in the past, you could do a lot worse than giving some thoughts to using Suffusion on your site.</p>
<p>It has a few very useful Social Media widgets, comes with 17 pre-defined color schemes, has lots of different page layouts and generally does everything you&#8217;ll need. It has more predefined widgets areas than you can fill with widgets, just take a look at the graphic on the right!</p>
<p>Best of all? It&#8217;s 100% free, and can be downloaded directly from the WordPress site using the Theme Manager within WordPress itself.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.ibresources.com/website/flexible-powerful-wordpress-theme/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

