<?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>Okada Design Blog &#187; XAMPP</title>
	<atom:link href="http://www.okadadesign.no/blog/category/xampp/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.okadadesign.no/blog</link>
	<description>Welcome to Okada Design Web Development Blog</description>
	<lastBuildDate>Wed, 11 Jan 2012 23:21:51 +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>Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter</title>
		<link>http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/</link>
		<comments>http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/#comments</comments>
		<pubDate>Sun, 27 Feb 2011 12:48:05 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[XAMPP]]></category>
		<category><![CDATA[VMware]]></category>
		<category><![CDATA[Windows 7]]></category>
		<category><![CDATA[Windows XP]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=2670</guid>
		<description><![CDATA[ <p>Well I had a aha moment today, so I thought I should share this. I know that the title is a bit confusing. </p> <p>There are times still I have to use Windows. And there are times when you have to develop for IE7. My set up for this is using IE 7 [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/web-development/windows-in-vm-virtualbox-on-ubuntu-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows in VM Virtualbox on Ubuntu, localhost and base url of CodeIgniter'>Windows in VM Virtualbox on Ubuntu, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/path-problems-with-codeigniter-on-windows/' rel='bookmark' title='Path problems with Codeigniter on Windows'>Path problems with Codeigniter on Windows</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-send-email-from-your-own-localhost/' rel='bookmark' title='How to send email from your own localhost'>How to send email from your own localhost</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fwindows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fwindows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p><img src="http://www.okadadesign.no/blog/wp-content/uploads/2011/02/icon_1281.png" alt="" title="icon_128" width="128" height="128" class="alignleft size-full wp-image-2695" />Well I had a aha moment today, so I thought I should share this. I know that the title is a bit confusing. </p>
<p>There are times still I have to use Windows. And there are times when you have to develop for IE7. My set up for this is using IE 7 on Windows XP which is installed in VMware running on Windows 7. Well I could do it on Ubuntu as well. And I use XAMPP on Windows 7 for development.</p>
<h3>Use IPv4 Address value</h3>
<p>I had a hard time to display localhost on IE 7. When I use http://localhost/mywebsite, it works fine in my browsers on Windows 7, but it did not display in browsers in Windows XP. In a short answer, use http://192.168.1.2/. If this does not work for you, read on.</p>
<p>On Windows 7, go to Control panes > Network and Internet > Networking and Sharing center, then click your wireless connection or if you are using cable, then cable connection. Please note that it is not a VMware Adapters. When you open the Wireless Network Connection status, click Details. Find the vaule for IPv4 Address. For me it is 192.168.1.2. Use this in a browser in VMware to display a localhost from Windows 7.</p>
<h3>Using CodeIgniter?</h3>
<p>If you are using CodeIgniter, then you need to do one more step. Open your system>application>config>config.php and add the following to your base_url.</p>
<pre class="brush: php; title: ; notranslate">
$config['base_url']	= &quot;http://192.168.1.2/mywebsite/&quot;;
</pre>
<p>Without this line, all the internal links, images, CSS and scripts are broken. Adding this will fix the problems.</p>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/web-development/windows-in-vm-virtualbox-on-ubuntu-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows in VM Virtualbox on Ubuntu, localhost and base url of CodeIgniter'>Windows in VM Virtualbox on Ubuntu, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/path-problems-with-codeigniter-on-windows/' rel='bookmark' title='Path problems with Codeigniter on Windows'>Path problems with Codeigniter on Windows</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-send-email-from-your-own-localhost/' rel='bookmark' title='How to send email from your own localhost'>How to send email from your own localhost</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Zend Framework on Codeigniter: Youtube</title>
		<link>http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/</link>
		<comments>http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/#comments</comments>
		<pubDate>Sat, 21 Nov 2009 22:28:47 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[XAMPP]]></category>
		<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[youtube]]></category>
		<category><![CDATA[zend]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=452</guid>
		<description><![CDATA[ <p> This post is about how to use Zend Framework on Codeigniter to show Youtube videos. </p> Download Note: <p>The download file is set up for Windows. If you are not using Windows, then open application/helpers/zend_framework_helper.php and comment out Windows part and uncomment the other part.</p> &#60;?php // For Windows ini_set(&#34;include_path&#34;, ini_get(&#34;include_path&#34;).PATH_SEPARATOR.str_replace(&#34;/&#34;, &#34;\\&#34;, [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/' rel='bookmark' title='Zend framework Youtube class on Codeigniter with jquery'>Zend framework Youtube class on Codeigniter with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
<li><a href='http://www.okadadesign.no/blog/zend-framework/zend-framework-flickr-class-on-codeignier-with-jquery/' rel='bookmark' title='Zend framework Flickr class on Codeignier with jquery'>Zend framework Flickr class on Codeignier with jquery</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fzend-framework-on-codeigniter-youtube%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fzend-framework-on-codeigniter-youtube%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p><img class="alignleft size-full wp-image-466" title="youtube3" src="http://www.okadadesign.no/blog/wp-content/uploads/2009/11/youtube3.jpg" alt="youtube3" width="420" height="413" /><br />
This post is about how to use Zend Framework on Codeigniter to show Youtube videos.<br />
<span id="more-452"></span></p>
<div class="clearboth"></div>
<h4 class="download"><a href="http://www.box.net/shared/0cxtrq8apq">Download</a></h4>
<h5>Note:</h5>
<p>The download file is set up for Windows. If you are not using Windows, then open application/helpers/zend_framework_helper.php and comment out Windows part and uncomment the other part.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
// For Windows
ini_set(&quot;include_path&quot;, ini_get(&quot;include_path&quot;).PATH_SEPARATOR.str_replace(&quot;/&quot;, &quot;\\&quot;, BASEPATH).&quot;contrib\\&quot;);
require_once ('Zend/Loader.php');

// For Non-Windows
/*
ini_set(&quot;include_path&quot;, ini_get(&quot;include_path&quot;).PATH_SEPARATOR.BASEPATH.&quot;/contrib/&quot;);
require_once 'Zend/Loader.php';
*/

?&gt;
</pre>
<h3>Implement Zend Framework in Codeigniter</h3>
<p>First you have to implement Zend Framework in Codeigniter. <a href="http://www.okadadesign.no/blog/?p=410">Please read this post</a>.</p>
<h3>Controller/youtube2.php</h3>
<p>Create a file and add the following code.<br />
<!--more--></p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
class Youtube2 extends Controller{
    protected $_youTube;

function __construct() {
    parent::Controller();
    Zend_Loader::loadClass('Zend_Gdata_YouTube');
    $this-&gt;_youTube = new Zend_Gdata_YouTube;
    }

function index(){
      // Gets playlists
    $data['playlistfeed']= $this-&gt;_youTube-&gt;getPlaylistListFeed('NationalGeographic');
    $this-&gt;load-&gt;view ('youtube_view2',$data);
    }

public function listAction(){
    // Gets playlist videos
    $playlistId = $this-&gt;uri-&gt;segment(4);
    $query = $this-&gt;_youTube-&gt;newVideoQuery(
    'http://gdata.youtube.com/feeds/playlists/' . $playlistId);
    $data['videoFeed']= $this-&gt;_youTube-&gt;getVideoFeed($query);
    $this-&gt;load-&gt;view('listaction_view', $data);
    }

public function viewAction(){
    // Gets video
    $videoId = $this-&gt;uri-&gt;segment(4);
    $data['videoId'] = $this-&gt;uri-&gt;segment(4);
    $data['videoEntry'] = $this-&gt;_youTube-&gt;getVideoEntry($videoId);
    $this-&gt;load-&gt;view('youtube_video_view', $data);
    }
}
</pre>
<p>Firstly I am adding a protected variable $_youTube.<br />
In the constructor, I load the class Zend_Gdata_Youtube, and create a new object.</p>
<p>In the function index, I add a variable playlistfeed and send it to a view called youtube_view2 which I am going to create it shortly.</p>
<p>I am going to collect National geographic videos in this case. You can change it as you wish.</p>
<h3>views/youtube_view2.php</h3>
<p>Create a file and add the following code.</p>
<pre class="brush: php; title: ; notranslate">
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot;
        &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;en&quot; lang=&quot;en&quot;&gt;
&lt;head&gt;
  &lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot; /&gt;
  &lt;title&gt;Video lists&lt;/title&gt;

&lt;/head&gt;
&lt;body&gt;
&lt;h1&gt;National Geographic Videos on Youtube&lt;/h1&gt;
&lt;dl&gt;
&lt;?php foreach ($playlistfeed as $playlistEntry): &gt;
&lt;?php $id = substr(strrchr(
$playlistEntry-&gt;getPlaylistVideoFeedUrl(), '/'
), 1); &gt;
&lt;dt&gt;
&lt;a href=&quot;youtube2/listAction/id/&lt;?php echo $id; &gt;/&quot;&gt;
&lt;?php echo $playlistEntry-&gt;title-&gt;text; &gt;
&lt;/a&gt;
&lt;/dt&gt;
&lt;dd&gt;&lt;?php echo $playlistEntry-&gt;description-&gt;text; &gt;&lt;/dd&gt;
&lt;?php endforeach; &gt;
&lt;/dl&gt;

&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>This will output the following html.</p>
<pre class="brush: xml; title: ; notranslate">
...
&lt;h1&gt;National Geographic Videos on Youtube&lt;/h1&gt;
&lt;dl&gt;
&lt;dt&gt;
&lt;a href=&quot;youtube2/listAction/id/746AD498C993B957/&quot;&gt;
Oceans&lt;/a&gt;

&lt;/dt&gt;
&lt;dd&gt;Explore the beauty of the world's oceans.&lt;/dd&gt;
&lt;dt&gt;
&lt;a href=&quot;youtube2/listAction/id/355D512277EFFA06/&quot;&gt;
Animal Attack!&lt;/a&gt;
&lt;/dt&gt;
...
...
</pre>
<p>When you click a link, it will take you listAction() function in youtube2 class and the fourth segment will be used as id in that class.<br />
<img class="alignleft size-full wp-image-464" title="youtube1" src="http://www.okadadesign.no/blog/wp-content/uploads/2009/11/youtube1.jpg" alt="youtube1" width="420" height="374" /></p>
<div class="clearboth"></div>
<h3>views/listaction_view.php</h3>
<p>Create a file and add the following code.</p>
<pre class="brush: php; title: ; notranslate">
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot;
        &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;en&quot; lang=&quot;en&quot;&gt;
&lt;head&gt;
  &lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot; /&gt;
  &lt;title&gt;Youtube Video Details&lt;/title&gt;

&lt;/head&gt;
&lt;body&gt;

&lt;h1&gt;National Geographic Videos on Youtube. Videos about &lt;?php echo $videoFeed-&gt;title-&gt;text; &gt;&lt;/h1&gt;
&lt;dl&gt;
&lt;?php foreach ($videoFeed as $videoEntry): &gt;
&lt;?php $id = substr(strrchr($videoEntry-&gt;getFlashPlayerUrl(), '/'),
1); &gt;

&lt;dt&gt;
    &lt;h2&gt;
        &lt;?php echo &quot;Video Title: &quot;. $videoEntry-&gt;mediaGroup-&gt;title-&gt;text; &gt;

&lt;/h2&gt;
   &lt;h3&gt; &lt;?php echo anchor(&quot;youtube2/viewAction/id/$id/&quot;,&quot;Watch Video&quot;);&gt;
&lt;/h3&gt;

&lt;/dt&gt;
&lt;dd&gt;&lt;?php echo $videoEntry-&gt;mediaGroup-&gt;description-&gt;text. &quot;&lt;br /&gt;&lt;br /&gt;&quot;; &gt;
&lt;b&gt;&lt;?php echo &quot;Video id: &quot;. $id; &gt;
&lt;/b&gt;
&lt;/dd&gt;
&lt;?php endforeach; &gt;
&lt;/dl&gt;

&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>This listAction() function outputs the following html.</p>
<pre class="brush: xml; title: ; notranslate">
...
&lt;h1&gt;National Geographic Videos on Youtube. Videos about Oceans&lt;/h1&gt;
&lt;dl&gt;

&lt;dt&gt;
    &lt;h2&gt;
        Video Title: Feeding Frenzy: Manta Rays in the Maldives
&lt;/h2&gt;
   &lt;h3&gt; &lt;a href=&quot;http://127.0.0.1/ci_zend/index.php/youtube2/viewAction/id/yihoIvUBDM4?f=playlists&amp;amp;amp;app=youtube_gdata&quot;&gt;Watch Video&lt;/a&gt;&lt;/h3&gt;

&lt;/dt&gt;
&lt;dd&gt;When tide and current turn a tiny bay into a bowl of plankton, manta rays in the Maldives gather for a roiling, whirling feast.&lt;br /&gt;&lt;br /&gt;&lt;b&gt;Video id: yihoIvUBDM4?f=playlists&amp;amp;amp;app=youtube_gdata&lt;/b&gt;
&lt;/dd&gt;

&lt;dt&gt;
    &lt;h2&gt;
        Video Title: Penguins vs. Pelicans
&lt;/h2&gt;
   &lt;h3&gt; &lt;a href=&quot;http://127.0.0.1/ci_zend/index.php/youtube2/viewAction/id/Fhmm-A8wBzk?f=playlists&amp;amp;amp;app=youtube_gdata&quot;&gt;Watch Video&lt;/a&gt;&lt;/h3&gt;

&lt;/dt&gt;
...
...
</pre>
<p>The links will take you to youtube2 viewAction () function with Youtube video identifier.<br />
The viewAction() function will take the forth segment and show a video in the next step.</p>
<p><img class="alignleft size-full wp-image-465" title="youtube2" src="http://www.okadadesign.no/blog/wp-content/uploads/2009/11/youtube2.jpg" alt="youtube2" width="420" height="420" /></p>
<div class="clearboth"></div>
<h3>views/youtube_video_view.php</h3>
<p>Create a file and add the following code.</p>
<pre class="brush: php; title: ; notranslate">
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot;
        &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;en&quot; lang=&quot;en&quot;&gt;
&lt;head&gt;
  &lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot; /&gt;
  &lt;title&gt;Watch: Youtube Videos&lt;/title&gt;

&lt;/head&gt;
&lt;body&gt;

&lt;h1&gt;&lt;?php echo $videoEntry-&gt;mediaGroup-&gt;title-&gt;text; &gt;&lt;/h1&gt;
&lt;object width=&quot;425&quot; height=&quot;355&quot;&gt;
&lt;param name=&quot;movie&quot;
value=&quot;http://www.youtube.com/v/&lt;?php echo $videoId; &gt;&amp;amp;amp;rel=0&quot;&gt;
&lt;/param&gt;
&lt;param name=&quot;wmode&quot; value=&quot;transparent&quot;&gt;&lt;/param&gt;
&lt;embed src=&quot;http://www.youtube.com/v/&lt;?php echo $videoId; &gt;&amp;amp;amp;rel=0&quot;
type=&quot;application/x-shockwave-flash&quot;
wmode=&quot;transparent&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;
&lt;/embed&gt;
&lt;/object&gt;

&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>This view outputs the following html.</p>
<pre class="brush: xml; title: ; notranslate">
...
&lt;h1&gt;Feeding Frenzy: Manta Rays in the Maldives&lt;/h1&gt;
&lt;object width=&quot;425&quot; height=&quot;355&quot;&gt;
&lt;param name=&quot;movie&quot;
value=&quot;http://www.youtube.com/v/yihoIvUBDM4&amp;amp;amp;rel=0&quot;&gt;
&lt;/param&gt;
&lt;param name=&quot;wmode&quot; value=&quot;transparent&quot;&gt;&lt;/param&gt;
&lt;embed src=&quot;http://www.youtube.com/v/yihoIvUBDM4&amp;amp;amp;rel=0&quot;
type=&quot;application/x-shockwave-flash&quot;
wmode=&quot;transparent&quot; width=&quot;425&quot; height=&quot;355&quot;&gt;
&lt;/embed&gt;
&lt;/object&gt;
...
...
</pre>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/' rel='bookmark' title='Zend framework Youtube class on Codeigniter with jquery'>Zend framework Youtube class on Codeigniter with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
<li><a href='http://www.okadadesign.no/blog/zend-framework/zend-framework-flickr-class-on-codeignier-with-jquery/' rel='bookmark' title='Zend framework Flickr class on Codeignier with jquery'>Zend framework Flickr class on Codeignier with jquery</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>How to implement Zend Framework with Codeigniter</title>
		<link>http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/</link>
		<comments>http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/#comments</comments>
		<pubDate>Sat, 21 Nov 2009 12:14:58 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[XAMPP]]></category>
		<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[zend]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=410</guid>
		<description><![CDATA[ Download Files <p>There are quite few posts how to use Zend framework in Codeigniter.</p> Beyond Coding Freakauth Phil&#8217;s post <p>However none of them worked on my XAMPP. I thought there might be some who are struggling to use Zend frame work on Windows. Here is how I did.</p> <p>Here you can read why [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/' rel='bookmark' title='Zend framework Youtube class on Codeigniter with jquery'>Zend framework Youtube class on Codeigniter with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/' rel='bookmark' title='Zend Framework on Codeigniter: Youtube'>Zend Framework on Codeigniter: Youtube</a></li>
<li><a href='http://www.okadadesign.no/blog/zend-framework/zend-framework-flickr-class-on-codeignier-with-jquery/' rel='bookmark' title='Zend framework Flickr class on Codeignier with jquery'>Zend framework Flickr class on Codeignier with jquery</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-implement-zend-framework-with-codeigniter-on-windows%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-implement-zend-framework-with-codeigniter-on-windows%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<h4 class="download">
<a href="http://www.box.net/shared/0cxtrq8apq">Download Files</a></h4>
<p>There are quite few posts how to use Zend framework in Codeigniter.</p>
<ol>
<li>
<a href="http://www.beyondcoding.com/2008/02/21/using-zend-framework-with-codeigniter/">Beyond Coding</a>
</li>
<li><a href="http://freakauth.4webby.com/tutorials/using-zend-framework-components-in-code-igniter">Freakauth</a>
</li>
<li><a href="http://www.mynameisphil.net/article/may/2009/implementing-the-zend-framework-with-codeigniter/11">Phil&#8217;s post</a></li>
</ol>
<p>However none of them worked on my XAMPP. I thought there might be some who are struggling to use Zend frame work on Windows. Here is how I did.</p>
<p><a href="http://www.okadadesign.no/blog/?p=414">Here you can read</a> why they don&#8217;t work with Windows.</p>
<h3>Adding Zend Framework</h3>
<p><a href="http://www.mynameisphil.net/article/may/2009/implementing-the-zend-framework-with-codeigniter/11">Here you can read</a> how to add Zend Framework. And I use this structure for this post.</p>
<p>You need to create a folder ../system/contrib/ and add Zend folders in this folder.</p>
<pre>
<div class="codesnip-container" >../system/
         contrib/
               Zend/
                     Acl/
                     Acl.php
                     Amf/
                     Amf.php ...</div>
</pre>
<p>Create a file system/application/helpers/zend_framework_helper.php and add the following.<br />
<span id="more-410"></span></p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
ini_set(&quot;include_path&quot;, ini_get(&quot;include_path&quot;).PATH_SEPARATOR.str_replace(&quot;/&quot;, &quot;\\&quot;, BASEPATH).&quot;contrib\\&quot;);
require_once ('Zend/Loader.php');
?&gt;
</pre>
<p>If you are not using Windows, then add the following instead.</p>
<pre class="brush: php; title: ; notranslate">
ini_set(&quot;include_path&quot;, ini_get(&quot;include_path&quot;).PATH_SEPARATOR.BASEPATH.&quot;/contrib/&quot;);
require_once 'Zend/Loader.php';
</pre>
<h3>Adding it in autoload.php</h3>
<p>Open config/autoload.php and add the following.</p>
<pre class="brush: php; title: ; notranslate">
$autoload['helper'] = array('zend_framework');
</pre>
<h3>Using Zend in Codeigniter</h3>
<p>Now you can load any Zend class by adding Zend_Loader::loadClass(&#8216;ZEND-CLASS-HERE&#8217;);.<br />
You can see all the Zend classes here. <a href="http://framework.zend.com/manual/en/">http://framework.zend.com/manual/en/</a></p>
<p>Here are three examples.</p>
<h4>Zend_Service_Flickr</h4>
<p>Create a file controllers/flickr.php and add the following.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
class Flickr extends Controller
{
function __construct()
{
parent::Controller();

}

function index()
{

Zend_Loader::loadClass('Zend_Service_Flickr');

$flickr = new Zend_Service_Flickr('ADD-YOUR-KEY-HERE');
try
{

$results = $flickr-&gt;tagSearch(&quot;cat&quot;);
if ($results-&gt;totalResults() &gt; 0)
{

foreach ($results as $result)
{
echo '&lt;img src=&quot;'.$result-&gt;Square-&gt;uri.'&quot; /&gt;';
}

}
else
{
echo '&lt;p style=&quot;color: orange; font-weight: bold&quot;&gt;No Results Found.&lt;/p&gt;';
}
}
catch (Zend_Service_Exception $e)
{
echo '&lt;p style=&quot;color: red; font-weight: bold&quot;&gt;An error occured, please try again later. (' .$e-&gt;getMessage(). ')&lt;/p&gt;';
}

}
}

?&gt;
</pre>
<p>Don&#8217;t forget to change ADD-YOUR-KEY-HERE to your Flickr key.<br />
If you don&#8217;t have one, <a href="http://www.flickr.com/services/api/misc.api_keys.html">get it from here</a>.<br />
Then visit your controller, http://127.0.0.1/codeigniter/index.php/flickr to see the result.</p>
<h4>Using Zend_Gdata_YouTube</h4>
<p>Create another file controllers/youtube.php and add the following.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
class Youtube extends Controller
{
function __construct()
{
parent::Controller();

}

function index()
{

    Zend_Loader::loadClass('Zend_Gdata_YouTube');
    $youtube = new Zend_Gdata_YouTube();
    $query = $youtube-&gt;newVideoQuery();
    $query-&gt;videoQuery = 'cat';
    $query-&gt;startIndex = 10;
    $query-&gt;maxResults = 20;
    $query-&gt;orderBy = 'viewCount';

    $data['queryurl'] =  $query-&gt;queryUrl;
    $data['videofeed'] =  $youtube-&gt;getVideoFeed($query);
    $this-&gt;load-&gt;view('youtube_view', $data);
  }
}

?&gt;
</pre>
<h5>views/youtube_view.php</h5>
<p>Create this file and add the following.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php

foreach ($videofeed as $videoEntry) {
    echo &quot;---------VIDEO----------&lt;br /&gt;&quot;;
    echo &quot;Title: &quot; . $videoEntry-&gt;getVideoTitle() . &quot;&lt;br /&gt;&quot;;
    echo &quot;\nDescription:&lt;br /&gt;&quot;;
    echo $videoEntry-&gt;getVideoDescription();
    echo &quot;&lt;br /&gt;&lt;br /&gt;&quot;;
}
?&gt;
</pre>
<p>Then visit a new page http://127.0.0.1/codeigniter/index.php/youtube to the result.</p>
<h4>Using Google calendar</h4>
<p>Create controller/googlecalendar.php and add the following. Use your google email and password.</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
class Googlecalendar extends Controller
{
function __construct()
{
parent::Controller();

}

function index()
{
    Zend_Loader::loadClass('Zend_Gdata_Calendar');
     Zend_Loader::loadClass('Zend_Gdata_ClientLogin');
    // Parameters for ClientAuth authentication

$user = &quot;YOUR gmail HERE&quot;;
$pass = &quot;YOUR PASS&quot;;

$service = Zend_Gdata_Calendar::AUTH_SERVICE_NAME;
$client = Zend_Gdata_ClientLogin::getHttpClient($user, $pass, $service);
$service = new Zend_Gdata_Calendar($client);

try {
    $listFeed= $service-&gt;getCalendarListFeed();
} catch (Zend_Gdata_App_Exception $e) {
    echo &quot;Error: &quot; . $e-&gt;getMessage();
}
echo &quot;&lt;h1&gt;Calendar List Feed&lt;/h1&gt;&quot;;
echo &quot;&lt;ul&gt;&quot;;
foreach ($listFeed as $calendar) {
    echo &quot;&lt;li&gt;&quot; . $calendar-&gt;title .
         &quot; (Event Feed: &quot; . $calendar-&gt;id . &quot;)&lt;/li&gt;&quot;;
}
echo &quot;&lt;/ul&gt;&quot;;
}
}
?&gt;
</pre>
<p>Then again visit http://127.0.0.1/codeigniter/googlecalendar.</p>
<h4 class="download">
<a href="http://www.box.net/shared/0cxtrq8apq">Download Files</a></h4>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/' rel='bookmark' title='Zend framework Youtube class on Codeigniter with jquery'>Zend framework Youtube class on Codeigniter with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/' rel='bookmark' title='Zend Framework on Codeigniter: Youtube'>Zend Framework on Codeigniter: Youtube</a></li>
<li><a href='http://www.okadadesign.no/blog/zend-framework/zend-framework-flickr-class-on-codeignier-with-jquery/' rel='bookmark' title='Zend framework Flickr class on Codeignier with jquery'>Zend framework Flickr class on Codeignier with jquery</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Path problems with Codeigniter on Windows</title>
		<link>http://www.okadadesign.no/blog/xampp/path-problems-with-codeigniter-on-windows/</link>
		<comments>http://www.okadadesign.no/blog/xampp/path-problems-with-codeigniter-on-windows/#comments</comments>
		<pubDate>Sat, 21 Nov 2009 11:53:12 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[XAMPP]]></category>
		<category><![CDATA[Tips]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=414</guid>
		<description><![CDATA[ <p>I posted how to implement Zend Framework here. However I had a problem with Window&#8217;s path when I was trying it.</p> <p>I have found a couple of things about paths in Windows when I am using Codeigniter. As all know that Windows uses \ for the path. For example, C:\xampp\htdocs\codeigniter\system\contrib. Linux uses / [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter'>Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/' rel='bookmark' title='Zend Framework on Codeigniter: Youtube'>Zend Framework on Codeigniter: Youtube</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fpath-problems-with-codeigniter-on-windows%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fpath-problems-with-codeigniter-on-windows%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>I posted <a href="http://www.okadadesign.no/blog/?p=410">how to implement Zend Framework here</a>. However I had a problem with Window&#8217;s path when I was trying it.</p>
<p>I have found a couple of things about paths in Windows when I am using Codeigniter.<br />
As all know that Windows uses \ for the path. For example, C:\xampp\htdocs\codeigniter\system\contrib. Linux uses / for the path. For example, /home/1/o/mywebsite/www/codeigniter/system/.</p>
<p>If you are using XAMPP or WAMP for your web development, you might have a problem with this difference.<br />
<span id="more-414"></span></p>
<h3>BASEPATH in Codeigniter</h3>
<p>Enter the following to view/welcome_message.php in your freshly installed Codeigniter. </p>
<pre class="brush: php; title: ; notranslate">
echo 'Basepath: ' . BASEPATH . '&lt;br /&gt;';
</pre>
<p>And visit http://127.0.0.7/codeigniter/index.php/welcome.<br />
You will see the following.</p>
<pre class="brush: xml; title: ; notranslate">
1. Basepath: C:\xampp\htdocs\codeigniter/system/
</pre>
<p>Did you notice \codeigniter/?</p>
<p>In practical situation, you would add the following for your live server(Linux).</p>
<pre class="brush: php; title: ; notranslate">
ini_set(&quot;include_path&quot;, ini_get(&quot;include_path&quot;).
PATH_SEPARATOR.BASEPATH.&quot;/contrib/&quot;);
</pre>
<p>However this will not work on your Windows.<br />
You need to use the following instead.</p>
<pre class="brush: php; title: ; notranslate">
ini_set(&quot;include_path&quot;, ini_get(&quot;include_path&quot;).
PATH_SEPARATOR.str_replace(&quot;/&quot;, &quot;\\&quot;, BASEPATH).&quot;contrib\\&quot;);
</pre>
<p>str_replace() function will replace / in BASEPATH with \.</p>
<p>If you want to see some of your paths in Codeigniter, add the following in your view/welcome_message.php and see the results.</p>
<pre class="brush: php; title: ; notranslate">
&lt;html&gt;
&lt;head&gt;
&lt;title&gt;Welcome to CodeIgniter&lt;/title&gt;

&lt;style type=&quot;text/css&quot;&gt;

body {
 background-color: #fff;
 margin: 40px;
 font-family: Lucida Grande, Verdana, Sans-serif;
 font-size: 14px;
 color: #4F5155;
}

a {
 color: #003399;
 background-color: transparent;
 font-weight: normal;
}

h1 {
 color: #444;
 background-color: transparent;
 border-bottom: 1px solid #D0D0D0;
 font-size: 16px;
 font-weight: bold;
 margin: 24px 0 2px 0;
 padding: 5px 0 6px 0;
}

code {
 font-family: Monaco, Verdana, Sans-serif;
 font-size: 12px;
 background-color: #f9f9f9;
 border: 1px solid #D0D0D0;
 color: #002166;
 display: block;
 margin: 14px 0 14px 0;
 padding: 12px 10px 12px 10px;
}

&lt;/style&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;h2&gt;When you are using set_include_path(), before get_include_path(), it will add one semi-colon, after get_include_path.&lt;/h2&gt;
&lt;?php
$src_name= 'kame.png';
echo 'PART 1&lt;br /&gt;';
&gt;
&lt;?=
'1. Basepath: ' . BASEPATH . '&lt;br /&gt;'.
'2. Apppath: ' . APPPATH . '&lt;br /&gt;'.
'3. Ext: ' . EXT . '&lt;br /&gt;' .
'4. Fcpath: ' . FCPATH .'&lt;br /&gt;' .
'5. Self: ' . SELF .'&lt;br /&gt;' .
// '6. base_url(): ' . base_url() . '&lt;br /&gt;'.
'7. site_url(): ' . site_url(). '&lt;br /&gt;'.
'8. current_url(): ' . current_url(). '&lt;br /&gt;'.
'9. uri_string(): ' . uri_string(). '&lt;br /&gt;'.
'10. index_page(): ' . index_page(). '&lt;br /&gt;'.
'11. realpath(__FILE__): ' . realpath(__FILE__). '&lt;br /&gt;'.
'12. realpath(dirname(__FILE__)): ' . realpath(dirname(__FILE__)). '&lt;br /&gt;'.
'13. realpath(dirname(__FILE__))/: '. realpath(dirname(__FILE__)).'/'.'&lt;br /&gt;'.
'14. str_replace(&quot;\\&quot;, &quot;/&quot;, realpath(dirname(__FILE__))): '. str_replace(&quot;\\&quot;, &quot;/&quot;, realpath(dirname(__FILE__))).'&lt;br /&gt;'.
'14a. str_replace(&quot;/&quot;, &quot;\\&quot;, BASEPATH): '. str_replace(&quot;/&quot;, &quot;\\&quot;, BASEPATH).'&lt;br /&gt;'.
'15. getcwd(), current working directory: '. getcwd(). '&lt;br /&gt;'.
'16. PATH_SEPARATOR: ' . PATH_SEPARATOR. '&lt;br /&gt;'.
'17. basename($src_name,\'.png\')): ' . basename($src_name,'.png'). '&lt;br /&gt;'.
'18. ini_get(\'include_path\') . PATH_SEPARATOR . APPPATH . \'libraries\': ' . ini_get('include_path') . PATH_SEPARATOR . APPPATH . 'libraries' . '&lt;br /&gt;'.
'19. get_include_path() :'. get_include_path().PATH_SEPARATOR.'&lt;br /&gt;' ;

&gt;
&lt;?php
echo '&lt;br /&gt;&lt;br /&gt;PART 2&lt;br /&gt;&lt;br /&gt;';
echo '1. dirname(dirname(__FILE__));'.dirname(dirname(__FILE__)).'&lt;br /&gt;';
echo '2. ini_get(\'include_path\') . PATH_SEPARATOR . str_replace(&quot;/&quot;, &quot;\\&quot;, APPPATH) . \'libraries\': ' . ini_get('include_path') . PATH_SEPARATOR . str_replace(&quot;/&quot;, &quot;\\&quot;, APPPATH) . 'libraries' . '&lt;br /&gt;';
echo '3. set_include_path(get_include_path() . PATH_SEPARATOR . :'. set_include_path(get_include_path() . PATH_SEPARATOR) .'&lt;br /&gt;';
echo '4. ini_get(\'include_path\'): ' . ini_get('include_path') . '&lt;br /&gt;';
echo '5. PATH_SEPARATOR . APPPATH . \'libraries\': ' .  PATH_SEPARATOR . APPPATH . 'libraries' . '&lt;br /&gt;'
// 'realpath($_SERVER['DOCUMENT_ROOT']): ' . realpath($_SERVER['DOCUMENT_ROOT']).'&lt;br /&gt;';

&gt;

&lt;?php
echo '&lt;br /&gt;&lt;br /&gt;PART 3&lt;br /&gt;&lt;br /&gt;';
echo '1. $_SERVER[\'DOCUMENT_ROOT\']: '. $_SERVER['DOCUMENT_ROOT'];
echo &quot;&lt;br /&gt;&quot;;
$base_url = '\\img\\';
$src_name = 'photo.png';
$base_path = realpath(&quot;photo.png&quot;);

echo '$base_url(): ';
echo &quot;$base_url () &lt;br /&gt;&quot;;
echo 'realpath(\'./img/\'): ';
echo &quot;&lt;br /&gt;&quot;;
echo realpath('./img/') ;
echo &quot;&lt;br /&gt;&quot;;
echo '$src_name: ';
echo &quot;$src_name&quot;;
echo &quot;&lt;br /&gt;&lt;br /&gt;&quot;;
echo '$_SERVER[\'DOCUMENT_ROOT\']: ';
echo  $_SERVER['DOCUMENT_ROOT'];
echo &quot;&lt;br /&gt;&quot;;
echo 'realpath($_SERVER[\'DOCUMENT_ROOT\']): ';
echo realpath($_SERVER['DOCUMENT_ROOT']);
echo &quot;&lt;br /&gt;&quot;;
$base_path = realpath('./img/');//This will show C:\xampp\htdocs\ci_day6_working_copy\img

$src_name = 'photo.png';//source name
$source_image = realpath($base_path.'/'.$src_name);
echo '$source_image is: ' . $source_image;

 echo &quot;&lt;br /&gt;&quot;;
$realpathtoBasepath = realpath(BASEPATH.'fonts/texb.ttf');
echo $realpathtoBasepath;
&gt;

&lt;?php
echo '&lt;br /&gt;&lt;br /&gt;PART 4&lt;br /&gt;&lt;br /&gt;';
echo 'Here echoing $my_include_folder = realpath(dirname(__FILE__)).\'/assets/classes\';'.&quot;&lt;br /&gt;&quot;;
echo 'Here is the second line get_include_path() . PATH_SEPARATOR . $my_include_folder1;&lt;br /&gt;';
$my_include_folder1 = realpath(dirname(__FILE__)).'/assets/classes1';
echo get_include_path();
echo PATH_SEPARATOR;
echo '$my_include_folder1: '.$my_include_folder1. &quot;&lt;br /&gt;&quot;;
echo get_include_path() . PATH_SEPARATOR . $my_include_folder1;

&gt;

&lt;?php
echo '&lt;br /&gt;&lt;br /&gt;PART 5&lt;br /&gt;&lt;br /&gt;';
echo 'Here echoing $my_include_folder2 = realpath(dirname(__FILE__)).\'\\assets\\classes\';'.&quot;&lt;br /&gt;&quot;;
echo 'Here is the second line set_include_path(get_include_path() . PATH_SEPARATOR . $my_include_folder2);&lt;br /&gt;';
$my_include_folder2 = realpath(dirname(__FILE__)).'\\assets\\classes2';
echo get_include_path() . PATH_SEPARATOR . $my_include_folder2;

&gt;

&lt;?php
echo '&lt;br /&gt;&lt;br /&gt;PART 6&lt;br /&gt;&lt;br /&gt;';
echo 'Here echoing ini_set(&quot;include_path&quot;, ini_get(&quot;include_path&quot;).PATH_SEPARATOR.BASEPATH.&quot;/contrib/&quot;); '.&quot;&lt;br /&gt;&quot;;
echo ini_get(&quot;include_path&quot;).PATH_SEPARATOR.BASEPATH.&quot;/contrib/&quot;; 

&gt;
&lt;?php
echo '&lt;br /&gt;&lt;br /&gt;PART 7&lt;br /&gt;&lt;br /&gt;';
echo 'Here echoing ini_get(&quot;include_path&quot;).PATH_SEPARATOR.str_replace(&quot;/&quot;, &quot;\\&quot;, BASEPATH).&quot;\\contrib\\&quot;
'.&quot;&lt;br /&gt;&quot;;
echo ini_get(&quot;include_path&quot;).PATH_SEPARATOR.str_replace(&quot;/&quot;, &quot;\\&quot;, BASEPATH).&quot;contrib\\Zend\\Loader.php&quot;

&gt;

&lt;/body&gt;
&lt;/html&gt;
</pre>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter'>Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/' rel='bookmark' title='Zend Framework on Codeigniter: Youtube'>Zend Framework on Codeigniter: Youtube</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/path-problems-with-codeigniter-on-windows/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Zend framework Youtube class on Codeigniter with jquery</title>
		<link>http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/</link>
		<comments>http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/#comments</comments>
		<pubDate>Sun, 01 Nov 2009 06:20:50 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[XAMPP]]></category>
		<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[youtube]]></category>
		<category><![CDATA[zend]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=504</guid>
		<description><![CDATA[ Download <p>This does not contain Codeigniter or Zend framework. If you need them please download it from here. </p> Introduction <p>The previous post &#8220;Zend Framework on Codeigniter: Youtube&#8221; involved three steps to see a video. And it did not have any style.</p> Goals <p>I will reduce it to two steps, add a minimum [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/' rel='bookmark' title='Zend Framework on Codeigniter: Youtube'>Zend Framework on Codeigniter: Youtube</a></li>
<li><a href='http://www.okadadesign.no/blog/zend-framework/zend-framework-flickr-class-on-codeignier-with-jquery/' rel='bookmark' title='Zend framework Flickr class on Codeignier with jquery'>Zend framework Flickr class on Codeignier with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fzend-framework-youtube-class-on-codeigniter-with-jquery%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fzend-framework-youtube-class-on-codeigniter-with-jquery%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<h4>Download</h4>
<p>This does not contain Codeigniter or Zend framework. If you need them please download it from <a href="http://www.okadadesign.no/blog/?p=452">here</a>.  </p>
<h3>Introduction</h3>
<p>The previous post <a href="http://www.okadadesign.no/blog/?p=452">&#8220;Zend Framework on Codeigniter: Youtube&#8221;</a> involved three steps to see a video. And it did not have any style.</p>
<h3>Goals</h3>
<p>I will reduce it to two steps, add a minimum styling and use jquery tools scrollable.<br />
<img src="http://www.okadadesign.no/blog/wp-content/uploads/2009/11/zend_youtube_2_1.jpg" alt="zend_youtube_2_1" title="zend_youtube_2_1" width="460" height="376" class="alignleft size-full wp-image-505" /></p>
<div class="clearboth"></div>
<p><span id="more-504"></span><br />
The default videos in a scrollabe screen will be three. </p>
<h3>Resources</h3>
<ol>
<li>
<a href="http://flowplayer.org/tools/demos/scrollable/vertical.html">Jquery Tools Scrollable</a>: I am using a vertical scrollabe this time.</li>
<li>
<a href="http://framework.zend.com/manual/en/zend.gdata.youtube.html">Zend Framework Youtube class</a></li>
<li><a href="http://codeigniter.com/user_guide/index.html">Codeigniter</a></li>
</ol>
<h3>Config</h3>
<p>system/application/config/autoload.php</p>
<pre class="brush: php; title: ; notranslate">
$autoload['helper'] = array('zend_framework', 'url');
</pre>
<p>Autoload the zend_framework and url.<br />
</p>
<p>system/application/config/config.php</p>
<pre class="brush: php; title: ; notranslate">
$config['base_url']	=&quot;http://127.0.0.1/ci_zend_youtube/&quot;;
</pre>
<p></p>
<p>Add your base url here.</p>
<h3>Controller</h3>
<p>system/application/controllers/yt_scroll.php<br />
</p>
<pre class="brush: php; title: ; notranslate">
&lt;?php
class Yt_scroll extends Controller{
    protected $_youTube;

function __construct() {
    parent::Controller();
    Zend_Loader::loadClass('Zend_Gdata_YouTube');

    $this-&gt;_youTube = new Zend_Gdata_YouTube;

    }

function index(){

    // Gets playlists
    $data['playlistfeed']= $this-&gt;_youTube-&gt;getPlaylistListFeed('NationalGeographic');
    $this-&gt;load-&gt;view ('youtube_view3',$data);
    }

public function listAction(){
    // Gets playlist videos

    $playlistId = $this-&gt;uri-&gt;segment(4);
    $query = $this-&gt;_youTube-&gt;newVideoQuery(
    'http://gdata.youtube.com/feeds/playlists/' . $playlistId);
    $data['videoFeed']= $this-&gt;_youTube-&gt;getVideoFeed($query);
    $this-&gt;load-&gt;view('listaction2_view', $data);
    }

}
</pre>
<p></p>
<h4>Contructor</h4>
<p>A variable $_youTube is created with protected.<br />
Constructor function loads Zend_Gdata_YouTube with Zend_Loader.<br />
And a new object is created.<br />
</p>
<h4>Index () function</h4>
<p>PlaylistListFeed of National Geographic is stored in playlistfeed and this will be loaded in youtube_view3.</p>
<h4>listAction () function</h4>
<p>The fourth segment of uri will be used for $playlistId.<br />
Query is stored to $query and videofeed will be in </p>
<h3>View</h3>
<p>system/application/views/youtube_view3.php</p>
<pre class="brush: php; title: ; notranslate">
&lt;!DOCTYPE html PUBLIC&quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot;
       &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;
&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;en&quot; lang=&quot;en&quot;&gt;
&lt;head&gt;
  &lt;meta http-equiv=&quot;content-type&quot; content=&quot;text/html; charset=utf-8&quot; /&gt;
  &lt;title&gt;Video lists&lt;/title&gt;
 &lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;&lt;?=base_url();?&gt;css/default.css&quot; /&gt;
 &lt;script src=&quot;http://cdn.jquerytools.org/1.1.2/full/jquery.tools.min.js&quot;&gt;&lt;/script&gt;

&lt;/head&gt;
&lt;body&gt;
    &lt;div id=&quot;wrapper&quot;&gt;
&lt;h1&gt;National Geographic Videos on Youtube&lt;/h1&gt;
&lt;div&gt;
&lt;?php foreach ($playlistfeed as $playlistEntry): ?&gt;
&lt;?php $id = substr(strrchr(
$playlistEntry-&gt;getPlaylistVideoFeedUrl(), '/'
), 1); ?&gt;
&lt;h3&gt;
&lt;a href=&quot;yt_scroll/listAction/id/&lt;?php echo $id; ?&gt;/&quot;&gt;
&lt;?php echo $playlistEntry-&gt;title-&gt;text; ?&gt;
&lt;/a&gt;
&lt;/h3&gt;
&lt;div class=&quot;pane&quot;&gt;

&lt;p&gt;&lt;?php echo $playlistEntry-&gt;description-&gt;text; ?&gt;&lt;/p&gt;
&lt;/div&gt;
&lt;?php endforeach; ?&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;/body&gt;
&lt;/html&gt;
</pre>
<h3>Conclusion</h3>
<p>You can add a form to submit the video subject like <a href="http://www.okadadesign.no/blog/?p=478">I did for Flickr.</a> You may want to add this to your side column. Pagenation can be added to this.</p>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-on-codeigniter-youtube/' rel='bookmark' title='Zend Framework on Codeigniter: Youtube'>Zend Framework on Codeigniter: Youtube</a></li>
<li><a href='http://www.okadadesign.no/blog/zend-framework/zend-framework-flickr-class-on-codeignier-with-jquery/' rel='bookmark' title='Zend framework Flickr class on Codeignier with jquery'>Zend framework Flickr class on Codeignier with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to delete index.php from Codeigniter in localhost</title>
		<link>http://www.okadadesign.no/blog/xampp/how-to-delete-index-php-from-codeigniter-in-localhost/</link>
		<comments>http://www.okadadesign.no/blog/xampp/how-to-delete-index-php-from-codeigniter-in-localhost/#comments</comments>
		<pubDate>Mon, 28 Sep 2009 09:15:06 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[Codeigniter]]></category>
		<category><![CDATA[XAMPP]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=195</guid>
		<description><![CDATA[ <p></p> <p></p> If you have installed a codeigniter in XAMPP and want to delete index.php in your URL, this is how I did it.</p> <p>For example your URL is,</p> <p>http://127.0.0.1/ci_cms/index.php/admin/users/manage</p> <p>And you want to make it to,</p> <p>http://127.0.0.1/ci_cms/admin/users/manage</p> <p>Firstly, it does not matter if you move application folder out of system folder or [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter'>Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-send-email-from-your-own-localhost/' rel='bookmark' title='How to send email from your own localhost'>How to send email from your own localhost</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-delete-index-php-from-codeigniter-in-localhost%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-delete-index-php-from-codeigniter-in-localhost%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p><img alt="" src="http://www.apachefriends.org/images/1240.jpg" title="XAMPP" class="alignleft" width="200" height="59" /></p>
<p><img class="alignleft" title="Codeigniter" src="http://codeigniter.com/images/design/ci_logo2.gif" alt="" width="170" height="73" /></p>
<div class="clearleft padtop">
If you have installed a codeigniter in XAMPP and want to delete index.php in your URL, this is how I did it.</p>
<p>For example your URL is,</p>
<p>http://127.0.0.1/ci_cms/index.php/admin/users/manage</p>
<p>And you want to make it to,</p>
<p>http://127.0.0.1/ci_cms/admin/users/manage</p>
<p>Firstly, it does not matter if you move application folder out of system folder or keep it under system folder.<br />
You need to modify config.php. $config['index_page'] = &#8220;&#8221;;<br />
And also add .htaccess to the same level as system folder.<br />
Your .htaccess file should contain the following.</p>
<div class="codesnip-container" >RewriteEngine on<br />
RewriteCond $1 !^(index\.php|images|scripts|css|robots\.txt)<br />
RewriteRule ^(.*)$ index.php/$1 [L]</div>
<p><a href="http://codeigniter.com/user_guide/general/urls.html">Codeigniter suggests</a> the following code. But if you use it some of your link will go to http://127.0.0/ and shows xampp home page, http://127.0.0/xampp.<br />
If you are installing CI in your root, this code will be fine, otherwise use the first .htaccess for your XAMPP.</p>
<div class="codesnip-container" >RewriteEngine on<br />
RewriteCond $1 !^(index\.php|images|robots\.txt)<br />
RewriteRule ^(.*)$ /index.php/$1 [L]</div>
<p>You can add folder names in images|scripts|css in order to access these folders.<br />
For example I use TinyMCE and I added it under scripts folder which is the same level as system folder.</p>
<p>Also it is good idea to add the following code to a view/header.php.<br />
This enable you to add images like image/myimage.jpg and automatically it becomes http://127.0.0.1/ci_cms/images/myimage.jpg.</p>
<p>That&#8217;s it.</p></div>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter'>Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-send-email-from-your-own-localhost/' rel='bookmark' title='How to send email from your own localhost'>How to send email from your own localhost</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/how-to-delete-index-php-from-codeigniter-in-localhost/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>How to add httpd.conf to XAMPP</title>
		<link>http://www.okadadesign.no/blog/xampp/how-to-add-httpd-conf-to-xampp/</link>
		<comments>http://www.okadadesign.no/blog/xampp/how-to-add-httpd-conf-to-xampp/#comments</comments>
		<pubDate>Sat, 12 Sep 2009 16:54:27 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[XAMPP]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=151</guid>
		<description><![CDATA[ <p>I was reading &#8220;Practical web 2.0&#8243; by Quentin Zervaas. In chapater 2 there is a section which adds httpd.conf to folder. I struggled a bit but I made it finally. This is how.</p> <p>My directory structure is like this.</p> -hdocs -phpweb20 -data -htdocs -include -templates -httpd.conf <p>I added the following to httpd.conf</p> &#60;VirtualHost [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/ubuntu/installing-lamp-and-phpmyadmin-on-ubuntu/' rel='bookmark' title='Installing LAMP and phpMyAdmin on Ubuntu'>Installing LAMP and phpMyAdmin on Ubuntu</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-start-zend-framework-in-xampp/' rel='bookmark' title='How to start Zend Framework in Xampp'>How to start Zend Framework in Xampp</a></li>
<li><a href='http://www.okadadesign.no/blog/web-development/changing-documentroot-from-varwww-to-homemynamewww/' rel='bookmark' title='Changing DocumentRoot from /var/www to /home/myname/www'>Changing DocumentRoot from /var/www to /home/myname/www</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-add-httpd-conf-to-xampp%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-add-httpd-conf-to-xampp%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>I was reading &#8220;Practical web 2.0&#8243; by Quentin Zervaas. In chapater 2 there is a section which adds httpd.conf to folder.<br />
I struggled a bit but I made it finally. This is how.</p>
<p>My directory structure is like this.</p>
<pre>
-hdocs
    -phpweb20
       -data
       -htdocs
       -include
       -templates
       -httpd.conf
</pre>
<p>I added the following to httpd.conf</p>
<pre class="brush: php; title: ; notranslate">
&lt;VirtualHost *:80&gt;
ServerName phpweb20
DocumentRoot &quot;c:/xampp/htdocs/phpweb20/htdocs&quot;
&lt;Directory &quot;c:/xampp/htdocs/phpweb20/htdocs&quot;&gt;
AllowOverride None
Options All
&lt;/Directory&gt;
php_value include_path &quot;.;c:/xampp/htdocs/phpweb20/include;c:/xampp/php/pear&quot;
php_value magic_quotes_gpc off
php_value register_globals off
&lt;/VirtualHost&gt;</pre>
<p>I also added the following to C:\xampp\apache\conf\httpd.conf</p>
<pre class="brush: php; title: ; notranslate"># For phpweb20 config
Include &quot;C:/xampp/htdocs/phpweb20/httpd.conf&quot;</pre>
<p>And restart apache.</p>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/ubuntu/installing-lamp-and-phpmyadmin-on-ubuntu/' rel='bookmark' title='Installing LAMP and phpMyAdmin on Ubuntu'>Installing LAMP and phpMyAdmin on Ubuntu</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-start-zend-framework-in-xampp/' rel='bookmark' title='How to start Zend Framework in Xampp'>How to start Zend Framework in Xampp</a></li>
<li><a href='http://www.okadadesign.no/blog/web-development/changing-documentroot-from-varwww-to-homemynamewww/' rel='bookmark' title='Changing DocumentRoot from /var/www to /home/myname/www'>Changing DocumentRoot from /var/www to /home/myname/www</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/how-to-add-httpd-conf-to-xampp/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How to start Zend Framework in Xampp</title>
		<link>http://www.okadadesign.no/blog/xampp/how-to-start-zend-framework-in-xampp/</link>
		<comments>http://www.okadadesign.no/blog/xampp/how-to-start-zend-framework-in-xampp/#comments</comments>
		<pubDate>Thu, 10 Sep 2009 06:06:49 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[XAMPP]]></category>
		<category><![CDATA[Zend Framework]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=147</guid>
		<description><![CDATA[ <p>I am using XAMPP and I just downloaded Zend Framework 1.9.2. I moved that folder under htdocs. I also created a folder called zendpractice in htdocs. Then Start> Start search, type cmd. You should have a cmd.exe pop up.</p> <p>Type the following in cmd.</p> cd c:\xampp\htdocs\zendpractice <p>Hit enter. Then you will see c:\xampp\htdocs\zendpractice>. [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-add-httpd-conf-to-xampp/' rel='bookmark' title='How to add httpd.conf to XAMPP'>How to add httpd.conf to XAMPP</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/' rel='bookmark' title='Zend framework Youtube class on Codeigniter with jquery'>Zend framework Youtube class on Codeigniter with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-start-zend-framework-in-xampp%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-start-zend-framework-in-xampp%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p>I am using XAMPP and I just downloaded Zend Framework 1.9.2.<br />
I moved that folder under htdocs.<br />
I also created a folder called zendpractice in htdocs.<br />
Then Start> Start search, type cmd.<br />
You should have a cmd.exe pop up.</p>
<p>Type the following in cmd.</p>
<div class="codesnip-container" >cd c:\xampp\htdocs\zendpractice</div>
<p>Hit enter. Then you will see c:\xampp\htdocs\zendpractice>.<br />
Type the following after that line.</p>
<div class="codesnip-container" >c:\xampp\htdocs\ZendFramework-1.9.2\bin\zf.bat create project quickstart</div>
<p>It will tell you Creating project at C:/xampp/htdocs/Zendpractice/quickstart.</p>
<p>Then check your folder if all the files and folders are created.</p>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-add-httpd-conf-to-xampp/' rel='bookmark' title='How to add httpd.conf to XAMPP'>How to add httpd.conf to XAMPP</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/zend-framework-youtube-class-on-codeigniter-with-jquery/' rel='bookmark' title='Zend framework Youtube class on Codeigniter with jquery'>Zend framework Youtube class on Codeigniter with jquery</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-implement-zend-framework-with-codeigniter-on-windows/' rel='bookmark' title='How to implement Zend Framework with Codeigniter'>How to implement Zend Framework with Codeigniter</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/how-to-start-zend-framework-in-xampp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to send email from your own localhost</title>
		<link>http://www.okadadesign.no/blog/xampp/how-to-send-email-from-your-own-localhost/</link>
		<comments>http://www.okadadesign.no/blog/xampp/how-to-send-email-from-your-own-localhost/#comments</comments>
		<pubDate>Wed, 09 Sep 2009 13:31:59 +0000</pubDate>
		<dc:creator>shinokada</dc:creator>
				<category><![CDATA[Web Development]]></category>
		<category><![CDATA[XAMPP]]></category>
		<category><![CDATA[mail]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://www.okadadesign.no/blog/?p=140</guid>
		<description><![CDATA[ <p></p> <p> You may want to test your form or email in your laptop. If you are using XAMPP, go to XAMPP &#62; PHP and open php.ini. Around line 700 you will find</p> [mail function] ; For Win32 only. <p>Then change that line to the following. You need to find your SMTP host. [...]
Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/web-development/sending-email-from-localhost-using-msmtp-with-gmail/' rel='bookmark' title='Sending email from localhost using MSMTP with gmail'>Sending email from localhost using MSMTP with gmail</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter'>Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-delete-index-php-from-codeigniter-in-localhost/' rel='bookmark' title='How to delete index.php from Codeigniter in localhost'>How to delete index.php from Codeigniter in localhost</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<div class="tweetmeme_button" style="float: right; margin-left: 10px;">
			<a href="http://api.tweetmeme.com/share?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-send-email-from-your-own-localhost%2F"><br />
				<img src="http://api.tweetmeme.com/imagebutton.gif?url=http%3A%2F%2Fwww.okadadesign.no%2Fblog%2Fxampp%2Fhow-to-send-email-from-your-own-localhost%2F&amp;style=normal&amp;b=2" height="61" width="50" /><br />
			</a>
		</div>
<p><img class="size-full wp-image-143 alignleft" title="email180" src="http://www.okadadesign.no/blog/wp-content/uploads/2009/09/email180.jpg" alt="email180" width="180" height="162" /></p>
<div class="clearboth"> </div>
<p><span id="more-140"></span><br />
You may want to test your form or email in your laptop. If you are using XAMPP, go to XAMPP &gt; PHP and open php.ini. Around line 700 you will find</p>
<div class="codesnip-container" >[mail function]<br />
; For Win32 only.</div>
<p>Then change that line to the following. You need to find your SMTP host.<br />
I am setting up for my work in the following code. I just need to swap ; for work use and home use.</p>
<div class="codesnip-container" >[mail function]<br />
; For Win32 only.<br />
;SMTP = localhost<br />
;For my work use<br />
SMTP = work.mycompany.com</p>
<p>;For home use<br />
;SMTP = smtp.mybroadband.net<br />
smtp_port = 25</p>
<p>; For Win32 only.<br />
sendmail_from = <span class="mh-email">myn<a href='http://www.google.com/recaptcha/mailhide/d?k=01_G64DEJsZWQ2ejuqj5LY3g==&amp;c=hgqbY1I7cuzjtDryerEKMEZj88TewtrLYbGp48KhbEU=' onclick="window.open('http://www.google.com/recaptcha/mailhide/d?k=01_G64DEJsZWQ2ejuqj5LY3g==&amp;c=hgqbY1I7cuzjtDryerEKMEZj88TewtrLYbGp48KhbEU=', '', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=500,height=300'); return false;" title="Reveal this e-mail address">...</a>@mycompany.com</span></p></div>
<p>Related posts:<ol>
<li><a href='http://www.okadadesign.no/blog/web-development/sending-email-from-localhost-using-msmtp-with-gmail/' rel='bookmark' title='Sending email from localhost using MSMTP with gmail'>Sending email from localhost using MSMTP with gmail</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/windows-xp-in-vmware-on-windows-7-localhost-and-base-url-of-codeigniter/' rel='bookmark' title='Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter'>Windows XP in VMware on Windows 7, localhost and base url of CodeIgniter</a></li>
<li><a href='http://www.okadadesign.no/blog/xampp/how-to-delete-index-php-from-codeigniter-in-localhost/' rel='bookmark' title='How to delete index.php from Codeigniter in localhost'>How to delete index.php from Codeigniter in localhost</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://www.okadadesign.no/blog/xampp/how-to-send-email-from-your-own-localhost/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

