<?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"
	>

<channel>
	<title>eingko weblog</title>
	<atom:link href="http://www.eingko.net/blog/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.eingko.net/blog</link>
	<description>a web developer's thoughts and musings</description>
	<pubDate>Sun, 13 Apr 2008 05:07:59 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5</generator>
	<language>en</language>
			<item>
		<title>Mozilla Firefox and XML Limitations</title>
		<link>http://www.eingko.net/blog/2008/04/12/mozilla-firefox-and-xml-limitations/</link>
		<comments>http://www.eingko.net/blog/2008/04/12/mozilla-firefox-and-xml-limitations/#comments</comments>
		<pubDate>Sun, 13 Apr 2008 05:00:12 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[Browsers]]></category>

		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/?p=28</guid>
		<description><![CDATA[I wish I was informed earlier of the XML limitations in Firefox.  I was racking my brain trying to figure out why my external XML entities were not working only to discover that this essential XML feature is unsupported by Firefox.
This will NOT work:

&#60;!DOCTYPE root [
&#60;!ENTITY sample SYSTEM "sample.xml"&#62;
]&#62;
&#60;root&#62;
&#38;sample;
&#60;/root&#62;

How disappointing.  I understand the [...]]]></description>
			<content:encoded><![CDATA[<p>I wish I was informed earlier of the <a href="http://www.ibm.com/developerworks/xml/library/x-ffox2/index.html#N101A0">XML limitations in Firefox</a>.  I was racking my brain trying to figure out why my external XML entities were not working only to discover that this essential XML feature is <a href="http://developer.mozilla.org/en/docs/XML_in_Mozilla#DTDs_and_Other_External_Entities">unsupported by Firefox</a>.</p>
<p>This will <strong>NOT</strong> work:<br />
<code><br />
&lt;!DOCTYPE root [<br />
&lt;!ENTITY sample SYSTEM "sample.xml"&gt;<br />
]&gt;<br />
&lt;root&gt;<br />
&amp;sample;<br />
&lt;/root&gt;<br />
</code></p>
<p>How disappointing.  I understand the rationale, but It&#8217;s unfortunate that this capability is completely unavailable.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2008/04/12/mozilla-firefox-and-xml-limitations/feed/</wfw:commentRss>
		</item>
		<item>
		<title>PHP 5.3</title>
		<link>http://www.eingko.net/blog/2008/02/16/php-53/</link>
		<comments>http://www.eingko.net/blog/2008/02/16/php-53/#comments</comments>
		<pubDate>Sat, 16 Feb 2008 22:13:55 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2008/02/16/php-53/</guid>
		<description><![CDATA[Good things are coming to PHP, and sooner than expected: http://www.sitepoint.com/article/whats-new-php-5-3
Here&#8217;s a quick list:

Namespaces
Namespace Aliases
Native MySQL Driver
Class constants
Late static binding

I can&#8217;t wait to start using this.
]]></description>
			<content:encoded><![CDATA[<p>Good things are coming to PHP, and sooner than expected: <a href="http://www.sitepoint.com/article/whats-new-php-5-3">http://www.sitepoint.com/article/whats-new-php-5-3</a></p>
<p>Here&#8217;s a quick list:</p>
<ul>
<li>Namespaces</li>
<li>Namespace Aliases</li>
<li>Native MySQL Driver</li>
<li>Class constants</li>
<li>Late static binding</li>
</ul>
<p>I can&#8217;t wait to start using this.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2008/02/16/php-53/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Prado PHP 5 Framework</title>
		<link>http://www.eingko.net/blog/2008/01/07/prado-php-5-framework/</link>
		<comments>http://www.eingko.net/blog/2008/01/07/prado-php-5-framework/#comments</comments>
		<pubDate>Tue, 08 Jan 2008 05:34:28 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2008/01/07/prado-php-5-framework/</guid>
		<description><![CDATA[I&#8217;ve been reading a lot about ASP.Net (with C#) recently. I want to learn to use ASP.Net proficiently so that I can add it to my web &#8220;toolkit&#8221; (development languages I&#8217;m familiar with).  A major downside to learning a new language is that as you consistently practice the new, it seems that you lose [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been reading a lot about <a href="http://www.asp.net/">ASP.Net</a> (with C#) recently. I want to learn to use ASP.Net proficiently so that I can add it to my web &#8220;toolkit&#8221; (development languages I&#8217;m familiar with).  A major downside to learning a new language is that as you consistently practice the new, it seems that you lose your grasp on what was once familiar - the old.</p>
<p>Fortunately, PHP and C# aren&#8217;t too different (not as dissimilar as PHP and VB anyway).  But, ASP.Net itself (regardless of which language you use with it; VB or C#) is a component and event based framework, requiring certain rules and components to tie the back-end to the front-end (generally speaking).  PHP, on the other hand, is not built this way; most PHP code is written inline.  So when switching back-and-forth between developing in ASP.Net and PHP (or any multitude of languages), there are unique approaches that are required in accomplishing the same tasks.  Obviously, this can become very confusing.</p>
<p><strong>To get to the point:</strong>  last week, I happened to come across the <a href="http://www.pradosoft.com/">Prado PHP Framework</a>.  My first thought was, &#8220;Oh, another PHP framework&#8221;, but then I took a closer look at the syntax and the page rendering model.  As I looked through the tutorials and documentation, it dawned on me that by using Prado I wouldn&#8217;t have to worry about using different approaches to server-side development.  I could use the same model with ASP.Net and with PHP.  </p>
<p>I immediately became excited at the possibilities.  How simple would it be to develop and application in one language and port it to the other?  If you&#8217;re already using the same model, all you would be switching is the &#8220;engine&#8221;.  Anyway, before I digress too much (this post is already exceedingly lengthy) and ramble forever I&#8217;ll conclude with this:  <strong>If you&#8217;re a PHP developer and interested in ASP.Net, or if you&#8217;re an ASP.Net developer interested in PHP, <a href="http://www.pradosoft.com/">Prado</a> is the way to go</strong>.  <a href="http://www.pradosoft.com/">Check it out at www.pradosoft.com</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2008/01/07/prado-php-5-framework/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Symfony Install and Setup for Windows XP with Apache 2.2</title>
		<link>http://www.eingko.net/blog/2007/12/13/symfony-install-and-setup-for-windows-xp-with-apache-22/</link>
		<comments>http://www.eingko.net/blog/2007/12/13/symfony-install-and-setup-for-windows-xp-with-apache-22/#comments</comments>
		<pubDate>Thu, 13 Dec 2007 17:25:16 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2007/12/13/symfony-install-and-setup-for-windows-xp-with-apache-22/</guid>
		<description><![CDATA[The following is a compilation of notes taken while installing and configuring Symfony for Windows XP with Apache 2.2:
The Process

Make sure that PHP is installed, then go to your PHP directory (i.e., C:\php) and double click go-pear.bat.
It will ask whether you would like to install a system-wide or local copy, type in “local” and press [...]]]></description>
			<content:encoded><![CDATA[<p>The following is a compilation of notes taken while installing and configuring Symfony for Windows XP with Apache 2.2:</p>
<h2>The Process</h2>
<ul>
<li>Make sure that PHP is installed, then go to your PHP directory (i.e., C:\php) and double click go-pear.bat.</li>
<li>It will ask whether you would like to install a system-wide or local copy, type in “local” and press enter, it will ask you to confirm, type in “yes” and press enter.</li>
<li>You should see a list displaying a suggested file layout, press enter and continue.</li>
<li>The installer will ask if you would like to “alter php.ini” type in “Y” and press enter.</li>
<li>After the installer has completed, open up a command prompt window and go to the root directory (i.e., C:\).  You can do this by typing: “cd \”.</li>
<li>From the command prompt type: “pear channel-discover pear.symfony-project.com” and press enter.  It should tell you “Discover of channel ‘pear.symfony-project.com’ succeeded”.</li>
<li>Now to install symfony, type in:</li>
</ul>
<pre class="code">Pear install symfony/symfony</pre>
<ul>
<li>You should see text that says “downloading symfony-1.0.6.tgz” and some loading progress, after the download is completed it will install symfony, and if everything goes well it will say “install ok”.</li>
<li>After the installation is complete, navigate to the directory in which you would like to initialize your first symfony project and make sure that it’s within your web root (e.g., C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\symfony).</li>
<li>When you’re in your target directory type:</li>
</ul>
<pre class="code">symfony init-project myproject</pre>
<ul>
<li>You should see a dump of assets.  When it’s complete, type in:</li>
</ul>
<pre class="code">symfony init-app myapp</pre>
<ul>
<li>After this is complete, navigate to the directory into which you initiated your symfony project (e.g., C:\Program Files\Apache Software Foundation\Apache2.2\htdocs\symfony) and verify that within the “web” directory that there is an “sf” folder, chances are that folder is nonexistent.  You’ll need to navigate to C:\php\PEAR\data\symfony\web\ (or, in my case: C:\php5\pear\data\symfony\web\) and copy the “sf” folder from there into the “web” folder within your install directory.  You should be good to go.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2007/12/13/symfony-install-and-setup-for-windows-xp-with-apache-22/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Apache 2.2, PHP 5, and MySQL 5 Install and Setup on Windows XP</title>
		<link>http://www.eingko.net/blog/2007/12/13/apache-22-php-5-and-mysql-5-install-and-setup-on-windows-xp/</link>
		<comments>http://www.eingko.net/blog/2007/12/13/apache-22-php-5-and-mysql-5-install-and-setup-on-windows-xp/#comments</comments>
		<pubDate>Thu, 13 Dec 2007 17:12:54 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2007/12/13/apache-22-php-5-and-mysql-5-install-and-setup-on-windows-xp/</guid>
		<description><![CDATA[The following is a series of notes that I compiled while installing and configuring Apache 2.2, PHP 5, and MySQL 5 on Windows XP:
Apache Installation

Download Apache HTTP Server (v2.2) from apache website or from mirror, make sure to get a binary file.
Run binary file and install Apache.

MySQL Installation

Download MySQL Server from dev.mysql.com, do NOT get [...]]]></description>
			<content:encoded><![CDATA[<p>The following is a series of notes that I compiled while installing and configuring Apache 2.2, PHP 5, and MySQL 5 on Windows XP:</p>
<h2>Apache Installation</h2>
<ul>
<li>Download Apache HTTP Server (v2.2) from apache website or from mirror, make sure to get a binary file.</li>
<li>Run binary file and install Apache.</li>
</ul>
<h2>MySQL Installation</h2>
<ul>
<li>Download MySQL Server from dev.mysql.com, do NOT get “essentials” version.</li>
<li>It may ask you to login/signup, etc.  Just click the link at the bottom: “No thanks, just take me to the downloads”.</li>
<li>Run binary and install MySQL.</li>
<li>(Optional) Check configuration box and edit configuration settings to your preference.</li>
<li>Make sure that MySQL is added to the BIN PATH.</li>
</ul>
<h2>PHP Installation</h2>
<ul>
<li>Download PHP 5, be sure to get the ZIP archive and NOT the installer.</li>
<li>Extract the archive to c:\php (or your preferred location).</li>
<li>After extraction is complete, copy php5ts.dll to C:\Windows\.  Make a copy of php.ini-recommended and rename it to “php.ini”; move this file into your C:\Windows\ folder.</li>
</ul>
<h2>Apache Configuration</h2>
<ul>
<li>Open your httpd.conf file (C:\Program Files\Apache Software Foundation\Apache2.2\conf) and find the line that looks like:</li>
</ul>
<pre class="code">DirectoryIndex index.html</pre>
<p><strong>Change to this:</strong></p>
<pre class="code">DirectoryIndex index.html index.php</pre>
<p>Feel free to add other extensions as well (e.g., index.htm, index.php5, etc.) if you wish.</p>
<ul>
<li>Find the area in the httpd.conf file that lists the loaded modules (e.g., “LoadModule foo_module modules/mod_foo.so”) and add the following line wherever you wish (i.e., at the beginning, the end, or alphabetical):</li>
</ul>
<pre class="code">LoadModule php5_module "c:/php/php5apache2_2.dll"</pre>
<p>Be sure that the path within the quotation marks points to your PHP directory and to the correct DLL file.</p>
<ul>
<li>Find the area that lists the “AddType” declarations (i.e., “AddType application/x-compress .Z” and add the following line at the bottom of that list:</li>
</ul>
<pre class="code">AddType application/x-httpd-php .php</pre>
<h2>PHP Configuration</h2>
<ul>
<li>Open up php.ini (the file you dropped into the C:\Windows\ directory). Find the line that looks like this:  “;extension=php_mysql.dll” uncomment the line by removing the semicolon.</li>
<li>Add “C:\php” to your PATH environment variable.</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2007/12/13/apache-22-php-5-and-mysql-5-install-and-setup-on-windows-xp/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Why I Love ActionScript 3.0</title>
		<link>http://www.eingko.net/blog/2007/09/26/why-i-love-actionscript-30/</link>
		<comments>http://www.eingko.net/blog/2007/09/26/why-i-love-actionscript-30/#comments</comments>
		<pubDate>Wed, 26 Sep 2007 16:55:39 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[Flash]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2007/09/26/why-i-love-actionscript-30/</guid>
		<description><![CDATA[When ActionScript 2.0 was released - and later Flash 8 - it was exciting to see the new capabilities of the Flash player.  But, the improvements of ActionScript 3.0 over ActionScript 2.0 are incredible.  When I jumped in and started playing around with ActionScript 3.0 I discovered many significant changes, all for the [...]]]></description>
			<content:encoded><![CDATA[<p>When ActionScript 2.0 was released - and later Flash 8 - it was exciting to see the new capabilities of the Flash player.  But, the improvements of ActionScript 3.0 over ActionScript 2.0 are incredible.  When I jumped in and started playing around with ActionScript 3.0 I discovered many significant changes, all for the better.  The following is a list of improvements that, for me, were exciting to see:</p>
<ul>
<li>Improved Object Oriented support (internal, public, private, and protected class types).</li>
<li>Improved event model; all events require listeners.</li>
<li>MouseEvent.MOUSE_LEAVE (detect mouse exit from stage) - enough said.</li>
<li>Performance - See <a title="PaperVision3D" target="_blank" href="http://www.papervision3d.org/">PaperVision3D</a>.</li>
<li>Improved compile-time and run-time error reporting.</li>
<li>DisplayList and MovieClip re-parenting and auto-depth management.</li>
<li>int and uint Classes for non-floated numbers.</li>
<li>XML is a built-in datatype</li>
<li>Intervals replaced with Timers</li>
<li>Built in &#8220;drawCircle&#8221; (or &#8220;drawOval&#8221;) method added for run-time elliptical shape-generation.</li>
</ul>
<p>There&#8217;s a lot more as well, but these are just a few improvements that I was very pleased to see.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2007/09/26/why-i-love-actionscript-30/feed/</wfw:commentRss>
		</item>
		<item>
		<title>PHP SQLite</title>
		<link>http://www.eingko.net/blog/2007/07/03/php-sqlite/</link>
		<comments>http://www.eingko.net/blog/2007/07/03/php-sqlite/#comments</comments>
		<pubDate>Wed, 04 Jul 2007 04:56:43 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2007/07/03/php-sqlite/</guid>
		<description><![CDATA[I just thought that I would post this because I ran into this issue earlier today.  If you&#8217;re wanting to enable SQLite in PHP you&#8217;ll have to edit your php.ini file and uncomment the line (removing the initial semicolon) that looks like this:
;extension=php_sqlite.dll
And the line that looks like this:
;extension=php_pdo.dll
Basically, SQLite requires the PDO module [...]]]></description>
			<content:encoded><![CDATA[<p>I just thought that I would post this because I ran into this issue earlier today.  If you&#8217;re wanting to enable SQLite in PHP you&#8217;ll have to edit your php.ini file and uncomment the line (removing the initial semicolon) that looks like this:</p>
<pre class="code">;extension=php_sqlite.dll</pre>
<p>And the line that looks like this:</p>
<pre class="code">;extension=php_pdo.dll</pre>
<p>Basically, SQLite requires the PDO module to be loaded in order for it to work.  This may seem an obvious solution to some (albeit somewhat awkward), but it caused me some annoyance.  Anyway, hope that helps someone out.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2007/07/03/php-sqlite/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Partigen</title>
		<link>http://www.eingko.net/blog/2007/07/02/partigen/</link>
		<comments>http://www.eingko.net/blog/2007/07/02/partigen/#comments</comments>
		<pubDate>Tue, 03 Jul 2007 02:59:31 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[Flash]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2007/07/02/partigen/</guid>
		<description><![CDATA[I&#8217;m really excited about the upcoming release of Partigen, check it out here: http://www.desuade.com/.
]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m really excited about the upcoming release of Partigen, check it out here: <a title="Desuade.com" href="http://www.desuade.com/">http://www.desuade.com/</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2007/07/02/partigen/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Setting Up the Symfony Framework on MediaTemple&#8217;s Grid Server</title>
		<link>http://www.eingko.net/blog/2007/06/20/setting-up-the-symfony-framework-on-mediatemples-grid-server/</link>
		<comments>http://www.eingko.net/blog/2007/06/20/setting-up-the-symfony-framework-on-mediatemples-grid-server/#comments</comments>
		<pubDate>Thu, 21 Jun 2007 07:06:58 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[Et Cetera]]></category>

		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2007/06/20/setting-up-the-symfony-framework-on-mediatemples-grid-server/</guid>
		<description><![CDATA[Introduction and Disclaimer
Before I begin I should probably mention that this will take quite a bit of time, potentially up to an hour or more; so make sure you set aside enough time to do this.  Also, I&#8217;d like to point out that Media Temple has an excellent tutorial and the official documentation may [...]]]></description>
			<content:encoded><![CDATA[<h3>Introduction and Disclaimer</h3>
<p>Before I begin I should probably mention that this will take quite a bit of time, potentially up to an hour or more; so make sure you set aside enough time to do this.  Also, I&#8217;d like to point out that <a title="Media Temple" target="_blank" href="http://kb.mediatemple.net/article.php?id=237">Media Temple has an excellent tutorial</a> and the official documentation may be found on the <a title="Symfony Project" target="_blank" href="http://www.symfony-project.com/content/download.html">Symfony website</a>.</p>
<p>A lot of this information can be found elsewhere on the internet, but I haven&#8217;t really seen a complete/concise walkthrough on setting up and configuring <a target="_blank" title="Symfony" href="http://www.symfony-project.com/">Symfony</a> to work with <a target="_blank" title="Media Temple" href="http://www.mediatemple.net/">MediaTemple</a>&#8217;s Grid Server, so I&#8217;m writing my own.  The following instructions are written from the perspective of a Windows PC user, but - for the most part - everything should be pretty much the same on OSX or Linux. Keep in mind that you should only do this if you know what you&#8217;re doing.  You could potentially mess up your web server if you&#8217;re not careful; also keep in mind that these instructions may not apply to all server configurations.  Don&#8217;t blame me if you end up screwing up your server.</p>
<h3>First and Foremost</h3>
<h4>PHP 5</h4>
<p>Before you can even get started you have to make sure that your server is configured properly.  Make sure that the <em>Primary PHP Version</em> is set to PHP 5.  You can do this by selecting your target domain from the domains tab, then click on <strong>PHP Settings</strong> and select PHP 5 and press save at the bottom.</p>
<h4>SSH Access</h4>
<p>The next thing you need to make sure to do is enabled SSH access to your MediaTemple account.  Still on the control panel page press the Server Administrator button/cell and make sure that under the <em>SSH Option</em> section that you select <strong>enabled</strong>. Save your settings.</p>
<p>Server Number:  You&#8217;ll need to know your MediaTemple server number.  In order to find out what your server number is, go the the Account Center control panel and click on the Server Guide button/cell.  On the next page click the &#8220;System Paths&#8221; link in the third column.  You should see a page that lists all of your server paths, environment variables, etc.  You should see a line titled <strong>System path</strong> with a value of something like: &#8220;home/####/domains/yoursite.com&#8221; write down the number that comes after &#8220;home/&#8221; and before &#8220;/domains&#8221;; that&#8217;s your server number, it could be four or five digits (maybe more).</p>
<h4>SSH Client</h4>
<p>Now that you SSH access you&#8217;ll need a client to utilize its power.  Mac users should have already have a client pre-installed on their OS (Applications>Utilities>Terminal).  Unix/linux users should already know how to do this.  For Windows users, I recommend using <a title="Putty" target="_blank" href="http://www.putty.nl/">Putty</a>; but if you have a preferred client feel free to use it. You can download the Putty client at http://www.putty.nl/download.html.  Select the version that applies to your version of Windows (select the putty.exe file, not one of the other options).  Whenever the Putty client finishes downloading, put the .exe file into your Windows folder (most likely C:\Windows); create a shortcut (right-click > &#8220;create shortcut&#8221;) and drag the shortcut to your desktop, start menu, wherever you want it.</p>
<h3>Connecting to the Server</h3>
<h4>Connecting</h4>
<p>Launch Putty (or your SSH client) from your shortcut, put your website hostname (www.example.com) or IP address into the hostname field - make sure the SSH option is selected and that the port number is correct - then click &#8220;open&#8221; on the bottom.  If you haven&#8217;t connected to your server with the SSH client before you&#8217;ll get a &#8220;The server&#8217;s host key is not cached in the registry&#8221; alert. Click &#8220;Yes&#8221; to continue.</p>
<h4>Logging In</h4>
<p>Put in your username (it should be serveradmin@yoursite.com), press enter, then type in your password and press enter.  If after logging in the client immediately closes or you get a &#8220;Connection closed by remote host&#8221; alert, it&#8217;s because you didn&#8217;t set your &#8220;SSH option&#8221; to <strong>enabled</strong> in the MediaTemple Account Center or you forgot to save your settings after you did so.  If this happens to you, change your settings and try logging in again.  After logging in successfully you should see a prompt with something like (except the *asterisks* will be an alphanumeric combination):</p>
<pre class="code">yoursite.com@****:~$</pre>
<h3>Installing Custom Pear Packages</h3>
<p>Fortunately Pear comes as a global pre-install with MediaTemple&#8217;s Grid Servers, so that saves us a step (kind of); but because we&#8217;re adding a custom package/module we need to manually create an install copy in the server&#8217;s home directory.</p>
<h4>Pear Install</h4>
<p>Before we install/copy Pear we need to create a configuration file.  Make sure that you&#8217;re still logged in with your SSH client (log in again if you&#8217;re not) and generate a configuration file for your home directory by typing in the following:</p>
<pre class="code">/usr/local/pear/bin/pear config-create $PWD .pearrc</pre>
<p>Double check your spelling.  If you did everything correctly you should see a list of files scroll past and the last line of text should read &#8220;Successfully created default configuration file&#8221;, etc.  Now you&#8217;ll need to run the install:</p>
<pre class="code">/usr/local/pear/bin/pear install -o PEAR</pre>
<p>Be sure to double check everything and make sure you don&#8217;t misspell anything.  If you typed in everything correctly you&#8217;ll see a series of lines scroll past with things like &#8220;Downloading Console_Getopt&#8221;, &#8220;Downloading Structures_Graph&#8221;, etc. and then a few lines that say &#8220;install ok: channel://pear.php.net&#8221; and so on.</p>
<h4>Bash Profile</h4>
<p>So that you don&#8217;t have to type the full path to Pear in every time we&#8217;ll create a .bash_profile in order to make things more efficient. Check to see if a .bash_profile file already exists (chances are it doesn&#8217;t) by typing in the following:</p>
<pre class="code">ls -a</pre>
<p>If you have a .bash_profile file in there already, fine, if you don&#8217;t also fine. You can do this next part one of two ways; you can use the Vi editor, or you can &#8220;concatenate&#8221; or &#8220;echo&#8221; the text directly into the file.  If .bash_profile already exists you should use the Vi editor to make sure you&#8217;re not adding something that&#8217;s already there.</p>
<h3>Vi Editor Method</h3>
<p>Launch the Vi editor within your SSH client by typing in:</p>
<pre class="code">vi .bash_profile</pre>
<p>This should &#8220;clear&#8221; the screen except for a line at the bottom that says something like:</p>
<pre class="code">".bash_profile" [New File]</pre>
<p>The Vi editor defaults to &#8220;Command Mode&#8221;, be sure to press &#8220;i&#8221; on your keyboard to switch to &#8220;INSERT&#8221; mode.  You&#8217;ll be able to tell because the bottom line changes to &#8220;&#8211; INSERT &#8211;&#8221;.  Now type:</p>
<pre class="code">export PATH=$PATH:/home/####/users/.home/pear/</pre>
<p>Be sure to replace the #### symbols with the server number you wrote down earlier.  Double check your spelling and press the Escape (ESC) key on your keyboard, this will put you back in &#8220;Command Mode&#8221;.  Hold down the Shift key (SHIFT) on your keyboard and press &#8220;ZZ&#8221; (make sure you press &#8220;Z&#8221; twice); again: &#8220;SHIFT+ZZ&#8221;.  If you did everything correctly it should take you back to the shell prompt.</p>
<p>Go ahead and make sure that the file is there by displaying a directory listing:</p>
<pre class="code">ls -a</pre>
<p>It should look just like it did earlier except now there&#8217;s a &#8220;.bash_profile&#8221; file in there.</p>
<h3>Concatenation Method</h3>
<p>If the .bash_profile file doesn&#8217;t exist in the current directory, at the SSH prompt type in:</p>
<pre class="code">touch .bash_profile</pre>
<p>Press Enter. This will create a .bash_profile file for you. Next type in the following:</p>
<pre class="code">echo export 'PATH=$PATH:/home/####/users/.home/pear/' >> ~/.bash_profile</pre>
<p>You can make sure that everything worked by typing in:</p>
<pre class="code">cat ~/.bash_profile</pre>
<p>If you did everything properly it should basically just echo back the contents of the file.</p>
<h3>Verifying the Profile</h3>
<p>Now you can install Pear packages without having to type in the full path.  Let&#8217;s run a test by installing/updating the mail package:</p>
<pre class="code">pear install -o Mail</pre>
<p>It should scroll a few lines saying &#8220;Downloading&#8221;, etc. and end with &#8220;install ok: channel://pear.php.net&#8221; and so on, just like when we copied/installed Pear to the home directory.</p>
<h3>Editing the PHP.INI File</h3>
<p>If you&#8217;re not logged into the MediaTemple Account Center anymore, be sure to log back in for this next segment.  From the Account Center control panel click on the &#8220;File Manager&#8221; button/cell.  On that page, click into the &#8220;etc&#8221; folder.  Once inside the &#8220;etc&#8221; folder you should see a file titled &#8220;php.ini.sample&#8221;, click it to open it and edit it.  By the way, I would recommend that you copy everything that&#8217;s in that text box and make a backup somewhere on your computer, just in case you accidentally mess something up and have to go back to the default settings.</p>
<p>Scroll down to the very bottom and add the following line:</p>
<pre class="code">include_path = ".:/home/####/users/.home/pear/php"</pre>
<p>Be sure to change the #### to your server number.  If you want, feel free to add a comment (start the line with a semi-colon &#8220;;&#8221;) that says something like &#8220;pear include path&#8221;.  Finally, change &#8220;php.ini.sample&#8221; to php.ini&#8221;.  If you don&#8217;t do this, your settings won&#8217;t take effect.  Click &#8220;save changes&#8221; to save the file.<br />
Some users may  prefer to change the include path on a directory-by-directory basis via an .htaccess file or  on a script-by-script (.php file) basis but I wouldn&#8217;t recommend it unless you know what you&#8217;re doing.  If you made the changes to your php.ini file as instructed above go ahead and skip to the next section, otherwise - if you&#8217;re wanting to go about it a different way - read the next few of paragraphs.<br />
If you want to do it via .htaccess files (keep in mind this only affects .php files within that directory) add the following line to the .htaccess file in your target directory (remember to change the #### values to your server number):</p>
<pre class="code">php_value include_path /home/####/users/.home/pear/php'</pre>
<p>If you&#8217;re wanting to change your include directive on a script-by-script basis, add the following somewhere near the top (probably before any &#8216;include&#8217; commands):</p>
<pre class="code">set_include_path('/home/####/users/.home/pear/php');</pre>
<p>Be sure - this is getting redundant, I know - to change the #### values to your server number.</p>
<h3>Preparing to Install Symfony</h3>
<p>Okay, we&#8217;re about half way done (I told you this would take a while).  By the time you&#8217;ve gone through all of this your SSH client has probably timed out and aborted the connection, if this is case go ahead and log back in.  If your client has not timed out type in &#8220;clear&#8221; and press enter to clear the screen (if you had to log back in, go ahead and do this as well).</p>
<p>You&#8217;ll have to make sure that the command-prompt is running as PHP5, to do this you&#8217;ll have to update your .bash_profile file again.  There are two methods to doing this, as mentioned before.  In this instance, I&#8217;m going to use the concatenation method:</p>
<pre class="code">echo export 'PATH=/usr/local/php5/bin:$PATH:/home/####/users/.home/pear'  >> ~/.bash_profile</pre>
<p class="alert">WARNING:  Make sure not to insert a carriage return or line break when entering the above two lines.  The code above is merely wrapping.</p>
<p>Type that into your SSH client and make sure to replace the #### with your server number.  Double check that everything is typed correctly, it&#8217;s a pretty lengthy line.</p>
<p>If you&#8217;re wanting to use Vi to input that, it&#8217;s the same except you don&#8217;t need to type &#8220;echo&#8221; or the &#8220;>> ~/.bash_profile&#8221;, nor do you need to put single quotes around the path.<br />
To make sure that everything worked correctly type:</p>
<pre class="code">cat ~/.bash_profile</pre>
<p>If you typed everything in correctly, it should echo the contents of .bash_profile out to you.  The last line is the part that you just added.</p>
<p>Before we move on, you&#8217;ll need to refresh the shell environment variables, type:</p>
<pre class="code">source ~/.bash_profile</pre>
<h3>Installing Symfony</h3>
<h4>Discovery</h4>
<p>Before installing Symfony you have to &#8220;discover&#8221; it through pear, type in:</p>
<pre class="code">pear channel-discover pear.symfony-project.com</pre>
<p>After a slight pause, you should see a couple of lines that say: &#8220;Adding Channel pear.symfony-project.com succeeded&#8221; and &#8220;Discovery of channel pear.symfony-project.com succeeded&#8221;. Now with the next part you can either choose to install the latest stable release of Symfony or the &#8220;nightly builds&#8221; (beta releases); I recommend using the stable release.</p>
<p>For the stable release (recommended), type:</p>
<pre class="code">pear install symfony/symfony</pre>
<p>For the &#8220;nightly build&#8221;:</p>
<pre class="code">pear install symfony/symfony-beta</pre>
<p>You should see some text that says &#8220;starting to download symfony&#8221; then a progressing load, and finally, &#8220;install ok: channel://pear.symfony-project.com&#8221;.</p>
<p>This next part can be a little tricky so follow along closely.</p>
<h3>Initializing a Symfony Project</h3>
<p>After completing the previous section, Symfony is officially installed on your server; but, before you can use it you have to initialize a project and an application.  The following steps will walk you through setting up a &#8220;symfony&#8221; subdomain which you can use to play with your Symfony installation.  If you don&#8217;t want to create a subdomain you don&#8217;t have to.</p>
<p>To create a subdomain type:</p>
<pre class="code">mkdir ~/domains/symfony.yoursite.com</pre>
<p>Obviously change &#8220;yoursite.com&#8221; to whatever your site may be (&#8221;example.com&#8221;, &#8220;mysite.net&#8221;, etc.).  Next create a &#8220;symfony&#8221; directory:</p>
<pre class="code">mkdir ~/domains/symfony.yoursite.com/symfony</pre>
<p>If you didn&#8217;t create a subdomain replace &#8220;symfony.yoursite.com&#8221; with simply &#8220;yoursite.com&#8221;.  Now within the &#8220;symfony&#8221; directory create a directory called &#8220;web&#8221;:</p>
<pre class="code">mkdir ~/domains/symfony.yoursite.com/symfony/web</pre>
<p>The reason we created these two directories is so that we can establish a symbolic link &#8220;SymLink&#8221; from the newly created &#8220;web&#8221; folder to the root &#8220;html&#8221; folder.  Type in the following (be absolutely sure to type this in correctly):</p>
<pre class="code">cd ~/domains/symfony.yoursite.com/
ln -s symfony/web html</pre>
<p>Again, if you didn&#8217;t create a subdomain instead of &#8220;symfony.yoursite.com&#8221; it will be just &#8220;yoursite.com&#8221;.  The reason this is necessary is because Symfony&#8217;s default folder structure is different from MediaTemple&#8217;s structure, so we have to create a &#8220;SymLink&#8221; that will basically redirect the framework to the required files.</p>
<p>You may have noticed that after typing &#8220;cd ~/domains/symfony.domain.com/&#8221; that the prompt changed; that&#8217;s because you&#8217;ve moved into another directory, which is what is supposed to happen.  Now that that&#8217;s done we need to actually &#8220;initialize&#8221; our Symfony project.  Make sure that the prompt displays (note the word &#8220;symfony&#8221; at the end):</p>
<pre class="code">yoursite.com@****:~/domains/symfony.yoursite.com/symfony$</pre>
<p>If it doesn&#8217;t type (if you didn&#8217;t create a subdomain - &#8220;yoursite.com&#8221; instead of &#8220;symfony.yoursite.com&#8221;):</p>
<pre class="code">cd ~/domains/symfony.yoursite.com/symfony</pre>
<p>Now, at the SSH shell type:</p>
<pre class="code">symfony init-project myproject</pre>
<p>Feel free to change &#8220;myproject&#8221; to whatever you want (e.g., &#8220;test&#8221;, &#8220;demo&#8221;, &#8220;default&#8221;, etc.).  You should see a series of lines scroll by, if you typed everything correctly.  Now type in the following:</p>
<pre class="code">symfony init-app myapp</pre>
<p>Again, feel free to change &#8220;myapp&#8221; to whatever you wish, just make sure to be consistent.</p>
<p>If you&#8217;ve created a subdomain you have to make sure to add an .htaccess file in your &#8220;symfony/web&#8221; directory that adds a php5 script handler.  To do this just type:</p>
<pre class="code">echo 'Options +FollowSymLinks +ExecCGI' >> ~/domains/symfony.yoursite.com/symfony/web/.htaccess
echo 'AddHandler php5-script .php' >> ~/domains/symfony.yoursite.com/symfony/web/.htaccess</pre>
<p class="alert">WARNING:  Make sure not to insert a carriage return or line break when entering the above two lines.  The code above is merely wrapping.</p>
<p>Be sure to type this accurately (note the spaces and periods carefully) otherwise you&#8217;ll get a &#8220;500 Internal Server Error&#8221;.  Again, if you prefer to use Vi to add those two lines to the end, it&#8217;s up to you.<br />
Now go and test your work: symfony.yoursite.com (or just yoursite.com if you didn&#8217;t create the subdomain).</p>
<h3>Where Are the Media Files?</h3>
<p>If for some reason you&#8217;re not seeing the stylesheet, images, etc.  It&#8217;s because the &#8220;sf&#8221; files didn&#8217;t get copied over, I&#8217;m not sure why this happens, but there&#8217;s an easy fix.  In your SSH shell type:</p>
<pre class="code">cp -r ~/pear/data/symfony/web/sf ~/domains/symfony.yoursite.com/symfony/web/sf</pre>
<p class="alert">WARNING:  Make sure not to insert a carriage return or line break when entering the above two lines.  The code above is merely wrapping.</p>
<p>Be sure to type all of that in carefully.  Also if you didn&#8217;t create a subdomain change &#8220;symfony.yoursite.com&#8221; to simply &#8220;yoursite.com&#8221;.</p>
<p>Now go and test your work: symfony.yoursite.com (or just yoursite.com if you didn&#8217;t create the subdomain).  Everything should be up and running smoothly.  Congratulations, you&#8217;re finished.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2007/06/20/setting-up-the-symfony-framework-on-mediatemples-grid-server/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Official Computer Geek</title>
		<link>http://www.eingko.net/blog/2007/06/18/official-computer-geek/</link>
		<comments>http://www.eingko.net/blog/2007/06/18/official-computer-geek/#comments</comments>
		<pubDate>Mon, 18 Jun 2007 19:29:12 +0000</pubDate>
		<dc:creator>eingko</dc:creator>
		
		<category><![CDATA[C/C++]]></category>

		<category><![CDATA[Et Cetera]]></category>

		<guid isPermaLink="false">http://www.eingko.net/blog/2007/06/18/official-computer-geek/</guid>
		<description><![CDATA[I&#8217;m not entirely sure what it takes to be considered a &#8220;Computer Geek&#8221; or &#8220;Computer Nerd&#8221; (whichever/whatever), but I think I may have crossed that line.  I was reading &#8220;C for Dummies&#8221; by Dan Gookin and around page 210 he mentioned the origin of the name &#8220;C++&#8221; (check it out on Wikipedia), and I [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m not entirely sure what it takes to be considered a &#8220;Computer Geek&#8221; or &#8220;Computer Nerd&#8221; (whichever/whatever), but I think I may have crossed that line.  I was reading <a rel="external" href="http://www.amazon.com/C-Dummies-2nd-Dan-Gookin/dp/0764570684/ref=pd_bbs_sr_1/102-7323323-9268954?ie=UTF8&#038;s=books&#038;qid=1182194601&#038;sr=8-1">&#8220;C for Dummies&#8221; by Dan Gookin</a> and around page 210 he mentioned the origin of the name &#8220;C++&#8221; (check it out on <a rel="external" href="http://en.wikipedia.org/wiki/C++#The_name_.22C.2B.2B.22">Wikipedia</a>), and I found it to be quite funny.  Originally it was called &#8220;C with classes&#8221;, but <a rel="external" href="http://en.wikipedia.org/wiki/Rick_Mascitti">Rick Mascitti</a> referred to it as &#8220;C++&#8221; as a sort of tongue-in-cheek reference to the incremental postfix operator (as in loops; e.g., i++).</p>
<p class="cplus">c = c + 1;</p>
<p>or</p>
<p class="cplus">c++;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.eingko.net/blog/2007/06/18/official-computer-geek/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
