<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Mukesh Chapagain's Blog</title>
	
	<link>http://blog.chapagain.com.np</link>
	<description>PHP Magento jQuery Wordpress Javascript programming n tutorial</description>
	<lastBuildDate>Tue, 07 Sep 2010 06:18:09 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/chapagainblog" /><feedburner:info uri="chapagainblog" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:emailServiceId>chapagainblog</feedburner:emailServiceId><feedburner:feedburnerHostname>http://feedburner.google.com</feedburner:feedburnerHostname><item>
		<title>Magento: How to change the ‘Default welcome msg!’</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/O6sNThAlVrg/</link>
		<comments>http://blog.chapagain.com.np/magento-how-to-change-the-default-welcome-msg/#comments</comments>
		<pubDate>Tue, 07 Sep 2010 06:18:09 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=935</guid>
		<description><![CDATA[Here is a quick tip to change the Default welcome message that appears in header of Magento shop.
When the user is not logged in, the message appears as &#8216;Default welcome msg!&#8216;.
To change the message text, follow steps below:-

- Go to
System -> Configuration -> GENERAL -> Design -> Header -> Welcome Text = YOUR WELCOME TEXT
That&#8217;s all. Now, the default welcome message is changed with your custom welcome message :)
Hope this helps. Thanks.

From Mukesh Chapagain&#039;s Blog &#124; Post Magento: How to change the &#8216;Default welcome msg!&#8217;

Copyright &#169; 2010 This feed is ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-setup-multiple-website/' rel='bookmark' title='Permanent Link: Magento: Setup Multiple Website'>Magento: Setup Multiple Website</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-change-currency-symbol/' rel='bookmark' title='Permanent Link: Magento: How to change Currency symbol ?'>Magento: How to change Currency symbol ?</a></li>
<li><a href='http://blog.chapagain.com.np/magento-setup-multiple-currency-shop/' rel='bookmark' title='Permanent Link: Magento: Setup multiple currency shop'>Magento: Setup multiple currency shop</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Here is a quick tip to change the Default welcome message that appears in header of Magento shop.</p>
<p>When the user is not logged in, the message appears as &#8216;<strong>Default welcome msg!</strong>&#8216;.</p>
<p>To change the message text, follow steps below:-</p>
<p><span id="more-935"></span></p>
<p>- Go to<br />
<strong>System -> Configuration -> GENERAL -> Design -> Header -> Welcome Text = YOUR WELCOME TEXT</strong></p>
<p>That&#8217;s all. Now, the default welcome message is changed with your custom welcome message :)</p>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-how-to-change-the-default-welcome-msg/">Magento: How to change the &#8216;Default welcome msg!&#8217;</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=935&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-setup-multiple-website/' rel='bookmark' title='Permanent Link: Magento: Setup Multiple Website'>Magento: Setup Multiple Website</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-change-currency-symbol/' rel='bookmark' title='Permanent Link: Magento: How to change Currency symbol ?'>Magento: How to change Currency symbol ?</a></li>
<li><a href='http://blog.chapagain.com.np/magento-setup-multiple-currency-shop/' rel='bookmark' title='Permanent Link: Magento: Setup multiple currency shop'>Magento: Setup multiple currency shop</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-how-to-change-the-default-welcome-msg/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-how-to-change-the-default-welcome-msg/</feedburner:origLink></item>
		<item>
		<title>Magento: Showing Store Selector / Switcher in header and footer</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/mgcdjXri9wY/</link>
		<comments>http://blog.chapagain.com.np/magento-showing-store-selector-switcher-in-header-and-footer/#comments</comments>
		<pubDate>Sun, 29 Aug 2010 11:42:16 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[footer]]></category>
		<category><![CDATA[header]]></category>
		<category><![CDATA[store selector]]></category>
		<category><![CDATA[store switcher]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=855</guid>
		<description><![CDATA[Here, I will show you how to show the store selector (store switcher) in header. By default, the store selector is present in footer.
Create a new phtml file (template/page/switch/stores-top.phtml) and write the following code in it :-


&#60;?php if(count($this-&#62;getGroups())&#62;1): ?&#62;
&#60;div class=&#34;language-switcher&#34; style=&#34;margin-left:15px&#34;&#62;
    &#60;label for=&#34;select-store&#34;&#62;&#60;?php echo $this-&#62;__('Select Store') ?&#62;: &#60;/label&#62;
    &#60;select id=&#34;select-store&#34; onchange=&#34;location.href=this.value&#34;&#62;
    &#60;?php /*foreach ($this-&#62;getStores() as $_store): ?&#62;
        &#60;option value=&#34;&#60;?php echo $_store-&#62;getUrl('') ?&#62;&#34;&#60;?php if($_store-&#62;getId()==$this-&#62;getCurrentStoreId()): ?&#62; selected=&#34;selected&#34;&#60;?php endif; ?&#62;&#62;&#60;?php echo $_store-&#62;getName() ?&#62;&#60;/option&#62;
    &#60;?php ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-show-currency-selector-in-header/' rel='bookmark' title='Permanent Link: Magento: Show Currency Selector in header'>Magento: Show Currency Selector in header</a></li>
<li><a href='http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/' rel='bookmark' title='Permanent Link: Magento: Show Currency Selector in right sidebar'>Magento: Show Currency Selector in right sidebar</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-call-static-block-from-template-file/' rel='bookmark' title='Permanent Link: Magento: How to call static block from template file?'>Magento: How to call static block from template file?</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Here, I will show you how to show the store selector (store switcher) in header. By default, the store selector is present in footer.</p>
<p>Create a new phtml file (<strong>template/page/switch/stores-top.phtml</strong>) and write the following code in it :-</p>
<p><span id="more-855"></span></p>
<pre class="brush: php;">
&lt;?php if(count($this-&gt;getGroups())&gt;1): ?&gt;
&lt;div class=&quot;language-switcher&quot; style=&quot;margin-left:15px&quot;&gt;
    &lt;label for=&quot;select-store&quot;&gt;&lt;?php echo $this-&gt;__('Select Store') ?&gt;: &lt;/label&gt;
    &lt;select id=&quot;select-store&quot; onchange=&quot;location.href=this.value&quot;&gt;
    &lt;?php /*foreach ($this-&gt;getStores() as $_store): ?&gt;
        &lt;option value=&quot;&lt;?php echo $_store-&gt;getUrl('') ?&gt;&quot;&lt;?php if($_store-&gt;getId()==$this-&gt;getCurrentStoreId()): ?&gt; selected=&quot;selected&quot;&lt;?php endif; ?&gt;&gt;&lt;?php echo $_store-&gt;getName() ?&gt;&lt;/option&gt;
    &lt;?php endforeach;*/ ?&gt;
    &lt;?php foreach ($this-&gt;getGroups() as $_group): ?&gt;
        &lt;?php $_selected = ($_group-&gt;getId()==$this-&gt;getCurrentGroupId()) ? 'selected=&quot;selected&quot;' : '' ?&gt;
        &lt;option value=&quot;&lt;?php echo $_group-&gt;getHomeUrl() ?&gt;&quot; &lt;?php echo $_selected ?&gt;&gt;&lt;?php echo $this-&gt;htmlEscape($_group-&gt;getName()) ?&gt;&lt;/option&gt;
    &lt;?php endforeach; ?&gt;
    &lt;/select&gt;
&lt;/div&gt;
&lt;?php endif; ?&gt;
</pre>
<p>Add <strong>store_switcher_top</strong> block after <strong>store_language</strong> block inside header block of <strong>page.xml</strong> present around line #66 :-</p>
<pre class="brush: xml;">
&lt;block type=&quot;page/html_header&quot; name=&quot;header&quot; as=&quot;header&quot;&gt;
	&lt;block type=&quot;page/template_links&quot; name=&quot;top.links&quot; as=&quot;topLinks&quot;/&gt;
	&lt;block type=&quot;page/switch&quot; name=&quot;store_language&quot; as=&quot;store_language&quot; template=&quot;page/switch/languages.phtml&quot;/&gt;
	&lt;block type=&quot;page/switch&quot; name=&quot;store_switcher_top&quot; as=&quot;store_switcher_top&quot; template=&quot;page/switch/stores-top.phtml&quot;/&gt;
	&lt;block type=&quot;core/text_list&quot; name=&quot;top.menu&quot; as=&quot;topMenu&quot;/&gt;
&lt;/block&gt;
</pre>
<p>Add <strong>getChildHtml(&#8217;store_switcher_top&#8217;)</strong> below <strong>getChildHtml(&#8217;store_language&#8217;)</strong> in <strong>template/page/html/header.phtml</strong> like below :-</p>
<pre class="brush: php;">
&lt;?php echo $this-&gt;getChildHtml('store_language') ?&gt;
&lt;?php echo $this-&gt;getChildHtml('store_switcher_top') ?&gt;
</pre>
<p>That&#8217;s all. Now, you can see store selector in header and footer both.</p>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-showing-store-selector-switcher-in-header-and-footer/">Magento: Showing Store Selector / Switcher in header and footer</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=855&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-show-currency-selector-in-header/' rel='bookmark' title='Permanent Link: Magento: Show Currency Selector in header'>Magento: Show Currency Selector in header</a></li>
<li><a href='http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/' rel='bookmark' title='Permanent Link: Magento: Show Currency Selector in right sidebar'>Magento: Show Currency Selector in right sidebar</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-call-static-block-from-template-file/' rel='bookmark' title='Permanent Link: Magento: How to call static block from template file?'>Magento: How to call static block from template file?</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-showing-store-selector-switcher-in-header-and-footer/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-showing-store-selector-switcher-in-header-and-footer/</feedburner:origLink></item>
		<item>
		<title>Magento: Show Currency Selector in header</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/7KUYeLPuK1I/</link>
		<comments>http://blog.chapagain.com.np/magento-show-currency-selector-in-header/#comments</comments>
		<pubDate>Wed, 25 Aug 2010 11:55:27 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[currency selector]]></category>
		<category><![CDATA[header]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=851</guid>
		<description><![CDATA[Here, I will show you how you can change the location of currency selector to header in Magento. 
By default, the currency selector is displayed in the left sidebar. Here, I will show you how you can show it in header just below the language selector.
Create a new phtml file (template/directory/currency-top.phtml) and write the following code in it :-


&#60;?php if($this-&#62;getCurrencyCount()&#62;1): ?&#62;
&#60;div class=&#34;box language-switcher&#34; style=&#34;margin-left:15px&#34;&#62;
    &#60;label for=&#34;select-language&#34;&#62;Your Currency: &#60;/label&#62;
        &#60;select name=&#34;currency&#34; onchange=&#34;changeCurrency(this)&#34;&#62;
        &#60;?php foreach ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-showing-store-selector-switcher-in-header-and-footer/' rel='bookmark' title='Permanent Link: Magento: Showing Store Selector / Switcher in header and footer'>Magento: Showing Store Selector / Switcher in header and footer</a></li>
<li><a href='http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/' rel='bookmark' title='Permanent Link: Magento: Show Currency Selector in right sidebar'>Magento: Show Currency Selector in right sidebar</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-get-currency-rates/' rel='bookmark' title='Permanent Link: Magento: How to get Currency Rates?'>Magento: How to get Currency Rates?</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Here, I will show you how you can change the location of currency selector to header in Magento. </p>
<p>By default, the currency selector is displayed in the left sidebar. Here, I will show you how you can show it in header just below the language selector.</p>
<p>Create a new phtml file (<strong>template/directory/currency-top.phtml</strong>) and write the following code in it :-</p>
<p><span id="more-851"></span></p>
<pre class="brush: php;">
&lt;?php if($this-&gt;getCurrencyCount()&gt;1): ?&gt;
&lt;div class=&quot;box language-switcher&quot; style=&quot;margin-left:15px&quot;&gt;
    &lt;label for=&quot;select-language&quot;&gt;Your Currency: &lt;/label&gt;
        &lt;select name=&quot;currency&quot; onchange=&quot;changeCurrency(this)&quot;&gt;
        &lt;?php foreach ($this-&gt;getCurrencies() as $_code =&gt; $_name): ?&gt;
            &lt;option value=&quot;&lt;?php echo $_code ?&gt;&quot;&lt;?php if($_code==$this-&gt;getCurrentCurrencyCode()): ?&gt; selected=&quot;selected&quot;&lt;?php endif; ?&gt;&gt;
                &lt;?php echo $_name ?&gt; - &lt;?php echo $_code ?&gt;
            &lt;/option&gt;
        &lt;?php endforeach; ?&gt;
        &lt;/select&gt;
&lt;/div&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
//&lt;![CDATA[
function changeCurrency(sObject){
    if(sObject.value){
        setLocation('&lt;?php echo $this-&gt;helper('directory/url')-&gt;getSwitchCurrencyUrl() ?&gt;currency/'+sObject.value);
    }
}
//]]&gt;
&lt;/script&gt;
&lt;?php endif; ?&gt;
</pre>
<p>Add <strong>currency_top</strong> block after <strong>store_language</strong> block inside header block of <strong>page.xml</strong> present around line #66 :-</p>
<pre class="brush: xml;">
&lt;block type=&quot;page/html_header&quot; name=&quot;header&quot; as=&quot;header&quot;&gt;
	&lt;block type=&quot;page/template_links&quot; name=&quot;top.links&quot; as=&quot;topLinks&quot;/&gt;
	&lt;block type=&quot;page/switch&quot; name=&quot;store_language&quot; as=&quot;store_language&quot; template=&quot;page/switch/languages.phtml&quot;/&gt;
	&lt;block type=&quot;directory/currency&quot; name=&quot;currency_top&quot; template=&quot;directory/currency-top.phtml&quot;/&gt;
	&lt;block type=&quot;core/text_list&quot; name=&quot;top.menu&quot; as=&quot;topMenu&quot;/&gt;
&lt;/block&gt;
</pre>
<p>Add <strong>getChildHtml(&#8216;currency_top&#8217;)</strong> below <strong>getChildHtml(&#8217;store_language&#8217;)</strong> in <strong>template/page/html/header.phtml</strong> like below :-</p>
<pre class="brush: php;">
&lt;?php echo $this-&gt;getChildHtml('store_language') ?&gt;
&lt;?php echo $this-&gt;getChildHtml('currency_top') ?&gt;
</pre>
<p>That&#8217;s all. Now, you will be able to see currency selector in the header of your site.</p>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-show-currency-selector-in-header/">Magento: Show Currency Selector in header</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=851&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-showing-store-selector-switcher-in-header-and-footer/' rel='bookmark' title='Permanent Link: Magento: Showing Store Selector / Switcher in header and footer'>Magento: Showing Store Selector / Switcher in header and footer</a></li>
<li><a href='http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/' rel='bookmark' title='Permanent Link: Magento: Show Currency Selector in right sidebar'>Magento: Show Currency Selector in right sidebar</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-get-currency-rates/' rel='bookmark' title='Permanent Link: Magento: How to get Currency Rates?'>Magento: How to get Currency Rates?</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-show-currency-selector-in-header/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-show-currency-selector-in-header/</feedburner:origLink></item>
		<item>
		<title>Magento: Show Currency Selector in right sidebar</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/IUt1bSfiIzA/</link>
		<comments>http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/#comments</comments>
		<pubDate>Sat, 21 Aug 2010 12:17:46 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[currency selector]]></category>
		<category><![CDATA[sidebar]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=849</guid>
		<description><![CDATA[Here, I will show you how you can change the location of currency selector in Magento. 
By default, the currency selector is displayed in the left sidebar. Here, I will show you how you can show it in right sidebar.
Showing currency selector in product view detail page

Put the following code in layout/directory.xml

&#60;!--
Product default layout
--&#62;

&#60;catalog_product_view&#62;
	&#60;reference name=&#34;right&#34;&#62;
		&#60;block type=&#34;directory/currency&#34; name=&#34;currency&#34; before=&#34;-&#34; template=&#34;directory/currency.phtml&#34;/&#62;
	&#60;/reference&#62;
&#60;/catalog_product_view&#62;

Showing currency selector in homepage
Go to Admin Panel -> CMS -> Manage Pages -> Edit Homepage
Click Custom Design tab in left sidebar
Write the following code in Layout Update XML box.

&#60;reference name=&#34;right&#34;&#62;
	&#60;block type=&#34;directory/currency&#34; ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-show-currency-selector-in-header/' rel='bookmark' title='Permanent Link: Magento: Show Currency Selector in header'>Magento: Show Currency Selector in header</a></li>
<li><a href='http://blog.chapagain.com.np/magento-setchange-page-layout-title-tag-meta-keywords-and-description/' rel='bookmark' title='Permanent Link: Magento: Set/Change page layout, title tag, meta keywords and description'>Magento: Set/Change page layout, title tag, meta keywords and description</a></li>
<li><a href='http://blog.chapagain.com.np/magento-showing-store-selector-switcher-in-header-and-footer/' rel='bookmark' title='Permanent Link: Magento: Showing Store Selector / Switcher in header and footer'>Magento: Showing Store Selector / Switcher in header and footer</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Here, I will show you how you can change the location of currency selector in Magento. </p>
<p>By default, the currency selector is displayed in the left sidebar. Here, I will show you how you can show it in right sidebar.</p>
<p><strong>Showing currency selector in product view detail page</strong></p>
<p><span id="more-849"></span></p>
<p>Put the following code in <strong>layout/directory.xml</strong></p>
<pre class="brush: xml;">
&lt;!--
Product default layout
--&gt;

&lt;catalog_product_view&gt;
	&lt;reference name=&quot;right&quot;&gt;
		&lt;block type=&quot;directory/currency&quot; name=&quot;currency&quot; before=&quot;-&quot; template=&quot;directory/currency.phtml&quot;/&gt;
	&lt;/reference&gt;
&lt;/catalog_product_view&gt;
</pre>
<p><strong>Showing currency selector in homepage</strong></p>
<p>Go to <strong>Admin Panel -> CMS -> Manage Pages -> Edit Homepage</strong></p>
<p>Click <strong>Custom Design</strong> tab in left sidebar</p>
<p>Write the following code in <strong>Layout Update XML</strong> box.</p>
<pre class="brush: xml;">
&lt;reference name=&quot;right&quot;&gt;
	&lt;block type=&quot;directory/currency&quot; name=&quot;currency&quot; before=&quot;-&quot; template=&quot;directory/currency.phtml&quot;/&gt;
&lt;/reference&gt;
</pre>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/">Magento: Show Currency Selector in right sidebar</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=849&type=feed" alt="" />

<p>No related posts.</p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-show-currency-selector-in-right-sidebar/</feedburner:origLink></item>
		<item>
		<title>Magento: Recoverable Error: Argument 1 passed to Mage_Core_Model_Store :: setWebsite() must be an instance of Mage_Core_Model_Website</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/klqJ8e0AaLI/</link>
		<comments>http://blog.chapagain.com.np/magento-recoverable-error-argument-1-passed-to-mage_core_model_store-setwebsite-must-be-an-instance-of-mage_core_model_website/#comments</comments>
		<pubDate>Tue, 17 Aug 2010 10:43:05 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=919</guid>
		<description><![CDATA[Problem:
I was transfering Magento files and database from one server to another. I did complete all the transfer process of files and also exported and imported the database. After that, when I tried to access the site, I got the following error:-
Recoverable Error: Argument 1 passed to Mage_Core_Model_Store::setWebsite() must be an instance of Mage_Core_Model_Website, null given, called in /path/app/code/core/Mage/Core/Model/App.php on line 427 and defined  in /path/app/code/core/Mage/Core/Model/Store.php on line 279

Solution:
It&#8217;s very simple. Although I had to search for sometime for the solution. :)
Delete the following file:-
app/etc/use_cache.ser
That&#8217;s it. You are done. ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-error-%e2%80%93-notice-undefined-index-0-appcodecoremagecoremodelmysql4config-php-on-line-92/' rel='bookmark' title='Permanent Link: Magento Error – Notice: Undefined index: 0 app/code/core/Mage/Core/Model/Mysql4/Config.php on line 92'>Magento Error – Notice: Undefined index: 0 app/code/core/Mage/Core/Model/Mysql4/Config.php on line 92</a></li>
<li><a href='http://blog.chapagain.com.np/magento-product-edit-warning-invalid-argument-supplied-for-foreach/' rel='bookmark' title='Permanent Link: Magento: Product Edit Warning: Invalid argument supplied for foreach()'>Magento: Product Edit Warning: Invalid argument supplied for foreach()</a></li>
<li><a href='http://blog.chapagain.com.np/magento-admin-login-problem/' rel='bookmark' title='Permanent Link: Magento Admin login problem'>Magento Admin login problem</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p><strong>Problem:</strong></p>
<p>I was transfering Magento files and database from one server to another. I did complete all the transfer process of files and also exported and imported the database. After that, when I tried to access the site, I got the following error:-</p>
<blockquote><p>Recoverable Error: Argument 1 passed to Mage_Core_Model_Store::setWebsite() must be an instance of Mage_Core_Model_Website, null given, called in /path/app/code/core/Mage/Core/Model/App.php on line 427 and defined  in /path/app/code/core/Mage/Core/Model/Store.php on line 279</p></blockquote>
<p><span id="more-919"></span></p>
<p><strong>Solution:</strong></p>
<p>It&#8217;s very simple. Although I had to search for sometime for the solution. :)</p>
<p>Delete the following file:-</p>
<blockquote><p>app/etc/use_cache.ser</p></blockquote>
<p>That&#8217;s it. You are done. Now, you can access your site.</p>
<p>After doing this, you might get the next error which says:-</p>
<blockquote><p>Notice: Undefined index:  0  in /srv/www/vhosts/javra.com/htdocs/munchad2/app/code/core/Mage/Core/Model/Mysql4/Config.php on line 92</p></blockquote>
<p>If you get this error then please have a look at the solution for this error over here:- </p>
<blockquote><p><a href="http://blog.chapagain.com.np/magento-error-%E2%80%93-notice-undefined-index-0-appcodecoremagecoremodelmysql4config-php-on-line-92/" target="_blank">http://blog.chapagain.com.np/magento-error-%E2%80%93-notice-undefined-index-0-appcodecoremagecoremodelmysql4config-php-on-line-92/</a></p></blockquote>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-recoverable-error-argument-1-passed-to-mage_core_model_store-setwebsite-must-be-an-instance-of-mage_core_model_website/">Magento: Recoverable Error: Argument 1 passed to Mage_Core_Model_Store :: setWebsite() must be an instance of Mage_Core_Model_Website</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=919&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-error-%e2%80%93-notice-undefined-index-0-appcodecoremagecoremodelmysql4config-php-on-line-92/' rel='bookmark' title='Permanent Link: Magento Error – Notice: Undefined index: 0 app/code/core/Mage/Core/Model/Mysql4/Config.php on line 92'>Magento Error – Notice: Undefined index: 0 app/code/core/Mage/Core/Model/Mysql4/Config.php on line 92</a></li>
<li><a href='http://blog.chapagain.com.np/magento-product-edit-warning-invalid-argument-supplied-for-foreach/' rel='bookmark' title='Permanent Link: Magento: Product Edit Warning: Invalid argument supplied for foreach()'>Magento: Product Edit Warning: Invalid argument supplied for foreach()</a></li>
<li><a href='http://blog.chapagain.com.np/magento-admin-login-problem/' rel='bookmark' title='Permanent Link: Magento Admin login problem'>Magento Admin login problem</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-recoverable-error-argument-1-passed-to-mage_core_model_store-setwebsite-must-be-an-instance-of-mage_core_model_website/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-recoverable-error-argument-1-passed-to-mage_core_model_store-setwebsite-must-be-an-instance-of-mage_core_model_website/</feedburner:origLink></item>
		<item>
		<title>Magento: How to select, insert, update, and delete data?</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/Unv4uN-ejFo/</link>
		<comments>http://blog.chapagain.com.np/magento-how-to-select-insert-update-and-delete-data/#comments</comments>
		<pubDate>Mon, 16 Aug 2010 12:36:29 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[crud]]></category>
		<category><![CDATA[data]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=916</guid>
		<description><![CDATA[Here, I will be showing how to select, insert/add, update/edit and delete data in the Magento way. It&#8217;s about implementing the CRUD (Create Read Update Delete) concept. :)
Suppose, I have a database table named &#8216;news&#8216; with the following fields:-

id : int, auto increment, primary key
title : varchar
content : text
status : 0 or 1
Suppose, I have a module named &#8216;mynews&#8216;. Here follows the code to select, insert, update, and delete data from the &#8216;news&#8216; table.
INSERT DATA
$data contains array of data to be inserted. The key of the array should be the ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-create-read-delete-cookie/' rel='bookmark' title='Permanent Link: Magento: Create, read, delete cookie'>Magento: Create, read, delete cookie</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-delete-system-attribute/' rel='bookmark' title='Permanent Link: Magento: How to delete System Attribute?'>Magento: How to delete System Attribute?</a></li>
<li><a href='http://blog.chapagain.com.np/how-to-install-sample-data-for-magento/' rel='bookmark' title='Permanent Link: How to Install Sample Data for Magento?'>How to Install Sample Data for Magento?</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Here, I will be showing how to select, insert/add, update/edit and delete data in the Magento way. It&#8217;s about implementing the CRUD (Create Read Update Delete) concept. :)</p>
<p>Suppose, I have a database table named &#8216;<strong>news</strong>&#8216; with the following fields:-</p>
<p><span id="more-916"></span></p>
<p>id : int, auto increment, primary key<br />
title : varchar<br />
content : text<br />
status : 0 or 1</p>
<p>Suppose, I have a module named &#8216;<strong>mynews</strong>&#8216;. Here follows the code to select, insert, update, and delete data from the &#8216;<strong>news</strong>&#8216; table.</p>
<p><strong>INSERT DATA</strong></p>
<p><strong>$data</strong> contains array of data to be inserted. The key of the array should be the database table&#8217;s field name and the value should be the value to be inserted.</p>
<pre class="brush: php;">
$data = array('title'=&gt;'hello there','content'=&gt;'how are you? i am fine over here.','status'=&gt;1);
$model = Mage::getModel('mynews/mynews')-&gt;setData($data);
try {
		$insertId = $model-&gt;save()-&gt;getId();
		echo &quot;Data successfully inserted. Insert ID: &quot;.$insertId;
	} catch (Exception $e){
	 echo $e-&gt;getMessage();
}
</pre>
<p><strong>SELECT DATA</strong></p>
<p><strong>$item->getData()</strong> prints array of data from &#8216;news&#8217; table.<br />
<strong>$item->getTitle()</strong> prints the only the title field.<br />
Similarly, to print content, we need to write <strong>$item->getContent()</strong>. </p>
<pre class="brush: php;">
$model = Mage::getModel('mynews/mynews');
$collection = $model-&gt;getCollection();
foreach($collection as $item){
	print_r($item-&gt;getData());
	print_r($item-&gt;getTitle());
}
</pre>
<p><strong>UPDATE DATA</strong></p>
<p><strong>$id</strong> is the database table row id to be updated.<br />
<strong>$data</strong> contains array of data to be updated. The key of the array should be the database table&#8217;s field name and the value should be the value to be updated.</p>
<pre class="brush: php;">
// $id = $this-&gt;getRequest()-&gt;getParam('id');
$id = 2;
$data = array('title'=&gt;'hello test','content'=&gt;'test how are you?','status'=&gt;0);
$model = Mage::getModel('mynews/mynews')-&gt;load($id)-&gt;addData($data);
try {
		$model-&gt;setId($id)-&gt;save();
		echo &quot;Data updated successfully.&quot;;

	} catch (Exception $e){
		echo $e-&gt;getMessage();
}
</pre>
<p><strong>DELETE DATA</strong></p>
<p><strong>$id</strong> is the database table row id to be deleted.</p>
<pre class="brush: php;">
// $id = $this-&gt;getRequest()-&gt;getParam('id');
$id = 3;
$model = Mage::getModel('mynews/mynews');
try {
		$model-&gt;setId($id)-&gt;delete();
		echo &quot;Data deleted successfully.&quot;;

	} catch (Exception $e){
		echo $e-&gt;getMessage();
}
</pre>
<p>In this way you can perform select, insert, update and delete in your custom module and in any magento code.</p>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-how-to-select-insert-update-and-delete-data/">Magento: How to select, insert, update, and delete data?</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=916&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-create-read-delete-cookie/' rel='bookmark' title='Permanent Link: Magento: Create, read, delete cookie'>Magento: Create, read, delete cookie</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-delete-system-attribute/' rel='bookmark' title='Permanent Link: Magento: How to delete System Attribute?'>Magento: How to delete System Attribute?</a></li>
<li><a href='http://blog.chapagain.com.np/how-to-install-sample-data-for-magento/' rel='bookmark' title='Permanent Link: How to Install Sample Data for Magento?'>How to Install Sample Data for Magento?</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-how-to-select-insert-update-and-delete-data/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-how-to-select-insert-update-and-delete-data/</feedburner:origLink></item>
		<item>
		<title>Magento: Setup Multiple Website</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/9EHzXczmmHk/</link>
		<comments>http://blog.chapagain.com.np/magento-setup-multiple-website/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 06:38:33 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[localhost]]></category>
		<category><![CDATA[multiple]]></category>
		<category><![CDATA[website]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=847</guid>
		<description><![CDATA[In this article, you will learn about creating multiple website in Magento.
Creating or setting up multiple stores in Magento is somehow easy but creating/setting up multiple website in Magento is a bit difficult task :).
This step-by-step tutorial will guide you to do so.

I suppose that you have installed Magento in folder named &#8216;magento&#8217;. So, your website URL will be http://yourwebsite.com/magento/
- Create Website, Store, and Store View
- Create Website
- Go to System &#8211;> Manage Stores
- Create Website
- Name = My Website
- Code = mywebsite
- Sort Order = 10
- Save Website
- Create ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-setup-multiple-currency-shop/' rel='bookmark' title='Permanent Link: Magento: Setup multiple currency shop'>Magento: Setup multiple currency shop</a></li>
<li><a href='http://blog.chapagain.com.np/aspnet-error-an-htmlselect-cannot-have-multiple-items-selected-when-multiple-is-false/' rel='bookmark' title='Permanent Link: ASP.NET Error : An HtmlSelect cannot have multiple items selected when Multiple is false.'>ASP.NET Error : An HtmlSelect cannot have multiple items selected when Multiple is false.</a></li>
<li><a href='http://blog.chapagain.com.np/magento-load-store-specific-product/' rel='bookmark' title='Permanent Link: Magento: Load store specific product'>Magento: Load store specific product</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>In this article, you will learn about creating multiple website in Magento.</p>
<p>Creating or setting up multiple stores in Magento is somehow easy but creating/setting up multiple website in Magento is a bit difficult task :).</p>
<p>This step-by-step tutorial will guide you to do so.</p>
<p><span id="more-847"></span></p>
<p>I suppose that you have installed Magento in folder named <strong>&#8216;magento&#8217;</strong>. So, your website URL will be <strong>http://yourwebsite.com/magento/</strong></p>
<p><strong>- Create Website, Store, and Store View</strong></p>
<p>- Create Website<br />
- Go to System &#8211;> Manage Stores<br />
- Create Website<br />
- Name = My Website<br />
- Code = mywebsite<br />
- Sort Order = 10<br />
- Save Website</p>
<p>- Create Store<br />
- Go to System -&gt; Manage Stores<br />
- Create Store<br />
- Website = My Website<br />
- Name = Main Store<br />
- Root Category = Root Catalog</p>
<p>- Create Store View<br />
- Go to System -&gt; Manage Stores<br />
- Create Store View<br />
- Store = My Website -&gt; Main Store<br />
- Name = English<br />
- Code = English<br />
- Status = Enabled<br />
- Sort Order = 10</p>
<p><strong>- Change Link URL</strong><br />
- Go to System -&gt; Configuration -&gt; GENERAL -&gt; Web<br />
- Change &#8216;Current Configuration Scope&#8217; to &#8216;My Website&#8217;<br />
- Unsecure -&gt; Base URL = http://yourwebsite.com/magento/<br />
- Unsecure -&gt; Base Link URL = http://yourwebsite.com/magento/mywebsite/</p>
<p><strong>- Change Theme (Optional: If you want different design for your new website)</strong></p>
<p>- Suppose your new design template and skin folder is named &#8216;mywebsite&#8217;<br />
- Copy &#8216;mywebsite&#8217; template folder to magento/app/design/frontend/default/<br />
- Copy &#8216;mywebsite&#8217; skin folder to magento/skin/frontend/default/</p>
<p>- Go to System -&gt; Configuration -&gt; GENERAL -&gt; Design<br />
- Change &#8216;Current Configuration Scope&#8217; to &#8216;My Website&#8217;<br />
- Themes -&gt; Default = &#8216;mywebsite&#8217;<br />
- Uncheck &#8216;Use Default&#8217;<br />
- Save Config</p>
<p><strong>- Create a new folder named &#8216;mywebsite&#8217; inside &#8216;magento&#8217; folder.</strong></p>
<p><strong>- Copy index.php of magento folder into mywebsite folder.</strong></p>
<p><strong>- Open index.php of mywebsite folder.</strong><br />
- Change $compilerConfig = &#8216;includes/config.php&#8217;; to $compilerConfig = &#8216;../includes/config.php&#8217;;<br />
- Change $mageFilename = &#8216;app/Mage.php&#8217;; to $mageFilename = &#8216;../app/Mage.php&#8217;;<br />
- Change Mage::run(); to Mage::run(&#8216;mywebsite&#8217;,'website&#8217;);</p>
<p><strong>- Copy .htaccess file from magento folder to mywebsite folder</strong></p>
<p>Finally, you have created a new website for your magento shop. Your base installation can be browsed by http://yourwebsite.com/magento/ and your new website can be browsed by <strong>http://yourwebsite.com/magento/mywebsite/</strong></p>
<p>Hope this helps. Thanks.
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-setup-multiple-website/">Magento: Setup Multiple Website</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=847&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-setup-multiple-currency-shop/' rel='bookmark' title='Permanent Link: Magento: Setup multiple currency shop'>Magento: Setup multiple currency shop</a></li>
<li><a href='http://blog.chapagain.com.np/aspnet-error-an-htmlselect-cannot-have-multiple-items-selected-when-multiple-is-false/' rel='bookmark' title='Permanent Link: ASP.NET Error : An HtmlSelect cannot have multiple items selected when Multiple is false.'>ASP.NET Error : An HtmlSelect cannot have multiple items selected when Multiple is false.</a></li>
<li><a href='http://blog.chapagain.com.np/magento-load-store-specific-product/' rel='bookmark' title='Permanent Link: Magento: Load store specific product'>Magento: Load store specific product</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-setup-multiple-website/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-setup-multiple-website/</feedburner:origLink></item>
		<item>
		<title>Magento: PayPal Website Payments Standard not displayed</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/13-bN_sihFo/</link>
		<comments>http://blog.chapagain.com.np/magento-paypal-website-payments-standard-not-displayed/#comments</comments>
		<pubDate>Mon, 09 Aug 2010 09:19:18 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[currency]]></category>
		<category><![CDATA[payment]]></category>
		<category><![CDATA[paypal]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=910</guid>
		<description><![CDATA[Problem:
I am having problem in displaying PayPal payment method in payment method section of onepage checkout in Magento.
I am using &#8220;PayPal Website Payments Standard&#8220;.

I have enabled this module from backend (System -> Configuration -> SALES -> Payment Methods -> PayPal Website Payments Standard).
I have also entered the Business Name and Business Account at &#8220;Website Payments Standard&#8221; (System -> Configuration -> SALES -> PayPal Accounts -> Website Payments Standard). I have set Sandbox Flag = Yes and Debug Flag = Yes. I am using Sandbox business name and account.
After doing all ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-authorize-net-not-displayed-in-payment-information-section-while-checkout/' rel='bookmark' title='Permanent Link: Magento: Authorize.net not displayed in Payment Information section while Checkout'>Magento: Authorize.net not displayed in Payment Information section while Checkout</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-get-currency-rates/' rel='bookmark' title='Permanent Link: Magento: How to get Currency Rates?'>Magento: How to get Currency Rates?</a></li>
<li><a href='http://blog.chapagain.com.np/magento-setup-multiple-website/' rel='bookmark' title='Permanent Link: Magento: Setup Multiple Website'>Magento: Setup Multiple Website</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p><strong>Problem:</strong></p>
<p>I am having problem in displaying PayPal payment method in payment method section of onepage checkout in Magento.</p>
<p>I am using &#8220;<strong>PayPal Website Payments Standard</strong>&#8220;.</p>
<p><span id="more-910"></span></p>
<p>I have enabled this module from backend (<strong>System -> Configuration -> SALES -> Payment Methods -> PayPal Website Payments Standard</strong>).</p>
<p>I have also entered the Business Name and Business Account at &#8220;<strong>Website Payments Standard</strong>&#8221; (<strong>System -> Configuration -> SALES -> PayPal Accounts -> Website Payments Standard</strong>). I have set <strong>Sandbox Flag = Yes</strong> and <strong>Debug Flag = Yes</strong>. I am using Sandbox business name and account.</p>
<p>After doing all this, I think I should see the PayPal payment method option in my Checkout page on Payment methods section. But PayPal payment option is not displayed there. </p>
<p><strong>Cause:</strong></p>
<p>The possible cause is because <strong>base currency</strong> of your shop is not supported by PayPal. </p>
<p><strong>Solution:</strong></p>
<p>PayPal supports the following currencies:-</p>
<pre class="brush: php;">
protected $_allowCurrencyCode = array('AUD', 'CAD', 'CZK', 'DKK', 'EUR', 'HKD', 'HUF', 'ILS', 'JPY', 'MXN', 'NOK', 'NZD', 'PLN', 'GBP', 'SGD', 'SEK', 'CHF', 'USD');
</pre>
<p>The above code is present in the class <strong>Mage_Paypal_Model_Standard</strong>. You can add your shop&#8217;s base currency code to the array.</p>
<p>Like, I have base currency code as <strong>NPR</strong>. To show PayPal payment method in my shop, I need to add NPR in the array. Like the following way:-</p>
<pre class="brush: php;">
protected $_allowCurrencyCode = array('AUD', 'CAD', 'CZK', 'DKK', 'EUR', 'HKD', 'HUF', 'ILS', 'JPY', 'MXN', 'NOK', 'NZD', 'PLN', 'GBP', 'SGD', 'SEK', 'CHF', 'USD', 'NPR');
</pre>
<p>Now, PayPal payment option is displayed in payment methods section of onepage checkout.</p>
<p>And, to change the data sent from your site to paypal, you have to modify <strong>getStandardCheckoutFormFields()</strong> function of <strong>Mage_Paypal_Model_Standard</strong> class. This function returns an array (<strong>$rArr</strong>) with some necessary parameters. You need to change the value of &#8216;<strong>currency_code</strong>&#8216; and &#8216;<strong>amount</strong>&#8216; of the array. Currency_code can be any currency code that is supported by PayPal and Amount must be converted from your base currency to that particular currency code.</p>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-paypal-website-payments-standard-not-displayed/">Magento: PayPal Website Payments Standard not displayed</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=910&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-authorize-net-not-displayed-in-payment-information-section-while-checkout/' rel='bookmark' title='Permanent Link: Magento: Authorize.net not displayed in Payment Information section while Checkout'>Magento: Authorize.net not displayed in Payment Information section while Checkout</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-get-currency-rates/' rel='bookmark' title='Permanent Link: Magento: How to get Currency Rates?'>Magento: How to get Currency Rates?</a></li>
<li><a href='http://blog.chapagain.com.np/magento-setup-multiple-website/' rel='bookmark' title='Permanent Link: Magento: Setup Multiple Website'>Magento: Setup Multiple Website</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-paypal-website-payments-standard-not-displayed/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-paypal-website-payments-standard-not-displayed/</feedburner:origLink></item>
		<item>
		<title>Magento: Adding category attributes</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/cBPG8CiX-F0/</link>
		<comments>http://blog.chapagain.com.np/magento-adding-category-attributes/#comments</comments>
		<pubDate>Sat, 07 Aug 2010 08:30:58 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[attribute]]></category>
		<category><![CDATA[category]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=821</guid>
		<description><![CDATA[Here, I will be showing you how you can add attributes for your categories in Magento.
From the admin panel, you can only add attributes to product. To add attributes to category, you need to write sql query in your phpmyadmin or a better way would be creating a new custom module and adding attributes to category from the mysql setup file of the module.
By mysql setup file, I mean the file inside the directory YourNamespace/YourModule/sql/yourmodule_setup/

Create a new module and write the following in your module&#8217;s mysql setup file. 

$installer = ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-adding-attribute-from-mysql-setup-file/' rel='bookmark' title='Permanent Link: Magento: Adding attribute from MySql setup file'>Magento: Adding attribute from MySql setup file</a></li>
<li><a href='http://blog.chapagain.com.np/magento-get-category-name-and-url-from-product/' rel='bookmark' title='Permanent Link: Magento: Get category name and url from product'>Magento: Get category name and url from product</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-filter-product-collection-using-2-or-more-category-filters/' rel='bookmark' title='Permanent Link: Magento: How to filter product collection using 2 or more category filters?'>Magento: How to filter product collection using 2 or more category filters?</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Here, I will be showing you how you can add attributes for your categories in Magento.</p>
<p>From the admin panel, you can only add attributes to product. To add attributes to category, you need to write sql query in your phpmyadmin or a better way would be creating a new custom module and adding attributes to category from the mysql setup file of the module.</p>
<p>By mysql setup file, I mean the file inside the directory <strong>YourNamespace/YourModule/sql/yourmodule_setup/</strong></p>
<p><span id="more-821"></span></p>
<p>Create a new module and write the following in your module&#8217;s mysql setup file. </p>
<pre class="brush: php;">
$installer = $this;
$setup = new Mage_Eav_Model_Entity_Setup('core_setup');
$installer-&gt;startSetup();

$setup-&gt;addAttribute('catalog_category', 'my_attribute', array(
	'group'     	=&gt; 'General',
	'input'         =&gt; 'text',
    'type'          =&gt; 'varchar',
    'label'         =&gt; 'My Attribute',
	'backend'       =&gt; '',
	'visible'       =&gt; 1,
	'required'		=&gt; 0,
	'user_defined' =&gt; 1,
    'global'        =&gt; Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_GLOBAL,
));

$installer-&gt;endSetup();
</pre>
<p>The above code will create a category with the code &#8216;<strong>my_attribute</strong>&#8216; and lable &#8216;<strong>My Attribute</strong>&#8216;. You can view it under <strong>Admin Panel &#8211;> Catalog &#8211;> Manage Categories &#8211;> General Information</strong></p>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-adding-category-attributes/">Magento: Adding category attributes</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=821&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/magento-adding-attribute-from-mysql-setup-file/' rel='bookmark' title='Permanent Link: Magento: Adding attribute from MySql setup file'>Magento: Adding attribute from MySql setup file</a></li>
<li><a href='http://blog.chapagain.com.np/magento-get-category-name-and-url-from-product/' rel='bookmark' title='Permanent Link: Magento: Get category name and url from product'>Magento: Get category name and url from product</a></li>
<li><a href='http://blog.chapagain.com.np/magento-how-to-filter-product-collection-using-2-or-more-category-filters/' rel='bookmark' title='Permanent Link: Magento: How to filter product collection using 2 or more category filters?'>Magento: How to filter product collection using 2 or more category filters?</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-adding-category-attributes/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-adding-category-attributes/</feedburner:origLink></item>
		<item>
		<title>Magento: Set Random Order in Collection using RAND()</title>
		<link>http://feedproxy.google.com/~r/chapagainblog/~3/ccRqAi2r9UE/</link>
		<comments>http://blog.chapagain.com.np/magento-set-random-order-in-collection-using-rand/#comments</comments>
		<pubDate>Mon, 02 Aug 2010 12:09:38 +0000</pubDate>
		<dc:creator>Mukesh</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[collection]]></category>
		<category><![CDATA[order]]></category>
		<category><![CDATA[query]]></category>
		<category><![CDATA[rand]]></category>
		<category><![CDATA[random]]></category>
		<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://blog.chapagain.com.np/?p=845</guid>
		<description><![CDATA[Scenario:
You have created a custom module.
You have entered certain data in your database.
You need to show the data randomly.
Solution:

In MySQL the rand() function helps the select query to fetch data randomly. In Magento, you can select random rows from MySQL table using Zend_Db_Expr(&#8216;RAND()&#8217;).
You have to create a new function in your module&#8217;s collection class (YourNamespace/YourModule/Model/Mysql4/YourModule/Collection.php)

public function setRandomOrder()
{
	$this-&#62;getSelect()-&#62;order(new Zend_Db_Expr('RAND()'));
	return $this;
}

Now, you can fetch random data from your table using the above create setRandomOrder function. The code below can be kept in the block or template (.phtml) file of your module.

$collection = ...


<strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/random-number-string-generation-in-php/' rel='bookmark' title='Permanent Link: Random number, string generation in PHP'>Random number, string generation in PHP</a></li>
<li><a href='http://blog.chapagain.com.np/generating-random-image/' rel='bookmark' title='Permanent Link: Generating random image'>Generating random image</a></li>
<li><a href='http://blog.chapagain.com.np/magento-collection-functions/' rel='bookmark' title='Permanent Link: Magento: Very Useful Collection Functions'>Magento: Very Useful Collection Functions</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p><strong>Scenario:</strong></p>
<p>You have created a custom module.<br />
You have entered certain data in your database.<br />
You need to show the data randomly.</p>
<p><strong>Solution:</strong></p>
<p><span id="more-845"></span></p>
<p>In MySQL the rand() function helps the select query to fetch data randomly. In Magento, you can select random rows from MySQL table using <strong>Zend_Db_Expr(&#8216;RAND()&#8217;)</strong>.</p>
<p>You have to create a new function in your module&#8217;s collection class <strong>(YourNamespace/YourModule/Model/Mysql4/YourModule/Collection.php)</strong></p>
<pre class="brush: php;">
public function setRandomOrder()
{
	$this-&gt;getSelect()-&gt;order(new Zend_Db_Expr('RAND()'));
	return $this;
}
</pre>
<p>Now, you can fetch random data from your table using the above create <strong>setRandomOrder</strong> function. The code below can be kept in the block or template (.phtml) file of your module.</p>
<pre class="brush: php;">
$collection = Mage::getModel('yourmodule/yourmodule')
					-&gt;getCollection()
					-&gt;setRandomOrder();

echo &quot;&lt;pre&gt;&quot;; print_r($collection-&gt;getData()); echo &quot;&lt;/pre&gt;&quot;;
</pre>
<p>Hope this helps. Thanks.</p>
<div style="margin-top: 15px; font-style: italic">
<p><strong>From</strong> <a href="http://blog.chapagain.com.np/">Mukesh Chapagain&#039;s Blog</a> | <strong>Post</strong> <a href="http://blog.chapagain.com.np/magento-set-random-order-in-collection-using-rand/">Magento: Set Random Order in Collection using RAND()</a></p>
</div>
<hr /><small>Copyright &copy; 2010<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> )</small><img src="http://blog.chapagain.com.np/?ak_action=api_record_view&id=845&type=feed" alt="" />

<p><strong>Related posts:</strong><ol><li><a href='http://blog.chapagain.com.np/random-number-string-generation-in-php/' rel='bookmark' title='Permanent Link: Random number, string generation in PHP'>Random number, string generation in PHP</a></li>
<li><a href='http://blog.chapagain.com.np/generating-random-image/' rel='bookmark' title='Permanent Link: Generating random image'>Generating random image</a></li>
<li><a href='http://blog.chapagain.com.np/magento-collection-functions/' rel='bookmark' title='Permanent Link: Magento: Very Useful Collection Functions'>Magento: Very Useful Collection Functions</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://blog.chapagain.com.np/magento-set-random-order-in-collection-using-rand/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://blog.chapagain.com.np/magento-set-random-order-in-collection-using-rand/</feedburner:origLink></item>
	</channel>
</rss><!-- Dynamic page generated in 1.957 seconds. --><!-- Cached page generated by WP-Super-Cache on 2010-09-07 17:25:27 -->
