<?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>MaggsWeb:7 &#187; Uncategorized</title>
	<atom:link href="http://www.maggsweb.com/category/uncategorized/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.maggsweb.com</link>
	<description>www.maggsweb.com</description>
	<lastBuildDate>Sat, 21 Aug 2010 20:50:00 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>PHP Classes &#8211; quick example</title>
		<link>http://www.maggsweb.com/uncategorized/php-classes-quick-example/</link>
		<comments>http://www.maggsweb.com/uncategorized/php-classes-quick-example/#comments</comments>
		<pubDate>Wed, 16 Jun 2010 13:04:32 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[class]]></category>
		<category><![CDATA[function]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.maggsweb.com/?p=938</guid>
		<description><![CDATA[Taken from http://mypaaji.com/Index.php/php-quick-reference/ ?View Code PHP&#60;?php class ClassName&#40;&#41; // class definition &#123; public $var1; // property with public access private $var2; // property with private access &#160; // constructor method public function __construct&#40;&#41; &#123; // code to initialize object goes here &#125; &#160; // public method public function setFoo&#40;$value&#41; &#123; // properties and methods are [...]]]></description>
			<content:encoded><![CDATA[<hr />
Taken from <a href="http://mypaaji.com/Index.php/php-quick-reference/" onclick="pageTracker._trackPageview('/outgoing/mypaaji.com/Index.php/php-quick-reference/?referer=');">http://mypaaji.com/Index.php/php-quick-reference/</a></p>
<hr />
<span id="more-938"></span></p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?" onclick="pageTracker._trackPageview('/outgoing/www.ericbess.com/ericblog/2008/03/03/wp-codebox/_examples?referer=');"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p938code2'); return false;">View Code</a> PHP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p9382"><td class="code" id="p938code2"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #000000; font-weight: bold;">class</span> ClassName<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #666666; font-style: italic;">// class definition</span>
<span style="color: #009900;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000088;">$var1</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// property with public access</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000088;">$var2</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// property with private access</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// constructor method</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> __construct<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #666666; font-style: italic;">// code to initialize object goes here</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// public method</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> setFoo<span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #666666; font-style: italic;">// properties and methods are accessed inside the class</span>
		<span style="color: #666666; font-style: italic;">// using $this-&gt;</span>
		<span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span> <span style="color: #004000;">var2</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$value</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// private method</span>
	<span style="color: #000000; font-weight: bold;">private</span> <span style="color: #000000; font-weight: bold;">function</span> bar<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #666666; font-style: italic;">// more code goes here</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// destructor method</span>
	<span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> __destruct<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #666666; font-style: italic;">// clean up code goes here</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #000088;">$c</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> ClassName<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// create a new instance of the object</span>
<span style="color: #000088;">$c</span><span style="color: #339933;">-&gt;</span> <span style="color: #004000;">var1</span> <span style="color: #339933;">=</span> <span style="color: #cc66cc;">42</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// properties and methods are accessed using - &gt;</span>
<span style="color: #000088;">$c</span><span style="color: #339933;">-&gt;</span> <span style="color: #004000;">setFoo</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Hello World'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://www.maggsweb.com/uncategorized/php-classes-quick-example/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Download and Upload Files Over FTP</title>
		<link>http://www.maggsweb.com/uncategorized/how-to-download-and-upload-files-over-ftp/</link>
		<comments>http://www.maggsweb.com/uncategorized/how-to-download-and-upload-files-over-ftp/#comments</comments>
		<pubDate>Wed, 16 Jun 2010 12:55:34 +0000</pubDate>
		<dc:creator>chris</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[ftp]]></category>
		<category><![CDATA[function]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.maggsweb.com/?p=934</guid>
		<description><![CDATA[Taken from http://mypaaji.com/Index.php/how-to-download-upload-transfer-files-over-ftp/ The below given listing illustrates the process. First, a connection to the FTP server is initialized with a call to ftp_connect(); this function returns a connection handle that is used in all subsequent calls. The ftp_login() function is then used to log in to the server, while the ftp_close() function is used [...]]]></description>
			<content:encoded><![CDATA[<hr />
Taken from <a href="http://mypaaji.com/Index.php/how-to-download-upload-transfer-files-over-ftp/" onclick="pageTracker._trackPageview('/outgoing/mypaaji.com/Index.php/how-to-download-upload-transfer-files-over-ftp/?referer=');">http://mypaaji.com/Index.php/how-to-download-upload-transfer-files-over-ftp/</a></p>
<hr />
The below given listing illustrates the process. First, a connection to the FTP server is initialized with a call to ftp_connect();  this function returns a connection handle that is used in all subsequent calls. The ftp_login() function is then used to log in to the server, while the ftp_close()  function is used to terminate the connection and end the session. Between the calls to ftp_connect() and ftp_disconnect(), it is possible to perform all the actions commonly associated with an FTP session.</p>
<p>The below given listing illustrates four of the most common: listing files using ftp_nlist(); uploading files with ftp_put(); downloading files with ftp_get(); and deleting files with ftp_delete(). Note that ftp_put() and ftp_get() must be supplied with the remote and local file name, together with the transfer type (binary or ASCII).</p>
<p><span id="more-934"></span></p>

<div class="wp_codebox_msgheader"><span class="right"><sup><a href="http://www.ericbess.com/ericblog/2008/03/03/wp-codebox/#examples" target="_blank" title="WP-CodeBox HowTo?" onclick="pageTracker._trackPageview('/outgoing/www.ericbess.com/ericblog/2008/03/03/wp-codebox/_examples?referer=');"><span style="color: #99cc00">?</span></a></sup></span><span class="left"><a href="javascript:;" onclick="javascript:showCodeTxt('p934code4'); return false;">View Code</a> PHP</span><div class="codebox_clear"></div></div><div class="wp_codebox"><table><tr id="p9344"><td class="code" id="p934code4"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #666666; font-style: italic;">// set access parameters</span>
<span style="color: #000088;">$host</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;ftp.domain.dom&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$user</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;user&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$pass</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;password&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$dir</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;/htdocs&quot;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">// open connection to FTP server</span>
<span style="color: #000088;">$conn</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/ftp_connect" onclick="pageTracker._trackPageview('/outgoing/www.php.net/ftp_connect?referer=');"><span style="color: #990000;">ftp_connect</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$host</span><span style="color: #009900;">&#41;</span> or <a href="http://www.php.net/die" onclick="pageTracker._trackPageview('/outgoing/www.php.net/die?referer=');"><span style="color: #990000;">die</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ERROR: Cannot connect&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">// log in</span>
<a href="http://www.php.net/ftp_login" onclick="pageTracker._trackPageview('/outgoing/www.php.net/ftp_login?referer=');"><span style="color: #990000;">ftp_login</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$conn</span><span style="color: #339933;">,</span> <span style="color: #000088;">$user</span><span style="color: #339933;">,</span> <span style="color: #000088;">$pass</span><span style="color: #009900;">&#41;</span> or <a href="http://www.php.net/die" onclick="pageTracker._trackPageview('/outgoing/www.php.net/die?referer=');"><span style="color: #990000;">die</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ERROR: Cannot log in&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">// get file listing</span>
<span style="color: #000088;">$list</span> <span style="color: #339933;">=</span> <a href="http://www.php.net/ftp_nlist" onclick="pageTracker._trackPageview('/outgoing/www.php.net/ftp_nlist?referer=');"><span style="color: #990000;">ftp_nlist</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$conn</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">&quot;.&quot;</span><span style="color: #009900;">&#41;</span> or <a href="http://www.php.net/die" onclick="pageTracker._trackPageview('/outgoing/www.php.net/die?referer=');"><span style="color: #990000;">die</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ERROR: Cannot list files&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">foreach</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$list</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$file</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;<span style="color: #006699; font-weight: bold;">$file</span>&quot;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">// Download a file</span>
<span style="color: #000088;">$remote</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;code.zip&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$local</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;code_sny.zip&quot;</span><span style="color: #339933;">;</span>
<a href="http://www.php.net/ftp_get" onclick="pageTracker._trackPageview('/outgoing/www.php.net/ftp_get?referer=');"><span style="color: #990000;">ftp_get</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$conn</span><span style="color: #339933;">,</span> <span style="color: #000088;">$local</span><span style="color: #339933;">,</span> <span style="color: #000088;">$remote</span><span style="color: #339933;">,</span> FTP_BINARY<span style="color: #009900;">&#41;</span> or <a href="http://www.php.net/die" onclick="pageTracker._trackPageview('/outgoing/www.php.net/die?referer=');"><span style="color: #990000;">die</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ERROR: Cannot download file: <span style="color: #006699; font-weight: bold;">$remote</span>&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;File [<span style="color: #006699; font-weight: bold;">$remote</span>] successfully downloaded as [<span style="color: #006699; font-weight: bold;">$local</span>]&quot;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">// Upload a file</span>
<span style="color: #000088;">$local</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;photoSny.jpg&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$remote</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;photoSny.jpg&quot;</span><span style="color: #339933;">;</span>
<a href="http://www.php.net/ftp_put" onclick="pageTracker._trackPageview('/outgoing/www.php.net/ftp_put?referer=');"><span style="color: #990000;">ftp_put</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$conn</span><span style="color: #339933;">,</span> <span style="color: #000088;">$remote</span><span style="color: #339933;">,</span> <span style="color: #000088;">$local</span><span style="color: #339933;">,</span> FTP_BINARY<span style="color: #009900;">&#41;</span> or <a href="http://www.php.net/die" onclick="pageTracker._trackPageview('/outgoing/www.php.net/die?referer=');"><span style="color: #990000;">die</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ERROR: Cannot upload file: <span style="color: #006699; font-weight: bold;">$local</span>&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;File [<span style="color: #006699; font-weight: bold;">$local</span>] successfully uploaded as [<span style="color: #006699; font-weight: bold;">$remote</span>]&quot;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">// Delete a file</span>
<span style="color: #000088;">$remote</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;someFile.tmp&quot;</span><span style="color: #339933;">;</span>
<a href="http://www.php.net/ftp_delete" onclick="pageTracker._trackPageview('/outgoing/www.php.net/ftp_delete?referer=');"><span style="color: #990000;">ftp_delete</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$conn</span><span style="color: #339933;">,</span> <span style="color: #000088;">$remote</span><span style="color: #009900;">&#41;</span> or <a href="http://www.php.net/die" onclick="pageTracker._trackPageview('/outgoing/www.php.net/die?referer=');"><span style="color: #990000;">die</span></a><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">&quot;ERROR: Cannot delete file: <span style="color: #006699; font-weight: bold;">$remote</span>&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">&quot;File [<span style="color: #006699; font-weight: bold;">$remote</span>] successfully deleted&quot;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">// Disconnect</span>
<a href="http://www.php.net/ftp_close" onclick="pageTracker._trackPageview('/outgoing/www.php.net/ftp_close?referer=');"><span style="color: #990000;">ftp_close</span></a><span style="color: #009900;">&#40;</span><span style="color: #000088;">$conn</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

]]></content:encoded>
			<wfw:commentRss>http://www.maggsweb.com/uncategorized/how-to-download-and-upload-files-over-ftp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Wee Me&#8217;s</title>
		<link>http://www.maggsweb.com/uncategorized/wee-mes/</link>
		<comments>http://www.maggsweb.com/uncategorized/wee-mes/#comments</comments>
		<pubDate>Sun, 18 Oct 2009 10:46:33 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://www.maggsweb.com/?p=41</guid>
		<description><![CDATA[]]></description>
			<content:encoded><![CDATA[<p><img src="http://www.maggsweb.com/wp-content/uploads/2009/10/WeeMe-Chris.jpg" alt="WeeMe - Chris" title="WeeMe - Chris" width="189" height="240" class="alignnone size-full wp-image-54" /><img src="http://www.maggsweb.com/wp-content/uploads/2009/10/WeeMe-Carolyn.jpg" alt="WeeMe - Carolyn" title="WeeMe - Carolyn" width="189" height="240" class="alignnone size-full wp-image-37" /><img src="http://www.maggsweb.com/wp-content/uploads/2009/10/WeeMe-Emily1.jpg" alt="WeeMe - Emily" title="WeeMe - Emily" width="189" height="240" class="alignnone size-full wp-image-42" /></p>
]]></content:encoded>
			<wfw:commentRss>http://www.maggsweb.com/uncategorized/wee-mes/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
