<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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:georss="http://www.georss.org/georss"
	xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#"
	
	>
<channel>
	<title>
	Comments on: How to run Magento session into an external site?	</title>
	<atom:link href="https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/feed/" rel="self" type="application/rss+xml" />
	<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/</link>
	<description>it&#039;s my blog anyway</description>
	<lastBuildDate>Mon, 10 Sep 2012 15:46:26 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=5.9.13</generator>
	<item>
		<title>
		By: Richard Feraro		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-56999</link>

		<dc:creator><![CDATA[Richard Feraro]]></dc:creator>
		<pubDate>Mon, 10 Sep 2012 15:46:26 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-56999</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-56987&quot;&gt;Hiren Prajapati&lt;/a&gt;.

Hello Hiren,

Make sure that your Magento application and the parent site share the same cookie and/or you should be able to generate the Magento cookie with the same cookie domain path with your parent site to share the same session.

Thanks for dropping by :)]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-56987">Hiren Prajapati</a>.</p>
<p>Hello Hiren,</p>
<p>Make sure that your Magento application and the parent site share the same cookie and/or you should be able to generate the Magento cookie with the same cookie domain path with your parent site to share the same session.</p>
<p>Thanks for dropping by 🙂</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Hiren Prajapati		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-56987</link>

		<dc:creator><![CDATA[Hiren Prajapati]]></dc:creator>
		<pubDate>Mon, 10 Sep 2012 14:48:55 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-56987</guid>

					<description><![CDATA[Hi Richard,

Thank you very much for this helpful post! 

I have similar problem. First of all i would like to overview the exact problem.

I have my external site setup in core php. I am using magento as a part of this parent site and i have to run the magento within iframe of parent website.

Now what exactly I want is, if I logged in to the parent website than it should also logged me in to the magento front end site as a customer once I click on the magento link.

I have managed the registration process. So if i register to the parent website than the record is also added to the magento database as a customer.

I do not have any idea that how I synchronize the session of my external site into magento site. 

Our external site creates a sessionhash once user logged in to the site and it keeps the sessionhash throughout the whole user session and it uses this session hash to authenticate user on every page.

Your quick help/solution would be really appreciated as I am running short of time.

Thanks in advance.

Hiren]]></description>
			<content:encoded><![CDATA[<p>Hi Richard,</p>
<p>Thank you very much for this helpful post! </p>
<p>I have similar problem. First of all i would like to overview the exact problem.</p>
<p>I have my external site setup in core php. I am using magento as a part of this parent site and i have to run the magento within iframe of parent website.</p>
<p>Now what exactly I want is, if I logged in to the parent website than it should also logged me in to the magento front end site as a customer once I click on the magento link.</p>
<p>I have managed the registration process. So if i register to the parent website than the record is also added to the magento database as a customer.</p>
<p>I do not have any idea that how I synchronize the session of my external site into magento site. </p>
<p>Our external site creates a sessionhash once user logged in to the site and it keeps the sessionhash throughout the whole user session and it uses this session hash to authenticate user on every page.</p>
<p>Your quick help/solution would be really appreciated as I am running short of time.</p>
<p>Thanks in advance.</p>
<p>Hiren</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: jancor		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-7381</link>

		<dc:creator><![CDATA[jancor]]></dc:creator>
		<pubDate>Fri, 19 Aug 2011 04:06:13 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-7381</guid>

					<description><![CDATA[Don&#039;t forget about translation init :   Mage::app()-&#062;getTranslator()-&#062;init(&#039;frontend&#039;);]]></description>
			<content:encoded><![CDATA[<p>Don&#8217;t forget about translation init :   Mage::app()-&gt;getTranslator()-&gt;init(&#8216;frontend&#8217;);</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: How to run Magento (version 1.4.0.1) session into an external site?		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-432</link>

		<dc:creator><![CDATA[How to run Magento (version 1.4.0.1) session into an external site?]]></dc:creator>
		<pubDate>Fri, 09 Jul 2010 07:51:50 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-432</guid>

					<description><![CDATA[[...] post is an update for my blog entry on how to extend the Magento session to an external site but instead of using the version 1.2.1.2, I used the the latest stable version as of this writing [...]]]></description>
			<content:encoded><![CDATA[<p>[&#8230;] post is an update for my blog entry on how to extend the Magento session to an external site but instead of using the version 1.2.1.2, I used the the latest stable version as of this writing [&#8230;]</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: How to add a product into Magento shopping cart from an external site?		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-275</link>

		<dc:creator><![CDATA[How to add a product into Magento shopping cart from an external site?]]></dc:creator>
		<pubDate>Fri, 04 Jun 2010 09:38:23 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-275</guid>

					<description><![CDATA[[...] the Mage.php file on top of the process.php. Click here to see how. Then proceed with the php script [...]]]></description>
			<content:encoded><![CDATA[<p>[&#8230;] the Mage.php file on top of the process.php. Click here to see how. Then proceed with the php script [&#8230;]</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Richard Feraro		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-69</link>

		<dc:creator><![CDATA[Richard Feraro]]></dc:creator>
		<pubDate>Thu, 27 May 2010 15:13:41 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-69</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-68&quot;&gt;sabnam&lt;/a&gt;.

Glad that you figured it out :) Keep on reading.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-68">sabnam</a>.</p>
<p>Glad that you figured it out 🙂 Keep on reading.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: sabnam		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-68</link>

		<dc:creator><![CDATA[sabnam]]></dc:creator>
		<pubDate>Thu, 27 May 2010 14:54:38 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-68</guid>

					<description><![CDATA[Thanks Richard for the help and this awesome blog.

I found that this solution also works ...
if(!($session-&#062;isLoggedIn()))
{
	Mage::getSingleton(&#039;customer/session&#039;)-&#062;setBeforeAuthUrl($this-&#062;getRequest()-&#062;getRequestUri());

it saves the url for where it will be redirected to after login/registration page...

will be glad..if it will work for others too.....]]></description>
			<content:encoded><![CDATA[<p>Thanks Richard for the help and this awesome blog.</p>
<p>I found that this solution also works &#8230;<br />
if(!($session-&gt;isLoggedIn()))<br />
{<br />
	Mage::getSingleton(&#8216;customer/session&#8217;)-&gt;setBeforeAuthUrl($this-&gt;getRequest()-&gt;getRequestUri());</p>
<p>it saves the url for where it will be redirected to after login/registration page&#8230;</p>
<p>will be glad..if it will work for others too&#8230;..</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Richard Feraro		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-67</link>

		<dc:creator><![CDATA[Richard Feraro]]></dc:creator>
		<pubDate>Thu, 27 May 2010 14:32:05 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-67</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-66&quot;&gt;sabnam&lt;/a&gt;.

Try using:
[sourcecode language=&quot;php&quot;]Mage::app()-&#062;getResponse()-&#062;setRedirect(...) ;[/sourcecode]
or
[sourcecode language=&quot;php&quot;]Mage::_redirect(...);[/sourcecode]
or another sample
[sourcecode language=&quot;php&quot;]header( &#039;Location: &#039; . Mage::helper(&#039;checkout/url&#039;)-&#062;getCheckoutUrl() );[/sourcecode]


Check the samples &lt;a href=&quot;http://www.magentocommerce.com/boards/viewthread/15792/#t75140&quot; rel=&quot;nofollow&quot;&gt;here&lt;/a&gt;
&lt;a href=&quot;http://blog.chapagain.com.np/magento-redirect-functions/&quot; rel=&quot;nofollow&quot;&gt;This&lt;/a&gt; can also help you.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-66">sabnam</a>.</p>
<p>Try using:</p>
<pre class="brush: php; title: ; notranslate">Mage::app()-&gt;getResponse()-&gt;setRedirect(...) ;</pre>
<p>or</p>
<pre class="brush: php; title: ; notranslate">Mage::_redirect(...);</pre>
<p>or another sample</p>
<pre class="brush: php; title: ; notranslate">header( 'Location: ' . Mage::helper('checkout/url')-&gt;getCheckoutUrl() );</pre>
<p>Check the samples <a href="http://www.magentocommerce.com/boards/viewthread/15792/#t75140" rel="nofollow">here</a><br />
<a href="http://blog.chapagain.com.np/magento-redirect-functions/" rel="nofollow">This</a> can also help you.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: sabnam		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-66</link>

		<dc:creator><![CDATA[sabnam]]></dc:creator>
		<pubDate>Thu, 27 May 2010 13:59:10 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-66</guid>

					<description><![CDATA[First of all thanks for this post...it really helped me a lot..

I am having one small problem here...

I have a magento CMS page which links to the module phtml which decides whether to let the user access external website or not....


 &quot;frontend&quot;));
$session = Mage::getSingleton(&quot;customer/session&quot;);
if(!($session-&#062;isLoggedIn()))
{
header(&quot;Location:/customer/account/login/login_url/ &quot;);
Mage::getSingleton(&#039;core/session&#039;)-&#062;addError($this-&#062;__(&#039;Before you can access ABC website you must first create an account or login with us&#039;));
exit;
}
else
{
header(&quot;Status: 301&quot;);
header(&quot;Location: http://ABC.com &quot;);
exit;
}
?&#062;


here when the user is not logged in and is taken to dual page where he can either do the registration or login...after that he should be taken to ABC.com..how can that be achieved..i tried geturl() and seturl() but didn`t worked :(..]]></description>
			<content:encoded><![CDATA[<p>First of all thanks for this post&#8230;it really helped me a lot..</p>
<p>I am having one small problem here&#8230;</p>
<p>I have a magento CMS page which links to the module phtml which decides whether to let the user access external website or not&#8230;.</p>
<p> &#8220;frontend&#8221;));<br />
$session = Mage::getSingleton(&#8220;customer/session&#8221;);<br />
if(!($session-&gt;isLoggedIn()))<br />
{<br />
header(&#8220;Location:/customer/account/login/login_url/ &#8220;);<br />
Mage::getSingleton(&#8216;core/session&#8217;)-&gt;addError($this-&gt;__(&#8216;Before you can access ABC website you must first create an account or login with us&#8217;));<br />
exit;<br />
}<br />
else<br />
{<br />
header(&#8220;Status: 301&#8221;);<br />
header(&#8220;Location: <a href="http://ABC.com" rel="nofollow ugc">http://ABC.com</a> &#8220;);<br />
exit;<br />
}<br />
?&gt;</p>
<p>here when the user is not logged in and is taken to dual page where he can either do the registration or login&#8230;after that he should be taken to ABC.com..how can that be achieved..i tried geturl() and seturl() but didn`t worked :(..</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Richard Feraro		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-65</link>

		<dc:creator><![CDATA[Richard Feraro]]></dc:creator>
		<pubDate>Fri, 21 May 2010 08:24:07 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-65</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-64&quot;&gt;Justin&lt;/a&gt;.

Hmm I think that would post security issues unless you&#039;re gonna access it thru other means except http.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-64">Justin</a>.</p>
<p>Hmm I think that would post security issues unless you&#8217;re gonna access it thru other means except http.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Justin		</title>
		<link>https://mysillypointofview.com/2009/04/13/how-to-run-magento-session-to-an-external-site/#comment-64</link>

		<dc:creator><![CDATA[Justin]]></dc:creator>
		<pubDate>Mon, 17 May 2010 20:30:57 +0000</pubDate>
		<guid isPermaLink="false">http://mysillypointofview.wordpress.com/?p=52#comment-64</guid>

					<description><![CDATA[Thanks for the posts on this topic!

Are you aware of a way to access the mage.php file in the same way, but from an application on a separate server - without changing permissions on that file?

We want to carry the high level cart information like price and item quantity between the website and the Magento store hosted on another server, so maybe you see a better way to do that?]]></description>
			<content:encoded><![CDATA[<p>Thanks for the posts on this topic!</p>
<p>Are you aware of a way to access the mage.php file in the same way, but from an application on a separate server &#8211; without changing permissions on that file?</p>
<p>We want to carry the high level cart information like price and item quantity between the website and the Magento store hosted on another server, so maybe you see a better way to do that?</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
