<?xml version="1.0" encoding="ISO-8859-1" ?>
<rss version="2.0">
<channel>
	<title>Articles</title>
	<link>http://www.realcustomscripts.com/page/articles/category/development/php/</link>
	<pubDate>Wed, 22 Feb 2012 18:37:21 +0000</pubDate>
	<ttl>43200</ttl>
	<description>PHP Articles and examples</description>
	<item>
		<title>PHP Currency Formatting</title>
		<link>http://www.realcustomscripts.com/page/articles/category/development/php/php-currency-formatting-r14</link>
		<description><![CDATA[When I was creating my marketplace & advertising system, I had to quickly format the currency used instead of adding things manually<br />
so I created that function.<br />
It might not be very useful for everyone but, it came handy for me !<br />
<br />
<span style='color: #2E8B57'><a href='http://realcustomscripts.com/learn/php/php-currency-format' class='bbc_url' title='External link' rel='external'>See Full Function here</a></span><br />
<br />
The functions is very simple and support multi data returns <br />
<br />
Single Currency format:<br />
<pre class='prettyprint'>
$cur = "GBP";
$curStuff =  getCurFormated($cur);
   echo "&lt;h2&gt; Single output&lt;/h2&gt;";
   echo "Currency Code: $curStuff&#91;0&#93;&lt;br&gt;
         Currency Sign: $curStuff&#91;1&#93;&lt;br&gt;
         Currency Title: $curStuff&#91;2&#93;&lt;br&gt;
</pre><br />
<br />
The output<br />
<p class='citation'>Quote</p><div class="blockquote"><div class='quote'>
<strong class='bbc'>Single output</strong><br />
<strong class='bbc'>Currency Code:</strong> GBP<br />
<strong class='bbc'>Currency Sign:</strong> £<br />
<strong class='bbc'>Currency Title:</strong> Great Britain Pounds<br /></div></div><br />
 <br />
<br />
<br />
Multi-formatting:<br />
<pre class='prettyprint'>
$curArray = Array( 'USD', 'GBP', 'CAD' );
      
       foreach ($curArray as $cur){
          $curStuff =  getCurFormated($cur);
          echo "&lt;h2&gt;Information about $cur&lt;/h2&gt;";
          echo "Currency Code: $curStuff&#91;0&#93;&lt;br&gt;
                Currency Sign: $curStuff&#91;1&#93;&lt;br&gt;
                Currency Title: $curStuff&#91;2&#93;&lt;br&gt;";
       }
</pre><br />
<br />
The output:<br />
<p class='citation'>Quote</p><div class="blockquote"><div class='quote'>
<strong class='bbc'>Information about USD</strong><br />
Currency Code: USD<br />
Currency Sign: $<br />
Currency Title: United Stats Dollars<br />
<br />
<strong class='bbc'>Information about GBP</strong><br />
Currency Code: GBP<br />
Currency Sign: £<br />
Currency Title: Great Britain Pounds<br />
<br />
<br />
<strong class='bbc'>Information about CAD</strong><br />
Currency Code: CAD<br />
Currency Sign: $<br />
Currency Title: Canadian Dollars<br /></div></div>]]></description>
		<pubDate>Wed, 12 Jan 2011 07:24:23 +0000</pubDate>
		<guid isPermaLink="false">5fd0b37cd7dbbb00f97ba6ce92bf5add</guid>
	</item>
	<item>
		<title>Test articles</title>
		<link>http://www.realcustomscripts.com/page/articles/category/development/php/test-articles-r11</link>
		<description><![CDATA[PHP: Hypertext Preprocessor is a widely used, general-purpose scripting language that was originally designed for web development to produce dynamic web pages. For this purpose, PHP code is embedded into the HTML source document and interpreted by a web server with a PHP processor module, which generates the web page document. As a general-purpose programming language, PHP code is processed by an interpreter application in command-line  mode performing desired operating system operations and producing program output on its standard output channel. It may also function as a graphical application. PHP is available as a processor for most modern web servers and as a standalone interpreter on most operating systems and computing platforms.<br />
<br />
PHP was originally created by <strong class='bbc'>Rasmus Lerdorf</strong> in 1995[1][2] and has been in continuous development ever since. The main implementation of PHP is now produced by the PHP Group and serves as the de facto standard for PHP as there is no formal specification.[3] PHP is free software released under the PHP License.]]></description>
		<pubDate>Wed, 08 Sep 2010 19:59:49 +0000</pubDate>
		<guid isPermaLink="false">698d51a19d8a121ce581499d7b701668</guid>
	</item>
</channel>
</rss>
