<?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></title>
	<atom:link href="http://www.php-opensource.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.php-opensource.com</link>
	<description>A blog related to web development,php,mysql and open source tools</description>
	<lastBuildDate>Fri, 01 Apr 2011 12:54:49 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.4</generator>
		<item>
		<title>SQL Query</title>
		<link>http://www.php-opensource.com/2011/04/sql-query/</link>
		<comments>http://www.php-opensource.com/2011/04/sql-query/#comments</comments>
		<pubDate>Fri, 01 Apr 2011 12:54:49 +0000</pubDate>
		<dc:creator>gansai</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[alot]]></category>
		<category><![CDATA[Auto]]></category>
		<category><![CDATA[Draft]]></category>
		<category><![CDATA[paragraph]]></category>
		<category><![CDATA[Query]]></category>
		<category><![CDATA[score]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[table]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=373</guid>
		<description><![CDATA[I need to get a particular column &#8216;value&#8217; where it has alot of characters looks like a short paragraph, now i want a string Pretest_Score=25 i.e., it should display 25 in my table. How could be this done?. Please kindly help me with exact sql query. SELECT TRIM(&#8216;value&#8217;) FROM mdl_sample]]></description>
			<content:encoded><![CDATA[<p>I need to get a particular column &#8216;value&#8217; where it has alot of characters looks like a short paragraph, now i want a string Pretest_Score=25 i.e., it should display 25</p>
<p>in my table. How could be this done?. Please kindly help me with exact sql query.</p>
<p>SELECT TRIM(&#8216;value&#8217;) FROM mdl_sample</p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2011/04/sql-query/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP,MySQL</title>
		<link>http://www.php-opensource.com/2011/01/phpmysql/</link>
		<comments>http://www.php-opensource.com/2011/01/phpmysql/#comments</comments>
		<pubDate>Sun, 23 Jan 2011 17:48:36 +0000</pubDate>
		<dc:creator>gansai</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[addlink]]></category>
		<category><![CDATA[Auto]]></category>
		<category><![CDATA[column style]]></category>
		<category><![CDATA[Draft]]></category>
		<category><![CDATA[error]]></category>
		<category><![CDATA[font]]></category>
		<category><![CDATA[form]]></category>
		<category><![CDATA[input type text]]></category>
		<category><![CDATA[link]]></category>
		<category><![CDATA[query sql]]></category>
		<category><![CDATA[server request]]></category>
		<category><![CDATA[td id]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=367</guid>
		<description><![CDATA[I inserted a single link to database with a single field &#8216;addlink&#8217;, likewise i inserted again &#38; again and now totally i have 5 rows. How can i get all the rows from database and update them. Please help with this. /*&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-Inserting working Successfully */ echo &#8216;&#60;font size=&#8221;4px&#8221; face=&#8221;verdana&#8221;&#62;&#60;b&#62;Add a New Link&#60;/b&#62;&#60;/font&#62;&#60;br&#62;&#60;br&#62;&#8217;; if($_SERVER['REQUEST_METHOD']==&#8217;POST&#8217;) { $add1 [...]]]></description>
			<content:encoded><![CDATA[<p>I inserted a single link to database with a single field &#8216;addlink&#8217;, likewise i inserted again &amp; again and now totally i have<br />
5 rows. How can i get all the rows from database and update them. Please help with this.</p>
<p>/*&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-Inserting working Successfully */<br />
echo &#8216;&lt;font size=&#8221;4px&#8221; face=&#8221;verdana&#8221;&gt;&lt;b&gt;Add a New Link&lt;/b&gt;&lt;/font&gt;&lt;br&gt;&lt;br&gt;&#8217;;<br />
if($_SERVER['REQUEST_METHOD']==&#8217;POST&#8217;)<br />
{<br />
$add1 = $_REQUEST["add"];<br />
$sql=&#8221;INSERT INTO mdl_block_left_menu_front(addlink) values(&#8216;$add1&#8242;)&#8221;;<br />
$a=mysql_query($sql);<br />
if(!$a)<br />
{<br />
error(&#8216;There was an error while inserting the link&#8217;);<br />
}<br />
else<br />
{<br />
echo &#8220;Changes saved Successfully&#8221;;<br />
}<br />
}</p>
<p>echo &#8216;&lt;form name=&#8221;fname&#8221; action=&#8221;add.php&#8221; method=&#8221;post&#8221;&gt;&#8217;;<br />
echo &#8216;Add a link : &lt;input type=&#8221;field&#8221; name=&#8221;add&#8221;&gt;&lt;br&gt;&lt;br&gt;&#8217;;<br />
echo &#8216;&lt;input type=&#8221;submit&#8221; value=&#8221;submit&#8221;&gt;&lt;/form&gt;&#8217;;</p>
<p>/*&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212; Need help in updating</p>
<p>echo &#8216;&lt;td id=&#8221;middle-column&#8221; style=&#8221;text-align:center;&#8221;&gt;&#8217;;<br />
echo &#8216;&lt;font size=&#8221;4px&#8221; face=&#8221;verdana&#8221;&gt;&lt;b&gt;Edit Link&lt;/b&gt;&lt;/font&gt;&lt;br&gt;&lt;br&gt;&#8217;;<br />
$list = get_records_sql(&#8216;SELECT * FROM mdl_block_left_menu_front&#8217;);</p>
<p>/* Displaying the field values from database */<br />
foreach($list as $listed)<br />
{<br />
$addlinky = $listed-&gt;addlink;<br />
echo &#8216;&lt;form name=&#8221;f&#8221; action=&#8221;update.php&#8221; method=&#8221;post&#8221;&gt;&#8217;;<br />
echo &#8216;&lt;table width=150 cellspacing=4 cellpadding=4&gt;&lt;tr align=center&gt;&lt;td&gt;&lt;input type=&#8221;text&#8221; value=&#8221;&#8216;.$addlinky.&#8217;&#8221;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#8217;;<br />
}<br />
/* Displaying the field values from database */</p>
<p>echo &#8216;&lt;input type=&#8221;submit&#8221; value=&#8221;submit&#8221;&gt;&lt;/form&gt;&#8217;;</p>
<p>/* Editing the field values and submitting again to the database */</p>
<p>if($_SERVER['REQUEST_METHOD']==&#8217;POST&#8217;)<br />
{<br />
$sql=&#8217;UPDATE mdl_block_left_menu_front SET addlink=&#8221;&#8216;.$addlinky.&#8217;&#8221;&#8216;;<br />
//echo &#8216;UPDATE mdl_block_left_menu_front SET addlink=&#8217;.$addlinkyy.&#8221;;<br />
$a=mysql_query($sql);<br />
if(!$a)<br />
{<br />
error(&#8216;There was an error while inserting the link&#8217;);<br />
}<br />
else<br />
{<br />
echo &#8220;Changes saved Successfully&#8221;;<br />
}<br />
}<br />
/* Editing the field values and submitting again to the database */<br />
echo &#8216;&lt;/td&gt;&#8217;;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2011/01/phpmysql/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP file convert to XML</title>
		<link>http://www.php-opensource.com/2011/01/php-file-convert-to-xml/</link>
		<comments>http://www.php-opensource.com/2011/01/php-file-convert-to-xml/#comments</comments>
		<pubDate>Wed, 05 Jan 2011 18:56:46 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[amp]]></category>
		<category><![CDATA[Auto]]></category>
		<category><![CDATA[Draft]]></category>
		<category><![CDATA[echo link]]></category>
		<category><![CDATA[function]]></category>
		<category><![CDATA[lt]]></category>
		<category><![CDATA[parent]]></category>
		<category><![CDATA[parent node]]></category>
		<category><![CDATA[parseToXML]]></category>
		<category><![CDATA[php and xml]]></category>
		<category><![CDATA[php convert to another files]]></category>
		<category><![CDATA[php file to xml]]></category>
		<category><![CDATA[return]]></category>
		<category><![CDATA[Start]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=362</guid>
		<description><![CDATA[&#60;? function parseToXML($htmlStr) { $xmlStr=str_replace('&#60;','&#38;lt;',$htmlStr); $xmlStr=str_replace('&#62;','&#38;gt;',$xmlStr); $xmlStr=str_replace('"','&#38;quot;',$xmlStr); $xmlStr=str_replace("'",'&#38;apos;',$xmlStr); $xmlStr=str_replace("&#38;",'&#38;amp;',$xmlStr); return $xmlStr; } // Start XML file, echo parent node echo '&#60;items&#62;'; echo '&#60;item '; echo 'name="' . parseToXML(stripslashes($sName)) . '" '; echo 'address="' . parseToXML(stripslashes($sAddress)) . '" '; echo 'price="' . parseToXML($iPrice) . '" '; echo 'link="' . parseToXML($sLink) . '" '; echo 'details="' . [...]]]></description>
			<content:encoded><![CDATA[<p><code><code><span style="color: #000000;"> <span style="color: #0000bb;">&lt;?<br />
</span><span style="color: #007700;">function </span><span style="color: #0000bb;">parseToXML</span><span style="color: #007700;">(</span><span style="color: #0000bb;">$htmlStr</span><span style="color: #007700;">)<br />
{<br />
</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">=</span><span style="color: #0000bb;">str_replace</span><span style="color: #007700;">(</span><span style="color: #dd0000;">'&lt;'</span><span style="color: #007700;">,</span><span style="color: #dd0000;">'&amp;lt;'</span><span style="color: #007700;">,</span><span style="color: #0000bb;">$htmlStr</span><span style="color: #007700;">);<br />
</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">=</span><span style="color: #0000bb;">str_replace</span><span style="color: #007700;">(</span><span style="color: #dd0000;">'&gt;'</span><span style="color: #007700;">,</span><span style="color: #dd0000;">'&amp;gt;'</span><span style="color: #007700;">,</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">);<br />
</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">=</span><span style="color: #0000bb;">str_replace</span><span style="color: #007700;">(</span><span style="color: #dd0000;">'"'</span><span style="color: #007700;">,</span><span style="color: #dd0000;">'&amp;quot;'</span><span style="color: #007700;">,</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">);<br />
</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">=</span><span style="color: #0000bb;">str_replace</span><span style="color: #007700;">(</span><span style="color: #dd0000;">"'"</span><span style="color: #007700;">,</span><span style="color: #dd0000;">'&amp;apos;'</span><span style="color: #007700;">,</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">);<br />
</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">=</span><span style="color: #0000bb;">str_replace</span><span style="color: #007700;">(</span><span style="color: #dd0000;">"&amp;"</span><span style="color: #007700;">,</span><span style="color: #dd0000;">'&amp;amp;'</span><span style="color: #007700;">,</span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">);<br />
return </span><span style="color: #0000bb;">$xmlStr</span><span style="color: #007700;">;<br />
}</p>
<p></span><span style="color: #ff8000;">// Start XML file, echo parent node<br />
</span><span style="color: #007700;">echo </span><span style="color: #dd0000;">'&lt;items&gt;'</span><span style="color: #007700;">;</p>
<p>echo </span><span style="color: #dd0000;">'&lt;item '</span><span style="color: #007700;">;<br />
echo </span><span style="color: #dd0000;">'name="' </span><span style="color: #007700;">. </span><span style="color: #0000bb;">parseToXML</span><span style="color: #007700;">(</span><span style="color: #0000bb;">stripslashes</span><span style="color: #007700;">(</span><span style="color: #0000bb;">$sName</span><span style="color: #007700;">)) . </span><span style="color: #dd0000;">'" '</span><span style="color: #007700;">;<br />
echo </span><span style="color: #dd0000;">'address="' </span><span style="color: #007700;">. </span><span style="color: #0000bb;">parseToXML</span><span style="color: #007700;">(</span><span style="color: #0000bb;">stripslashes</span><span style="color: #007700;">(</span><span style="color: #0000bb;">$sAddress</span><span style="color: #007700;">)) . </span><span style="color: #dd0000;">'" '</span><span style="color: #007700;">;<br />
echo </span><span style="color: #dd0000;">'price="' </span><span style="color: #007700;">. </span><span style="color: #0000bb;">parseToXML</span><span style="color: #007700;">(</span><span style="color: #0000bb;">$iPrice</span><span style="color: #007700;">) . </span><span style="color: #dd0000;">'" '</span><span style="color: #007700;">;<br />
echo </span><span style="color: #dd0000;">'link="' </span><span style="color: #007700;">. </span><span style="color: #0000bb;">parseToXML</span><span style="color: #007700;">(</span><span style="color: #0000bb;">$sLink</span><span style="color: #007700;">) . </span><span style="color: #dd0000;">'" '</span><span style="color: #007700;">;<br />
echo </span><span style="color: #dd0000;">'details="' </span><span style="color: #007700;">. </span><span style="color: #0000bb;">parseToXML</span><span style="color: #007700;">(</span><span style="color: #0000bb;">stripslashes</span><span style="color: #007700;">(</span><span style="color: #0000bb;">$tDetails</span><span style="color: #007700;">)) . </span><span style="color: #dd0000;">'" '</span><span style="color: #007700;">;<br />
echo </span><span style="color: #dd0000;">'other="' </span><span style="color: #007700;">. </span><span style="color: #0000bb;">parseToXML</span><span style="color: #007700;">(</span><span style="color: #0000bb;">stripslashes</span><span style="color: #007700;">(</span><span style="color: #0000bb;">$sOther</span><span style="color: #007700;">)) . </span><span style="color: #dd0000;">'" '</span><span style="color: #007700;">;<br />
echo </span><span style="color: #dd0000;">'/&gt;'</span><span style="color: #007700;">;</p>
<p></span><span style="color: #ff8000;">// End XML file<br />
</span><span style="color: #007700;">echo </span><span style="color: #dd0000;">'&lt;/items&gt;'</span><span style="color: #007700;">;</p>
<p></span><span style="color: #0000bb;">?&gt;</span> </span> </code></code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2011/01/php-file-convert-to-xml/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Convert PHP Array to XML or Simple XML Object</title>
		<link>http://www.php-opensource.com/2011/01/convert-php-array-to-xml-or-simple-xml-object/</link>
		<comments>http://www.php-opensource.com/2011/01/convert-php-array-to-xml-or-simple-xml-object/#comments</comments>
		<pubDate>Wed, 05 Jan 2011 18:52:48 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[php]]></category>
		<category><![CDATA[Array]]></category>
		<category><![CDATA[array data]]></category>
		<category><![CDATA[array value]]></category>
		<category><![CDATA[Auto]]></category>
		<category><![CDATA[compatibility]]></category>
		<category><![CDATA[Convert PHP Array to XML or Simple XML Object]]></category>
		<category><![CDATA[convert php file to xml file]]></category>
		<category><![CDATA[convert php to xml]]></category>
		<category><![CDATA[Draft]]></category>
		<category><![CDATA[lt xml]]></category>
		<category><![CDATA[multi dimensional array]]></category>
		<category><![CDATA[param]]></category>
		<category><![CDATA[php to xml]]></category>
		<category><![CDATA[return]]></category>
		<category><![CDATA[toXml]]></category>
		<category><![CDATA[xml object]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=359</guid>
		<description><![CDATA[Convert PHP Array to XML or Simple XML Object if you wish......]]></description>
			<content:encoded><![CDATA[<p>class ArrayToXML</p>
<p>{</p>
<p>/**</p>
<p>* The main function for converting to an XML document.</p>
<p>* Pass in a multi dimensional array and this recrusively loops through and builds up an XML document.</p>
<p>*</p>
<p>* @param array $data</p>
<p>* @param string $rootNodeName &#8211; what you want the root node to be &#8211; defaultsto data.</p>
<p>* @param SimpleXMLElement $xml &#8211; should only be used recursively<br />
* @return string XML</p>
<p>*/</p>
<p>public static function toXml($data, $rootNodeName = &#8216;data&#8217;, $xml=null)</p>
<p>{</p>
<p>// turn off compatibility mode as simple xml throws a wobbly if you don&#8217;t.</p>
<p>if (ini_get(&#8216;zend.ze1_compatibility_mode&#8217;) == 1)</p>
<p>{</p>
<p>ini_set (&#8216;zend.ze1_compatibility_mode&#8217;, 0);</p>
<p>}</p>
<p>if ($xml == null)</p>
<p>{</p>
<p>$xml = simplexml_load_string(&#8220;&lt;?xml version=&#8217;1.0&#8242; encoding=&#8217;utf-8&#8242;?&gt;&lt;$rootNodeName /&gt;&#8221;);</p>
<p>}</p>
<p>// loop through the data passed in.</p>
<p>foreach($data as $key =&gt; $value)</p>
<p>{</p>
<p>// no numeric keys in our xml please!</p>
<p>if (is_numeric($key))</p>
<p>{</p>
<p>// make string key&#8230;</p>
<p>$key = &#8220;unknownNode_&#8221;. (string) $key;</p>
<p>}</p>
<p>// replace anything not alpha numeric</p>
<p>$key = preg_replace(&#8216;/[^a-z]/i&#8217;, &#8221;, $key);</p>
<p>// if there is another array found recrusively call this function</p>
<p>if (is_array($value))</p>
<p>{</p>
<p>$node = $xml-&gt;addChild($key);</p>
<p>// recrusive call.</p>
<p>ArrayToXML::toXml($value, $rootNodeName, $node);</p>
<p>}</p>
<p>else</p>
<p>{</p>
<p>// add single node.</p>
<p>$value = htmlentities($value);</p>
<p>$xml-&gt;addChild($key,$value);</p>
<p>}</p>
<p>}</p>
<p>// pass back as string. or simple xml object if you want!</p>
<p>return $xml-&gt;asXML();</p>
<p>}</p>
<p>}</p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2011/01/convert-php-array-to-xml-or-simple-xml-object/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP Object Based</title>
		<link>http://www.php-opensource.com/2010/10/php-object-based/</link>
		<comments>http://www.php-opensource.com/2010/10/php-object-based/#comments</comments>
		<pubDate>Wed, 27 Oct 2010 07:50:38 +0000</pubDate>
		<dc:creator>gansai</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Auto]]></category>
		<category><![CDATA[Draft]]></category>
		<category><![CDATA[dynamic places]]></category>
		<category><![CDATA[dynamic template]]></category>
		<category><![CDATA[information]]></category>
		<category><![CDATA[location]]></category>
		<category><![CDATA[module]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[php file]]></category>
		<category><![CDATA[template]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=356</guid>
		<description><![CDATA[I need a dynamic template file for the pictures that will be pulled from the database. a.     I need a location for them to be stored and code that designates where to place the pictures that were uploaded or taken from facebook. This is going to be object based PHP and  I want each module [...]]]></description>
			<content:encoded><![CDATA[<p>I need a dynamic template file for the pictures that will be pulled from the database.</p>
<p>a.     I need a location for them to be stored and code that designates where to place the pictures that were uploaded or taken from facebook.</p>
<p>This is going to be object based PHP and  I want each module to be separated into a different PHP file. I need the code only pulling information and putting information into dynamic places.</p>
<p>Please help me</p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2010/10/php-object-based/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>AutoTags</title>
		<link>http://www.php-opensource.com/2010/10/autotags/</link>
		<comments>http://www.php-opensource.com/2010/10/autotags/#comments</comments>
		<pubDate>Thu, 07 Oct 2010 09:25:47 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=344</guid>
		<description><![CDATA[Basing on WordPress Plugin &#8220;tagthepress&#8221; .It using for tag suggestions by Yahoo cas API http://tw.developer.yahoo.com/cas/ With this plugin, you will be able to use the the Web service for your posts. Just click on Fetch tags and the title, content and optional excerpt of your post will be analyzed by Yahoo cas API in order [...]]]></description>
			<content:encoded><![CDATA[<p>Basing on WordPress Plugin &#8220;tagthepress&#8221; .It using for tag suggestions by Yahoo cas API <a rel="nofollow" href="http://tw.developer.yahoo.com/cas/">http://tw.developer.yahoo.com/cas/</a></p>
<p>With this plugin, you will be able to use the the Web service for your posts. Just click on <code>Fetch tags</code> and the title, content and optional excerpt of your post will be  analyzed by Yahoo cas API in order to find words that could be useful as  tags.</p>
<p>It currently works with English, Chinese</p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2010/10/autotags/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fckeditor Configuration File</title>
		<link>http://www.php-opensource.com/2010/08/configuration-file/</link>
		<comments>http://www.php-opensource.com/2010/08/configuration-file/#comments</comments>
		<pubDate>Sun, 15 Aug 2010 16:10:33 +0000</pubDate>
		<dc:creator>narayanvj</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[fckeditor]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=336</guid>
		<description><![CDATA[The editor comes with a rich set of configurations that makes it possible to customize its appearance, features and behavior. The main configuration file is named &#8220;fckconfig.js&#8220;. You can find this file in the root of the FCKeditor installation folder. // Available Configuration Options Check out the configuration options list to have a complete overview [...]]]></description>
			<content:encoded><![CDATA[<div id="mainCol">
<div class="post">
<p>The editor comes with a rich set of configurations that makes it possible to customize its appearance, features and behavior. The main configuration file is named &#8220;<strong>fckconfig.js</strong>&#8220;. You can find this file in the root of the FCKeditor installation folder.<span id="more-336"></span><br />
<script type="text/javascript">// <![CDATA[
    if (window.showTocToggle) { var tocShowText = "show"; var tocHideText = "hide"; showTocToggle(); }
// ]]&gt;</script><br />
<a id="Available_Configuration_Options" name="Available_Configuration_Options"></a></p>
<h2><span class="mw-headline"> Available Configuration Options </span></h2>
<p>Check out the <a title="FCKeditor 2.x/Developers Guide/Configuration/Configuration Options" href="http://docs.cksource.com/FCKeditor_2.x/Developers_Guide/Configuration/Configuration_Options">configuration options list</a> to have a complete overview of each setting.</p>
<p><a id="Overriding_the_Default_Configurations" name="Overriding_the_Default_Configurations"></a></p>
<h2><span class="mw-headline"> Overriding the Default Configurations </span></h2>
<p>You can either edit the main configuration file or just override the settings you want to change in a separate file. JavaScript syntax is used to configure FCKeditor.</p>
<p>To simplify updating FCKeditor on your sites, the best approach is to put all your configuration in a separate file, outside the editor&#8217;s package directory structure. In this way, you just need to overwrite the editor&#8217;s directory to update it to a newer version.</p>
<p><a id="Step_1" name="Step_1"></a></p>
<h3><span class="mw-headline"> Step 1 </span></h3>
<p>Create a file called, for example, <strong>&#8220;myconfig.js&#8221;</strong> and save it in the root directory (or any directory) of your web site. You custom settings will be placed in this file. For example, let&#8217;s suppose you want to force the editor to always have its interface in French. Simply writte this code into your new file:</p>
<pre>FCKConfig.AutoDetectLanguage = false ;
FCKConfig.DefaultLanguage = "fr" ;
</pre>
<p><a id="Step_2" name="Step_2"></a></p>
<h3><span class="mw-headline"> Step 2 </span></h3>
<p>Now we have to tell the editor that it has to load my custom configuration. There are two methodes to do it:</p>
<p><a id="Method_1" name="Method_1"></a></p>
<h4><span class="mw-headline"> Method 1 </span></h4>
<p>Find the following line in the main configuration file (<strong>fckconfig.js</strong>):</p>
<pre>FCKConfig.CustomConfigurationsPath = '' ;
</pre>
<p>and put in the path of your custom configuration file:</p>
<pre>FCKConfig.CustomConfigurationsPath = '/myconfig.js' ;
</pre>
<p>The above method is good, but, as you can imagine, you lose the facility not to touch the original files. In any case it is easier to remember that you just need to change one line, and all the other things settings changes remain separated.</p>
<p><a id="Method_2" name="Method_2"></a></p>
<h4><span class="mw-headline"> Method 2 </span></h4>
<p>There is an even better way to have the same results as described above, but without touching the fckconfig.js file. You can set the custom configurations path directly in the page that uses the editor. This is an example to achive this in JavaScript:</p>
<pre>var oFCKeditor = new FCKeditor( "FCKeditor1" ) ;
oFCKeditor.Config["CustomConfigurationsPath"] = "/myconfig.js"  ;
oFCKeditor.Create() ;
</pre>
<p>The same method can be used with your preferred server side language. Take a look at the samples to find out how to manipulate the configurations by code.</p>
<p><a id="Configurations_Loading_Precedence" name="Configurations_Loading_Precedence"></a></p>
<h3><span class="mw-headline"> Configurations Loading Precedence<br />
</span></h3>
<p>When overriding configurations, the following steps are taken:</p>
<ol>
<li> The configurations in the main configuration file (fckconfig.js) are loaded.</li>
<li> The configurations are overridden by the settings in the custom configuration file (if provided).</li>
<li> The configurations are finally overridden by the settings done inline in the editor page, except for the &#8220;CustomConfigurationsPath&#8221;, which is set right after step 1.</li>
</ol>
<p>You don&#8217;t need to include all configuration options in your custom file, just those you want to change. Your file will &#8220;override&#8221; the default one.</p>
<p><strong>NOTE</strong>:You need to keep the original configuration file, &#8220;fckconfig.js&#8221;, in the editor directory. Don&#8217;t delete it or you will break FCKeditor.</p>
<p><a id="Browser_Caching" name="Browser_Caching"></a></p>
<h3><span class="mw-headline"> Browser Caching </span></h3>
<p><strong>NOTE</strong>: remember to clear your browser cache when making changes to the configuration files, otherwise you may not see your changes. This is especially important when working behind a proxy which may cache your .js files more persistently than pages. There are a few tricks that can be used while developing to retrieve the latest version of the configuration file:</p>
<ul>
<li> If you are using Internet Explorer, hitting CTRL + F5 should suffice to update the latest versions of the script. No need to manually clear the browser cache.</li>
<li> If you are using Firefox or other Mozilla&#8217;s children, hitting Shift+CTRL + R should update the latest version with no need to clear the cache (although this method doesn&#8217;t seem to work at all times, if this fails clear cache manually).</li>
<li> You could add a number or code in the end of the custom configuration path, so the browser would be forced to load it every time:</li>
</ul>
<pre>var oFCKeditor = new FCKeditor( "FCKeditor1" ) ;
oFCKeditor.Config["CustomConfigurationsPath"] = "/myconfig.js?" + ( new Date() * 1 ) ;
oFCKeditor.Create() ;
</pre>
<p><!--  NewPP limit report Preprocessor node count: 24/1000000 Post-expand include size: 0/2097152 bytes Template argument size: 0/2097152 bytes Expensive parser function count: 0/100 --></p>
<p><!-- Saved in parser cache with key fckedit_cksourcedocs:pcache:idhash:413-0!1!0!!en!2!edit=0 and timestamp 20100815160350 --></p>
<div class="printfooter">Retrieved from &#8220;<a href="http://docs.cksource.com/FCKeditor_2.x/Developers_Guide/Configuration_File">http://docs.cksource.com/FCKeditor_2.x/Developers_Guide/Configuration_File</a>&#8220;</div>
</div>
</div>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2010/08/configuration-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Event Registration Joomla</title>
		<link>http://www.php-opensource.com/2010/08/event-registration-joomla/</link>
		<comments>http://www.php-opensource.com/2010/08/event-registration-joomla/#comments</comments>
		<pubDate>Sun, 08 Aug 2010 16:46:14 +0000</pubDate>
		<dc:creator>narayanvj</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[free software/tools]]></category>
		<category><![CDATA[joomla]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=333</guid>
		<description><![CDATA[Following is the link to list of components for Event Registration in Joomla. http://extensions.joomla.org/extensions/calendars-a-events/events-registration]]></description>
			<content:encoded><![CDATA[<p>Following is the link to list of components for Event Registration in Joomla.</p>
<p>http://extensions.joomla.org/extensions/calendars-a-events/events-registration</p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2010/08/event-registration-joomla/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Javascript Validation for uploading files</title>
		<link>http://www.php-opensource.com/2010/08/javascript-validation-for-uploading-files/</link>
		<comments>http://www.php-opensource.com/2010/08/javascript-validation-for-uploading-files/#comments</comments>
		<pubDate>Sun, 08 Aug 2010 15:40:58 +0000</pubDate>
		<dc:creator>narayanvj</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[free software/tools]]></category>
		<category><![CDATA[javascript]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[file]]></category>
		<category><![CDATA[file type]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[validation]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=329</guid>
		<description><![CDATA[The below javascript funtion checks the browsing file. For example, If the uploading file should accept only excel and word documents like that, then in that scenario, we can use this function. &#60;script type="text/javascript"&#62; function CheckFileExtension() { var ctrlUpload = document.getElementById('&#60; %=FileUpload.ClientID% &#62;'); //Does the user browse or select a file or not if (ctrlUpload.value [...]]]></description>
			<content:encoded><![CDATA[<pre><span style="color: #0000;">The below javascript funtion checks the browsing file. For example, If 

the uploading file should accept only excel and word documents like that, 

then in that scenario, we can use this function.
</span><span id="more-329"></span>

&lt;script type="text/javascript"&gt;
    function CheckFileExtension()
    {
        var ctrlUpload = document.getElementById('&lt; %=FileUpload.ClientID% &gt;');

        <span style="color: green;">
        //Does the user browse or select a file or not</span>
        if (ctrlUpload.value =='' )
        {
            alert("Select a file to upload!");
            ctrlUpload.focus();
            return false;
        }

         <span style="color: green;">
        //Extension List for validation. Add your
           required extension here with comma separator </span>
        var extensionList = new Array(".xls", ".doc");

        <span style="color: green;">//Get Selected file extension</span>
        var extension = ctrlUpload.value.slice(ctrlUpload.value.indexOf(".")).toLowerCase();

        <span style="color: green;">
        //Check file extension with your required extension list.</span>
        for (var i = 0; i &lt; extensionList.length; i++)
        {
            if (extensionList[i] == extension)
            return true;
        }
        alert("You can only upload below File Type:\n\n"+extensionList.join("\n"));
        ctrlUpload.focus();
        return false;
   }

   &lt;/script&gt;</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2010/08/javascript-validation-for-uploading-files/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Joomla Podcast Suite</title>
		<link>http://www.php-opensource.com/2010/08/joomla-podcast-suite/</link>
		<comments>http://www.php-opensource.com/2010/08/joomla-podcast-suite/#comments</comments>
		<pubDate>Fri, 06 Aug 2010 16:17:20 +0000</pubDate>
		<dc:creator>narayanvj</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[component]]></category>
		<category><![CDATA[extension]]></category>
		<category><![CDATA[joomla]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[podcast]]></category>
		<category><![CDATA[radio]]></category>

		<guid isPermaLink="false">http://www.php-opensource.com/?p=326</guid>
		<description><![CDATA[Podcast Suite. A component, module, and mambot designed to bring podcasting capabilities to Joomla. Support for iTunes.]]></description>
			<content:encoded><![CDATA[<p><a href="http://extensions.joomla.org/extensions/multimedia/shoutcast-a-podcasts/255" target = "_blank"><strong>Podcast Suite</strong></a>.</p>
<p>A component, module, and mambot designed to bring podcasting capabilities to Joomla. Support for iTunes. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.php-opensource.com/2010/08/joomla-podcast-suite/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

