<?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>Digital Base - Blog &#187; snippets</title>
	<atom:link href="http://www.digitalbase.eu/blog/tag/snippets/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.digitalbase.eu/blog</link>
	<description>A blog about webdesign, PHP, development and IT</description>
	<lastBuildDate>Mon, 10 May 2010 16:16:55 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>dbFusionChartPlugin : Simple Example</title>
		<link>http://www.digitalbase.eu/blog/dbfusionchartplugin-simple-example/</link>
		<comments>http://www.digitalbase.eu/blog/dbfusionchartplugin-simple-example/#comments</comments>
		<pubDate>Tue, 18 Mar 2008 11:00:00 +0000</pubDate>
		<dc:creator>Gijs Nelissen</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[charts]]></category>
		<category><![CDATA[dbFusionChart]]></category>
		<category><![CDATA[example]]></category>
		<category><![CDATA[graphs]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[snippets]]></category>
		<category><![CDATA[symfony]]></category>

		<guid isPermaLink="false">http://dibav3.gnelisse.desktop01/blog/?p=71</guid>
		<description><![CDATA[This first example will show you howto integrate a FusionChart graph in your symfony application, using the dbFusionChart Plugin.]]></description>
			<content:encoded><![CDATA[<p>
This first example will show you howto integrate a FusionChart (<a href="http://www.fusioncharts.com/free/" target="_blank" title="FusionCharts free">free</a>  / <a href="http://www.fusioncharts.com" target="_blank" title="FusionCharts">non-free</a> ) graph in your <a href="http://www.symfony-project.org" target="_blank" title="Symfony Project">symfony</a>  application, using the <a href="http://trac.symfony-project.com/wiki/dbFusionChartPlugin" target="_blank" title="dbFusionChartPlugin">dbFusionChartPlugin</a> . I will explain &#39;example1&#39; included in version 0.0.2 of our plugin.
</p>
<h3>The Result</h3>
<p>
Before getting to the code, here is what the final graph/chart will look like
</p>
<p>
[partial]dbFusionChartExample/example1[/partial]
</p>
<p>
&nbsp;
</p>
<h3>The Partial</h3>
<p>
The example1 is a partial that looks like this
</p>
<p>[code]dbfusionchart-example1-partial[/code]</p>
<p>
As you can see the code in this partial is pretty easy. First you tell the symfony application to load the FusionChart helper (using : use_helper). After that you load the graph/chart itself. dbfusionchart_js takes multiple arguments, the most important are the first 2.
</p>
<ul>
<li>the first argument is the type of chart (using class constants)</li>
<li>second argument is the url to the xml</li>
<li>extra arguments tell the dbFusionChart how big the chart should be (width &amp; size).</li>
</ul>
<p>
Very important in the url to the xml is that symfony knows it needs to return valid xml (an no html).
</p>
<h3>The Action</h3>
<p>
In the action.class of the dbFusionChartExample module we have the following action :
</p>
<p>
[code]dbfusionchart-example1-action[/code]
</p>
<p>
<strong><br />
Line 5 &#8211; 6</strong> tell symfony to not include the debug bar and send the response as XML (and not html)<br />
On <strong>line 8</strong> you will see the declaration of the chart. The classes are pretty smart, but the above example is a very basic example (copy pasted from FusionChart documentation).
</p>
<p>
When you are ready setting the properties of your chart (we will explain that in further posts), you tell symfony to return the xml (see <strong>line : 40</strong>).
</p>
<p>
&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.digitalbase.eu/blog/dbfusionchartplugin-simple-example/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>good linux mkdir usage</title>
		<link>http://www.digitalbase.eu/blog/good-linux-mkdir-usage/</link>
		<comments>http://www.digitalbase.eu/blog/good-linux-mkdir-usage/#comments</comments>
		<pubDate>Thu, 28 Feb 2008 11:00:00 +0000</pubDate>
		<dc:creator>Gijs Nelissen</dc:creator>
				<category><![CDATA[System Administration]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[snippets]]></category>
		<category><![CDATA[tools]]></category>

		<guid isPermaLink="false">http://dibav3.gnelisse.desktop01/blog/?p=56</guid>
		<description><![CDATA[Most people only know mkdir the simple way. I will give you some tips howto use mkdir, the "advanced" way]]></description>
			<content:encoded><![CDATA[<p>Most people only know mkdir the simple way. The simple way being<br />
[code]mkdir-simple[/code]<br />
I will give you some tips howto use mkdir, the &#8220;advanced&#8221; way.<br />
All of the above commands could be done in a single command.<br />
[code]mkdir-advanced[/code]<br />
It is alot easier to use the -p option with mkdir, and make all subdirectories with a single command. Even after you read this post, you will catch yourself using the &#8216;cd&#8217; way&#8230;<br />
try to avoid that, it will save you alot of time.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.digitalbase.eu/blog/good-linux-mkdir-usage/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
