<?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>PHPXPERT.COM</title>
	<atom:link href="http://phpxpert.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://phpxpert.com</link>
	<description>Web log from a freelance web developer</description>
	<lastBuildDate>Fri, 09 Dec 2011 16:21:04 +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>Find the number of child elements using jQuery</title>
		<link>http://phpxpert.com/2011/11/24/find-the-number-of-child-elements-using-jquery/</link>
		<comments>http://phpxpert.com/2011/11/24/find-the-number-of-child-elements-using-jquery/#comments</comments>
		<pubDate>Thu, 24 Nov 2011 13:09:21 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[jQuery]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=113</guid>
		<description><![CDATA[Hi guys, sometimes we may need to count the number of elements under a particular element. jQuery helps us to find the number of elements very easily, consider the following HTML we can use the following code to find out &#8230; <a href="http://phpxpert.com/2011/11/24/find-the-number-of-child-elements-using-jquery/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hi guys, sometimes we may need to count the number of elements under a particular element. jQuery helps us to find the number of elements very easily, consider the following HTML</p>
<p><span id="more-113"></span></p>
<pre class="brush: xml; title: ; notranslate">
&lt;ul id=&quot;list&quot;&gt;
	&lt;li&gt;1&lt;/li&gt;
	&lt;li&gt;2&lt;/li&gt;
	&lt;li&gt;3&lt;/li&gt;
&lt;/ul&gt;
</pre>
<p>we can use the following code to find out the number of list items under the UL</p>
<pre class="brush: jscript; title: ; notranslate">
var count = $('#list').size() //here the value in count will be 3
</pre>
<p>If you want to find out the number of elements of all types under a particular elelment, then you can use  *</p>
<pre class="brush: xml; title: ; notranslate">
&lt;div id=&quot;first&quot;&gt;
&lt;span&gt;Span element 1&lt;/span&gt;
&lt;span&gt;Span element 2&lt;/span&gt;
&lt;p&gt;paragraph&lt;/p&gt;
&lt;span&gt;Another span&lt;/span&gt;
&lt;div&gt;another div&lt;/div&gt;
&lt;/div&gt;
</pre>
<p>If you want to find out the total number of &#8216;span&#8217; elements under the div with id &#8220;first&#8221;, use the following code</p>
<pre class="brush: jscript; title: ; notranslate">
var count = $(&quot;#first &gt; span &quot;).size() //value in the var 'count' will be 3
</pre>
<p>we can use the following code to get the number of elements of all types under the div with id &#8220;first&#8221;</p>
<pre class="brush: jscript; title: ; notranslate">
var count = $(&quot;#first &gt; *&quot;).size() //value in the var count will be 5
</pre>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/11/24/find-the-number-of-child-elements-using-jquery/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to override module layout in joomla</title>
		<link>http://phpxpert.com/2011/11/10/how-to-override-module-layout-in-joomla/</link>
		<comments>http://phpxpert.com/2011/11/10/how-to-override-module-layout-in-joomla/#comments</comments>
		<pubDate>Thu, 10 Nov 2011 17:27:29 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[Joomla]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=97</guid>
		<description><![CDATA[Joomla is a popular CMS application, now I am using Joomla 1.7.  A lot of modules are available to download and each module has its own layout. Sometimes we may need to override the existing layout of a module. In &#8230; <a href="http://phpxpert.com/2011/11/10/how-to-override-module-layout-in-joomla/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Joomla is a popular CMS application, now I am using Joomla 1.7.  A lot of modules are available to download and each module has its own layout. Sometimes we may need to override the existing layout of a module. In order to override a module&#8217;s layout, we don&#8217;t need to update the module&#8217;s own layout files, instead we can create our own layout files to override the existing layout.</p>
<p><span id="more-97"></span></p>
<p>I will show you how to override a module&#8217;s layout with the help of an example. One of the most important module in Joomla is the menu module. Its files are located inside the  mod_menu directory inside the modules directory. The layout files of this particular module are located inside the tmpl directory. If you want to override these layout files, you have to move the layout files to your current template&#8217;s directory. My current template name is beez5 ( beez5 comes with Joomla) and I am going to move these layout files(files in side the tmpl directory) to the beez5 folder, before moving all the files, we have to make a few directories inside the template(beez5) directory. I have to create a new folder with name &#8220;html&#8221; inside the template folder to override the layout file (html folder is present in most of the templates) .I have to create one more folder inside the &#8220;html&#8221; directory as the name of the overriding module, so I have created a new folder with name &#8220;mod_menu&#8221;, then we have to paste the entire files in the tmpl directory to this directory. You can make what ever changes you need in the layout in the new files and when Joomla renders module mod_menu&#8217;s output, it takes the layout files from the mod_menu directory in the template folder.</p>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/11/10/how-to-override-module-layout-in-joomla/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>URL shortening using PHP</title>
		<link>http://phpxpert.com/2011/10/31/url-shortening-using-php/</link>
		<comments>http://phpxpert.com/2011/10/31/url-shortening-using-php/#comments</comments>
		<pubDate>Mon, 31 Oct 2011 08:40:46 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=90</guid>
		<description><![CDATA[to.ly and tinyurl.com are the most wanted URL shortening service providers. We can make urls short from their sites also we can use their services through PHP code. PHP code to short URL using to.ly PHP code to short URL using  tinyurl.com]]></description>
			<content:encoded><![CDATA[<p><a href="http://to.ly/">to.ly</a> and <a href="http://tinyurl.com">tinyurl.com</a> are the most wanted URL shortening service providers. We can make urls short from their sites also we can use their services through PHP code.</p>
<p><span id="more-90"></span>PHP code to short URL using <a href="http://to.ly/">to.ly</a></p>
<pre class="brush: php; title: ; notranslate">
function shortit($url)
{
	$curl = curl_init();
	curl_setopt($curl, CURLOPT_URL, &quot;http://to.ly/api.php?longurl=&quot;.urlencode($url));
	curl_setopt($curl, CURLOPT_RETURNTRANSFER,1);
	curl_setopt($curl, CURLOPT_HEADER, 0);
	$shorturl = curl_exec ($curl);
	curl_close ($curl);
	return $shorturl;
}
$url = &quot;http://phpxpert.com/&quot;;
echo shortit($url);
</pre>
<p>PHP code to short URL using  <a href="http://tinyurl.com">tinyurl.com</a></p>
<pre class="brush: php; title: ; notranslate">
function shortit($url)
{
	$url = &quot;http://tinyurl.com/api-create.php?url=&quot; . $url;
	$shorturl = file_get_contents($url);
	return $shorturl;
}

$url = &quot;http://phpxpert.com/&quot;;
echo shortit($url);
</pre>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/10/31/url-shortening-using-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Connect to an external database from a Joomla extension</title>
		<link>http://phpxpert.com/2011/10/28/connect-to-an-external-database-from-a-joomla-extension/</link>
		<comments>http://phpxpert.com/2011/10/28/connect-to-an-external-database-from-a-joomla-extension/#comments</comments>
		<pubDate>Fri, 28 Oct 2011 04:08:56 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[Joomla]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=79</guid>
		<description><![CDATA[Hello guys, sometimes we may need to connect to an external database from a custom made joomla extension. It is possible to connect to an external database with the help of JDatabase class. The following sample function connects to an &#8230; <a href="http://phpxpert.com/2011/10/28/connect-to-an-external-database-from-a-joomla-extension/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hello guys, sometimes we may need to connect to an external database from a custom made joomla extension. It is possible to connect to an external database with the help of JDatabase class. The following sample function connects to an external database and execute a query in the database and returns the result</p>
<p><span id="more-79"></span></p>
<pre class="brush: php; title: ; notranslate">
function getDetails()
{
     $options = array();
     $options['driver']   = 'mysql';
     $options['host']     = 'localhost';
     $options['user']     = 'dbuser';
     $options['password'] = 'dbpassword';
     $options['database'] = 'databasename';
     $options['prefix']   = 'tblprefix_';
     $db = &amp; JDatabase::getInstance($options);
     $query = &quot;SELECT * FROM #__example_table&quot;;
     $db-&gt;setQuery($query);
     return $db-&gt;loadAssocList();
}
</pre>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/10/28/connect-to-an-external-database-from-a-joomla-extension/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Directory indexing options using .htaccess file</title>
		<link>http://phpxpert.com/2011/10/27/directory-indexing-options-using-htaccess-file/</link>
		<comments>http://phpxpert.com/2011/10/27/directory-indexing-options-using-htaccess-file/#comments</comments>
		<pubDate>Thu, 27 Oct 2011 17:12:43 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[htaccess]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=52</guid>
		<description><![CDATA[Hi guys, in this post I am trying to describe various directory indexing options available through an htaccess file. htaccess stands for &#8220;Hypertext Access&#8221; and according to Apache .htaccess files (or &#8220;distributed configuration files&#8221;) provide a way to make configuration changes on &#8230; <a href="http://phpxpert.com/2011/10/27/directory-indexing-options-using-htaccess-file/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hi guys, in this post I am trying to describe various directory indexing options available through an htaccess file.</p>
<p>htaccess stands for &#8220;Hypertext Access&#8221; and according to <a href="http://httpd.apache.org/docs/1.3/howto/htaccess.html">Apache</a> <code>.htaccess</code> files (or &#8220;distributed configuration files&#8221;) provide a way to make configuration changes on a per-directory basis. A file, containing one or more configuration directives, is placed in a particular directory, and the directives apply to that directory, and all subdirectories thereof.</p>
<p><span id="more-52"></span></p>
<p>Most of the hosting companies enabled directory indexing in the server configuration file. If the directory indexing is enabled and you dont have a default directory file (index.html, index.php etc..) in the directory  then all the files in the directory get listed on the browser as in the following image</p>
<p><a href="http://phpxpert.com/wp-content/uploads/2011/10/ScreenShot006.gif"><img class="aligncenter size-full wp-image-64" title="ScreenShot006" src="http://phpxpert.com/wp-content/uploads/2011/10/ScreenShot006.gif" alt="" width="563" height="178" /></a></p>
<p>On the other hand if the directory indexing is disabled in the server and if you dont have a default file (index.html, index.php etc..) in the directory, you get a message like in following image on the browser and we can access one file by specifying its name.</p>
<p><a href="http://phpxpert.com/wp-content/uploads/2011/10/ScreenShot007.gif"><img class="aligncenter size-full wp-image-65" title="ScreenShot007" src="http://phpxpert.com/wp-content/uploads/2011/10/ScreenShot007.gif" alt="" width="887" height="185" /></a></p>
<p>If your server disabled directory indexing and you need directory indexing you can use the following directive in the htaccess file  to show the file list on the browser.</p>
<pre class="brush: plain; title: ; notranslate">
Options +Indexes
</pre>
<p>If the server enabled directory indexing and you don&#8217;t need directory indexing, you can use the following directive to disable the directory indexing.</p>
<pre class="brush: plain; title: ; notranslate">
Options -Indexes
</pre>
<p>It is also possible to hide files of specific format, for example the following directive hide all the gif and html files in the directory from the files list.</p>
<pre class="brush: plain; title: ; notranslate">
IndexIgnore *.gif *.html
</pre>
<p>You can also change the default directory file by an htaccess directive.</p>
<pre class="brush: plain; title: ; notranslate">
DirectoryIndex about.html
</pre>
<p>The above htaccess directive set about.html as the default file in the directory.</p>
<p>If you want to show more details in the index such as Last modified time, Size etc.. then you can use the fancy indexing directive in the htaccess file</p>
<pre class="brush: plain; title: ; notranslate">
IndexOptions FancyIndexing
or
IndexOptions +FancyIndexing
</pre>
<p>The above command in the htaccess file shows more details of the files in the index as the following image.</p>
<p><a href="http://phpxpert.com/wp-content/uploads/2011/10/ScreenShot009.gif"><img class="aligncenter size-full wp-image-75" title="ScreenShot009" src="http://phpxpert.com/wp-content/uploads/2011/10/ScreenShot009.gif" alt="" width="801" height="198" /></a>If FancyIndexing is enabled in the server and you want to remove fanyindexing use the following directive in the htaccess file</p>
<pre class="brush: plain; title: ; notranslate">
IndexOptions -FancyIndexing
</pre>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/10/27/directory-indexing-options-using-htaccess-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Joomla &#8211; How printing $app object in index.php display the whole site contents</title>
		<link>http://phpxpert.com/2011/09/20/joomla-how-printing-app-object-in-index-php-display-the-whole-site-contents/</link>
		<comments>http://phpxpert.com/2011/09/20/joomla-how-printing-app-object-in-index-php-display-the-whole-site-contents/#comments</comments>
		<pubDate>Tue, 20 Sep 2011 16:55:20 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[Joomla]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=37</guid>
		<description><![CDATA[Joomla is the most wanted CMS application I have ever seen. Currently I am using Joomla 1.6.  If you notice the index.php located at the root of joomla installation, you can see an object $app playing an important role in making &#8230; <a href="http://phpxpert.com/2011/09/20/joomla-how-printing-app-object-in-index-php-display-the-whole-site-contents/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Joomla is the most wanted CMS application I have ever seen. Currently I am using Joomla 1.6.  If you notice the index.php located at the root of joomla installation, you can see an object $app playing an important role in making the site contents. $app is an object of the class Jsite, class Jsite is defined in /includes/application.php. The class Jsite is extended from the class JApplication which is defined in libraries/joomla/application/application.php. Object $app calling several methods and finally print out the entire contents by the code echo $app; Its understood that an object cant print out any contents just by an echo statement. then how the code echo $app prints out the entire site contents ? here is the magic of the magic method <a href="http://www.php.net/manual/en/language.oop5.magic.php#language.oop5.magic.tostring">__toString()</a>. <span id="more-37"></span></p>
<p>The <a href="http://www.php.net/manual/en/language.oop5.magic.php#language.oop5.magic.tostring">__toString()</a> method allows a class to decide how it will react when it is treated like a string.This method must return a string.</p>
<p>The method <a href="http://www.php.net/manual/en/language.oop5.magic.php#language.oop5.magic.tostring">__toString()</a> is defined in the class Japplication. (class Jsite is a subclass of Japplication) so when code echo $app execute it calls the method <a href="http://www.php.net/manual/en/language.oop5.magic.php#language.oop5.magic.tostring">__toString()</a> defined in the class Japplication which in turn return the site contents.</p>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/09/20/joomla-how-printing-app-object-in-index-php-display-the-whole-site-contents/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Dynamic templates in Drupal</title>
		<link>http://phpxpert.com/2011/08/17/dynamic-templates-in-drupal/</link>
		<comments>http://phpxpert.com/2011/08/17/dynamic-templates-in-drupal/#comments</comments>
		<pubDate>Wed, 17 Aug 2011 14:18:19 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[Drupal]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=22</guid>
		<description><![CDATA[Hi guys, Drupal is an excellent content management system. It has a lot of features and one interesting feature is its dynamic template system. Dynamic templates allows us to change the layout of a page or a block very easily. For example, &#8230; <a href="http://phpxpert.com/2011/08/17/dynamic-templates-in-drupal/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hi guys, Drupal is an excellent content management system. It has a lot of features and one interesting feature is its dynamic template system. Dynamic templates allows us to change the layout of a page or a block very easily. For example, if you need a different layout in the Front page, you can use the front page template.</p>
<p><span id="more-22"></span>To see the use of front page template, make a copy of <strong>page.tpl.php</strong> file located in your theme directory and rename it to <strong>page-front.tpl.php</strong> and make some changes in the file. The changes will be visible only in the front page. So if you want to have different layout for your home page just change the structure of the <strong>page-front.tpl.php </strong>file according to your home page design.</p>
<p>A lot of dynamic templates are available in drupal. If you have a number of contents in your Drupal site,  you can have a separate layout or design for each of your contents. In Drupal each content has an ID associated with it, for example the first content has ID 1 and second has ID 2 and so on. you can find out the ID from the page URL. If you would like to have a separate layout for the content with ID 1, just create a copy of page template (page.tpl.php) file and rename it to  <strong>page-node-1.tpl.php</strong> and if you need a separate template for the content with ID 2, you can create a page template file with name <strong>page-node-2.tpl.php </strong>so you can have a separate layout for each of your contents. You can also use <strong>page-node-edit.tpl.php </strong>template file for editing the content in the site.</p>
<p>If you would like to have a separate layout for each of your node type, it is possible by creating a copy of your <strong>node.tpl.php</strong> and renaming it accordingly. Basically drupal has two node types Story and Page. If you want to have separate layout for each of these types, make two copies of node.tpl.php and rename as <strong>node-story.tpl.php</strong> and <strong>node-page.tpl.php </strong>and change the layout of both the files. All the story type contents will be rendered on the template file <strong>node-story.tpl.php</strong> and page type contents will be rendered on <strong>node-page.thp.php</strong> file.</p>
<p>You can also define dynamic templates for blocks based on the regions in the page. You can have a template for each of your regions. To do so create a copy of block.tpl.php file located in your theme directory and rename it in the format  <strong>block-[region-name].tpl.php, </strong>you have to use the the appropriate region name in the template file like  <strong>block-footer.tpl.php</strong> or <strong>block-left.tpl.php</strong> and change the structure of the new block template file. You will see the changes in the corresponding blocks.</p>
<p>You can also define a template for a module in a block for example if you want to define a layout a for the block of user module, you can use the dynamic template <strong>block-user.tpl.php </strong>in the format <strong>block-[module-name].tpl.php.</strong> If the user module has more than one block you use the block&#8217;s delta value to define the template, for example <strong>block-user-1.tpl.php </strong>or<strong>  <strong>block-user-2.tpl.php</strong>. </strong>You can find out the delta value of a block by checking its HTML code</p>
<pre> &lt;div class="block block-{module}" id="block-{module}-{delta}"&gt;</pre>
<p>You can also define a template for your comment section, you can have separate comment template for each node type in the.format <strong>comment-[nodetype].tpl.php </strong> example <strong>comment.story.tpl.php</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/08/17/dynamic-templates-in-drupal/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to set home page in drupal</title>
		<link>http://phpxpert.com/2011/08/11/how-to-set-home-page-in-drupal/</link>
		<comments>http://phpxpert.com/2011/08/11/how-to-set-home-page-in-drupal/#comments</comments>
		<pubDate>Thu, 11 Aug 2011 14:00:01 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[Drupal]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=7</guid>
		<description><![CDATA[Hi friends, Today I am going to show you how to set home page in a Drupal site. We can set the home page either from the admin panel or by using a page template (front page template). If you &#8230; <a href="http://phpxpert.com/2011/08/11/how-to-set-home-page-in-drupal/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Hi friends, Today I am going to show you how to set home page in a Drupal site. We can set the home page either from the admin panel or by using a page template (front page template). If you want to change the layout of the home page then creating a front page template is the prefered method.</p>
<p><span id="more-7"></span></p>
<p>After installing Drupal in the server or in your localhost, you will get a home page similar to the following image</p>
<p style="text-align: center;"><a href="http://phpxpert.com/wp-content/uploads/2011/08/drupal_default_home_page.gif"><img class="size-large wp-image-13 aligncenter" title="drupal_default_home_page" src="http://phpxpert.com/wp-content/uploads/2011/08/drupal_default_home_page-1024x492.gif" alt="drupal default home page" width="584" height="280" /></a></p>
<p>When you add your first content (story type) to drupal it comes to the front page as follows and if you want to read the entire content you have to click on the read more link.</p>
<p><a href="http://phpxpert.com/wp-content/uploads/2011/08/drupal_first_content.gif"><img class="aligncenter size-full wp-image-14" title="drupal_first_content" src="http://phpxpert.com/wp-content/uploads/2011/08/drupal_first_content.gif" alt="drupal first content" width="1024" height="493" /></a></p>
<p>when you add more contents to the site,  latest post comes to the top in front page as follows.</p>
<p><a href="http://phpxpert.com/wp-content/uploads/2011/08/drupal_contents.gif"><img class="aligncenter size-full wp-image-12" title="drupal contents" src="http://phpxpert.com/wp-content/uploads/2011/08/drupal_contents.gif" alt="" width="1024" height="472" /></a></p>
<p>If you need a particular node on home page then you can set it from the Drupal admin panel. Please got to Administrator &gt; Site configuration &gt; Site information. You will see a lot of configuration options in this page and at the bottom you can see <strong>Default front page </strong>You can set your default home page content from here. You have to use the node id to set a default home page. Each content has an ID associated with it, you can find the ID from the the content URL. Put the id of the node in the text box  as follows and Save configuration.</p>
<p><a href="http://phpxpert.com/wp-content/uploads/2011/08/drupal_front_page_configuration.gif"><img class="aligncenter size-full wp-image-15" title="drupal_front_page_configuration" src="http://phpxpert.com/wp-content/uploads/2011/08/drupal_front_page_configuration.gif" alt="" width="540" height="145" /></a></p>
<p>If you have a separate design or layout for the home page then you have to do something with the theme files. Currently my demo site using Garlent theme, and if you check the files in the Garlent theme folder, there is a file calld <strong>page.tpl.php</strong>. This page will be display the content section. By default this file is responsible for all the pages and if you need separate layout for the home page just make a copy of this file and rename it as <strong>page-front.tpl.php </strong>and change the layout of the second file. So the home page will  be following the second page template file page-front.tpl.php. If you want to know more about dynamic templates please read this post <a title="http://phpxpert.com/2011/08/17/dynamic-templates-in-drupal/" href="http://phpxpert.com/2011/08/17/dynamic-templates-in-drupal/">http://phpxpert.com/2011/08/17/dynamic-templates-in-drupal/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/08/11/how-to-set-home-page-in-drupal/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to include stylesheets only for Internet explorer</title>
		<link>http://phpxpert.com/2011/07/24/how-to-include-stylesheets-only-for-internet-explorer/</link>
		<comments>http://phpxpert.com/2011/07/24/how-to-include-stylesheets-only-for-internet-explorer/#comments</comments>
		<pubDate>Sun, 24 Jul 2011 14:10:31 +0000</pubDate>
		<dc:creator>Joyal</dc:creator>
				<category><![CDATA[CSS]]></category>

		<guid isPermaLink="false">http://phpxpert.com/?p=126</guid>
		<description><![CDATA[Sometimes we may need to include style sheets only for Internet explorer and it is possible to do so by using CSS conditional comments. Conditional comments allows us to load style sheet only for Internet explorer and also for specific &#8230; <a href="http://phpxpert.com/2011/07/24/how-to-include-stylesheets-only-for-internet-explorer/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Sometimes we may need to include style sheets only for Internet explorer and it is possible to do so by using CSS conditional comments. Conditional comments allows us to load style sheet only for Internet explorer and also for specific version of Internet explorer.</p>
<p><span id="more-126"></span></p>
<p>The following CSS code includes the style sheet <strong><em>stylesheet-ie.css</em></strong> in all versions on internet explorer.</p>
<pre class="brush: css; title: ; notranslate">
&lt;!--[if IE]&gt;
	&lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;stylesheet-ie.css&quot; /&gt;
&lt; ![endif]--&gt;
</pre>
<p>It is possible to load style sheets for a specific version of Internet explorer. Fox example the following code include the style sheet for <strong><em>stylesheet-ie7.css</em></strong> IE7 only </p>
<pre class="brush: css; title: ; notranslate">
&lt;!--[if IE 7]&gt;
	&lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;stylesheet-ie7.css&quot; /&gt;
&lt; ![endif]--&gt;
</pre>
<p>It is also possible to add conditional statements for targeting more than one version of internet explorer.</p>
<pre class="brush: css; title: ; notranslate">
&lt;!--[if gt IE 7]&gt; file path  &lt;![endif]--&gt;  targets IE8 and above
&lt;!--[if lt IE 7]&gt; file path  &lt;![endif]--&gt; targets IE6 and below
&lt;!--[if gte IE 7]&gt; file path &lt;![endif]--&gt; targets IE7 and above
&lt;!--[if lte IE 7]&gt; file path &lt;![endif]--&gt; targets IE7 and below
</pre>
<p>Thanks</p>
]]></content:encoded>
			<wfw:commentRss>http://phpxpert.com/2011/07/24/how-to-include-stylesheets-only-for-internet-explorer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

