<?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>Information Technology Issues &#187; PHP</title>
	<atom:link href="http://www.semenit.com/category/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.semenit.com</link>
	<description>This is all about Information Technology</description>
	<lastBuildDate>Fri, 13 Jan 2012 07:50:28 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.4</generator>
		<item>
		<title>Sourcecop Decrypt</title>
		<link>http://www.semenit.com/2012/01/13/sourcecop-decrypt/</link>
		<comments>http://www.semenit.com/2012/01/13/sourcecop-decrypt/#comments</comments>
		<pubDate>Fri, 13 Jan 2012 07:50:28 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[decrypt]]></category>
		<category><![CDATA[encrypt]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=158</guid>
		<description><![CDATA[Need to decrypt php files that encrypted by Sourcecop? Maybe this link will help you. http://sourcecop.decoder-online.com/]]></description>
			<content:encoded><![CDATA[<p>Need to decrypt php files that encrypted by Sourcecop? Maybe this link will help you.<br />
<a href="http://sourcecop.decoder-online.com/">http://sourcecop.decoder-online.com/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2012/01/13/sourcecop-decrypt/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Download File Function</title>
		<link>http://www.semenit.com/2011/04/08/download-file-function/</link>
		<comments>http://www.semenit.com/2011/04/08/download-file-function/#comments</comments>
		<pubDate>Fri, 08 Apr 2011 10:12:38 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=122</guid>
		<description><![CDATA[Here is the function for Download many file: &#60;?php function downloadFile( $fullPath ){ // Must be fresh start if( headers_sent() ) die(&#8216;Headers Sent&#8217;); // Required for some browsers if(ini_get(&#8216;zlib.output_compression&#8217;)) ini_set(&#8216;zlib.output_compression&#8217;, &#8217;Off&#8217;); // File Exists? if( file_exists($fullPath) ){ // Parse Info / Get Extension $fsize = filesize($fullPath); $path_parts = pathinfo($fullPath); $ext = strtolower($path_parts["extension"]); // Determine Content Type switch ($ext) { case &#8221;pdf&#8221;: $ctype=&#8221;application/pdf&#8221;; break; case &#8221;exe&#8221;: $ctype=&#8221;application/octet-stream&#8221;; break; case &#8221;zip&#8221;: $ctype=&#8221;application/zip&#8221;; break; case &#8221;doc&#8221;: $ctype=&#8221;application/msword&#8221;; break; [...]]]></description>
			<content:encoded><![CDATA[<p>Here is the function for Download many file:</p>
<blockquote><p>&lt;?php<br />
function downloadFile( $fullPath ){</p>
<p>// Must be fresh start<br />
if( headers_sent() )<br />
die(&#8216;Headers Sent&#8217;);</p>
<p>// Required for some browsers<br />
if(ini_get(&#8216;zlib.output_compression&#8217;))<br />
ini_set(&#8216;zlib.output_compression&#8217;, &#8217;Off&#8217;);</p>
<p>// File Exists?<br />
if( file_exists($fullPath) ){</p>
<p>// Parse Info / Get Extension<br />
$fsize = filesize($fullPath);<br />
$path_parts = pathinfo($fullPath);<br />
$ext = strtolower($path_parts["extension"]);</p>
<p>// Determine Content Type<br />
switch ($ext) {<br />
case &#8221;pdf&#8221;: $ctype=&#8221;application/pdf&#8221;; break;<br />
case &#8221;exe&#8221;: $ctype=&#8221;application/octet-stream&#8221;; break;<br />
case &#8221;zip&#8221;: $ctype=&#8221;application/zip&#8221;; break;<br />
case &#8221;doc&#8221;: $ctype=&#8221;application/msword&#8221;; break;<br />
case &#8221;xls&#8221;: $ctype=&#8221;application/vnd.ms-excel&#8221;; break;<br />
case &#8221;ppt&#8221;: $ctype=&#8221;application/vnd.ms-powerpoint&#8221;; break;<br />
case &#8221;gif&#8221;: $ctype=&#8221;image/gif&#8221;; break;<br />
case &#8221;png&#8221;: $ctype=&#8221;image/png&#8221;; break;<br />
case &#8221;jpeg&#8221;:<br />
case &#8221;jpg&#8221;: $ctype=&#8221;image/jpg&#8221;; break;<br />
default: $ctype=&#8221;application/force-download&#8221;;<br />
}</p>
<p>header(&#8220;Pragma: public&#8221;); // required<br />
header(&#8220;Expires: 0&#8243;);<br />
header(&#8220;Cache-Control: must-revalidate, post-check=0, pre-check=0&#8243;);<br />
header(&#8220;Cache-Control: private&#8221;,false); // required for certain browsers<br />
header(&#8220;Content-Type: $ctype&#8221;);<br />
header(&#8220;Content-Disposition: attachment; filename=\&#8221;".basename($fullPath).&#8221;\&#8221;;&#8221; );<br />
header(&#8220;Content-Transfer-Encoding: binary&#8221;);<br />
header(&#8220;Content-Length: &#8220;.$fsize);<br />
ob_clean();<br />
flush();<br />
readfile( $fullPath );</p>
<p>} else<br />
die(&#8216;File Not Found&#8217;);</p>
<p>}<br />
?&gt;</p></blockquote>
<p>Source <a href="http://php.net/manual/en/function.header.php">http://php.net/manual/en/function.header.php</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2011/04/08/download-file-function/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to hidden error message in PHP</title>
		<link>http://www.semenit.com/2011/03/03/how-to-hidden-error-message-in-php/</link>
		<comments>http://www.semenit.com/2011/03/03/how-to-hidden-error-message-in-php/#comments</comments>
		<pubDate>Thu, 03 Mar 2011 10:28:59 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=119</guid>
		<description><![CDATA[Hidden error message in PHP, so your visitor will not know your php file. &#60;? @ini_set(&#8216;display_errors&#8217;, 0); ?&#62;]]></description>
			<content:encoded><![CDATA[<p>Hidden error message in PHP, so your visitor will not know your php file.</p>
<blockquote><p>&lt;? @ini_set(&#8216;display_errors&#8217;, 0); ?&gt;</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2011/03/03/how-to-hidden-error-message-in-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>how to delete file or not exist file</title>
		<link>http://www.semenit.com/2011/03/03/how-to-delete-file-or-not-exist-file/</link>
		<comments>http://www.semenit.com/2011/03/03/how-to-delete-file-or-not-exist-file/#comments</comments>
		<pubDate>Thu, 03 Mar 2011 10:26:47 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=117</guid>
		<description><![CDATA[The syntax how to check the file exist or not and delete the file if exist. $targetupload=$_SERVER['DOCUMENT_ROOT'].&#8221;/semenit/&#8221;;  //server location or directory $deletefile=&#8221;namafile.jpg&#8221;; if (file_exists($targetupload.&#8221;images/&#8221;.$deletefile)) { unlink($targetupload.&#8221;images/&#8221;.$deletefile); }]]></description>
			<content:encoded><![CDATA[<p>The syntax how to check the file exist or not and delete the file if exist.</p>
<blockquote>
<div id="_mcePaste">$targetupload=$_SERVER['DOCUMENT_ROOT'].&#8221;/semenit/&#8221;;  //server location or directory</div>
<div id="_mcePaste">$deletefile=&#8221;namafile.jpg&#8221;;</div>
<div id="_mcePaste">if (file_exists($targetupload.&#8221;images/&#8221;.$deletefile)) { unlink($targetupload.&#8221;images/&#8221;.$deletefile); }</div>
</blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2011/03/03/how-to-delete-file-or-not-exist-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Problem install Magento</title>
		<link>http://www.semenit.com/2010/11/12/problem-install-magento/</link>
		<comments>http://www.semenit.com/2010/11/12/problem-install-magento/#comments</comments>
		<pubDate>Fri, 12 Nov 2010 06:18:32 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Magento]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=112</guid>
		<description><![CDATA[Problem install magento in windows? error: PHP Extension &#8220;pdo_mysql&#8221; must be loaded PHP Extension &#8220;mcrypt&#8221; must be loaded Solution: Uncomment in php.ini (c:/windows) extension=php_mcrypt.dll and extension=php_pdo_mysql.dll Should be works. But if you still have problem in &#8220;mcrypt&#8221;, just downloads &#8220;libmcrypt.dll&#8221; file to c:\windows or you can download here. That will works fine.]]></description>
			<content:encoded><![CDATA[<p>Problem install magento in windows?<br />
error:<br />
PHP Extension &#8220;pdo_mysql&#8221; must be loaded<br />
PHP Extension &#8220;mcrypt&#8221; must be loaded</p>
<p>Solution:<br />
Uncomment in php.ini (c:/windows) extension=php_mcrypt.dll and extension=php_pdo_mysql.dll<br />
Should be works.</p>
<p>But if you still have problem in &#8220;mcrypt&#8221;, just downloads &#8220;libmcrypt.dll&#8221; file to c:\windows<br />
or you can download <a href="http://www.semenit.com/wp-content/uploads/2010/11/libmcrypt.dll_.zip">here</a>.</p>
<p>That will works fine.<!--6c5bdf30d9ba4846ae89762d832b0a18--></p>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2010/11/12/problem-install-magento/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>JQuery Validation</title>
		<link>http://www.semenit.com/2010/08/16/jquery-validation/</link>
		<comments>http://www.semenit.com/2010/08/16/jquery-validation/#comments</comments>
		<pubDate>Mon, 16 Aug 2010 09:10:37 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[JQuery]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=94</guid>
		<description><![CDATA[Email, Verify Email and Password, Confirm Password Validation using JQuery &#60;script src=&#8221;http://code.jquery.com/jquery-latest.js&#8221;&#62;&#60;/script&#62; &#60;script type=&#8221;text/javascript&#8221; src=&#8221;http://dev.jquery.com/view/trunk/plugins/validate/jquery.validate.js&#8221;&#62;&#60;/script&#62; &#60;style type=&#8221;text/css&#8221;&#62; label.error { float: left; color: red; margin-left: 400px; vertical-align: top; margin-top:-20px; } p { clear: both; } .submit { margin-left: 12em; } em { font-weight: bold; padding-right: 1em; vertical-align: top; } .inf { font-family: verdana, sans-serif; color: #999; [...]]]></description>
			<content:encoded><![CDATA[<p>Email, Verify Email and Password, Confirm Password Validation using JQuery</p>
<blockquote>
<div id="_mcePaste">&lt;script src=&#8221;http://code.jquery.com/jquery-latest.js&#8221;&gt;&lt;/script&gt;</div>
<div id="_mcePaste">&lt;script type=&#8221;text/javascript&#8221; src=&#8221;http://dev.jquery.com/view/trunk/plugins/validate/jquery.validate.js&#8221;&gt;&lt;/script&gt;</div>
<div id="_mcePaste">&lt;style type=&#8221;text/css&#8221;&gt;</div>
<div id="_mcePaste">label.error { float: left; color: red; margin-left: 400px; vertical-align: top; margin-top:-20px; }</div>
<div id="_mcePaste">p { clear: both; }</div>
<div id="_mcePaste">.submit { margin-left: 12em; }</div>
<div id="_mcePaste">em { font-weight: bold; padding-right: 1em; vertical-align: top; }</div>
<div id="_mcePaste">.inf { font-family: verdana, sans-serif; color: #999; background: #333; border: 1px solid #505050; padding: .2em; font-size: 1em }</div>
<div id="_mcePaste">&lt;/style&gt;</div>
<div id="_mcePaste">&lt;script type=&#8221;text/javascript&#8221;&gt;</div>
<div id="_mcePaste">SubmittingForm=function() {</div>
<div id="_mcePaste">//alert(&#8220;The form has been validated.&#8221;);</div>
<div id="_mcePaste">&lt;? if (ofanvalid==&#8221;true&#8221;) { ?&gt;</div>
<div id="_mcePaste">//alert(&#8220;valid&#8221;);</div>
<div id="_mcePaste">&lt;? } else { ?&gt;</div>
<div id="_mcePaste">//alert(&#8220;notvalid&#8221;);</div>
<div id="_mcePaste">&lt;? } ?&gt;</div>
<div id="_mcePaste">oshippingform.submit();</div>
<div id="_mcePaste">}</div>
<div id="_mcePaste">$(document).ready(function() {</div>
<div id="_mcePaste">$(&#8220;#oshippingform&#8221;).validate({</div>
<div id="_mcePaste">submitHandler:function(form) {</div>
<div id="_mcePaste">SubmittingForm();</div>
<div id="_mcePaste">},</div>
<div id="_mcePaste">rules: {</div>
<div id="_mcePaste">first_name: &#8220;required&#8221;,		// simple rule, converted to {required:true}</div>
<div id="_mcePaste">email_address: {				// compound rule</div>
<div id="_mcePaste">required: true,</div>
<div id="_mcePaste">email: true</div>
<div id="_mcePaste">},</div>
<div id="_mcePaste">email_confirm: {</div>
<div id="_mcePaste">required: true,</div>
<div id="_mcePaste">equalTo: &#8220;#email_address&#8221;</div>
<div id="_mcePaste">},</div>
<div id="_mcePaste">password: {				// compound rule</div>
<div id="_mcePaste">required: true,</div>
<div id="_mcePaste">},</div>
<div id="_mcePaste">confirmpassword: {</div>
<div id="_mcePaste">required: true,</div>
<div id="_mcePaste">equalTo: &#8220;#password&#8221;</div>
<div id="_mcePaste">},</div>
<div id="_mcePaste">url: {</div>
<div id="_mcePaste">url: true</div>
<div id="_mcePaste">},</div>
<div id="_mcePaste">comment: {</div>
<div id="_mcePaste">required: true</div>
<div id="_mcePaste">}</div>
<div id="_mcePaste">},</div>
<div id="_mcePaste">messages: {</div>
<div id="_mcePaste">comment: &#8220;Please enter a comment.&#8221;</div>
<div id="_mcePaste">}</div>
<div id="_mcePaste">});</div>
<div id="_mcePaste">});</div>
<div id="_mcePaste">&lt;/script&gt;</div>
</blockquote>
<p>In Input type:</p>
<blockquote><p>&lt;INPUT type=&#8221;text&#8221; name=&#8221;email_address&#8221; id=&#8221;email_address&#8221; class=&#8221;required inf&#8221; maxlength=&#8221;40&#8243; value=&#8221;"&gt;</p></blockquote>
<p>That&#8217;s an example. You can modify it.</p>
<p>Source: <a href="http://docs.jquery.com/Plugins/Validation">http://docs.jquery.com/Plugins/Validation</a> and <a href="http://docs.jquery.com/Plugins/Validation/validate">http://docs.jquery.com/Plugins/Validation/validate</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2010/08/16/jquery-validation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Get 1 paragraph only</title>
		<link>http://www.semenit.com/2010/08/12/get-1-paragraph-only/</link>
		<comments>http://www.semenit.com/2010/08/12/get-1-paragraph-only/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 09:27:19 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=87</guid>
		<description><![CDATA[Here is php script to get first paragraph in description; $pos=strpos($description,&#8221;&#60;/p&#62;&#8221;); $pos=$pos+4; echo substr($description,0,$pos); +4 because &#60;/p&#62; is 4 chars]]></description>
			<content:encoded><![CDATA[<p>Here is php script to get first paragraph in description;</p>
<blockquote>
<div id="_mcePaste">$pos=strpos($description,&#8221;&lt;/p&gt;&#8221;);</div>
<div id="_mcePaste">$pos=$pos+4;</div>
<div id="_mcePaste">echo substr($description,0,$pos);</div>
</blockquote>
<p>+4 because &lt;/p&gt; is 4 chars</p>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2010/08/12/get-1-paragraph-only/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Select distinct month or year</title>
		<link>http://www.semenit.com/2010/08/12/select-distinct-month-or-year/</link>
		<comments>http://www.semenit.com/2010/08/12/select-distinct-month-or-year/#comments</comments>
		<pubDate>Thu, 12 Aug 2010 09:20:42 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=85</guid>
		<description><![CDATA[Here is MySQL syntax for select distinct month or year SELECT distinct month(daterelease) as bulan FROM releases WHERE year(daterelease)=&#8217;$tahun&#8217; AND sportsid=&#8217;$sportsid&#8217; ORDER BY daterelease DESC while ($releasemonthline = mysql_fetch_array($releasemonth)) { $bulan=$releasemonthline["bulan"]; // get from &#8220;as bulan&#8221; } Here is complete reference: http://dev.mysql.com/doc/refman/5.1/en/date-and-time-functions.html]]></description>
			<content:encoded><![CDATA[<p>Here is MySQL syntax for select distinct month or year</p>
<blockquote><p>SELECT distinct month(daterelease) as bulan FROM releases WHERE year(daterelease)=&#8217;$tahun&#8217; AND sportsid=&#8217;$sportsid&#8217; ORDER BY daterelease DESC</p></blockquote>
<div id="_mcePaste">while ($releasemonthline = mysql_fetch_array($releasemonth)) {<br />
$bulan=$releasemonthline["bulan"]; // get from &#8220;as bulan&#8221;</div>
<div>}</div>
<div></div>
<div>Here is complete reference: http://dev.mysql.com/doc/refman/5.1/en/date-and-time-functions.html</div>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2010/08/12/select-distinct-month-or-year/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>User IP Address and Facebook</title>
		<link>http://www.semenit.com/2010/06/29/user-ip-address-and-facebook/</link>
		<comments>http://www.semenit.com/2010/06/29/user-ip-address-and-facebook/#comments</comments>
		<pubDate>Tue, 29 Jun 2010 02:17:46 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Facebook]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=81</guid>
		<description><![CDATA[How to get (using PHP) User IP Address : $_SERVER['REMOTE_ADDR']; User IP Address Facebook : $_SERVER['HTTP_X_FB_USER_REMOTE_ADDR'];]]></description>
			<content:encoded><![CDATA[<p>How to get (using PHP)</p>
<blockquote><p>User IP Address : $_SERVER['REMOTE_ADDR'];</p>
<p>User IP Address Facebook : $_SERVER['HTTP_X_FB_USER_REMOTE_ADDR'];</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2010/06/29/user-ip-address-and-facebook/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Changing text with innerHTML</title>
		<link>http://www.semenit.com/2010/06/04/changing-text-with-innerhtml/</link>
		<comments>http://www.semenit.com/2010/06/04/changing-text-with-innerhtml/#comments</comments>
		<pubDate>Fri, 04 Jun 2010 08:04:53 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.semenit.com/?p=72</guid>
		<description><![CDATA[Changing text with innerHTML, &#60;script type="text/javascript"&#62; function changeText(){ document.getElementById('boldStuff').innerHTML = 'Semenit'; } &#60;/script&#62; &#60;p&#62;Welcome to the &#60;b id='boldStuff'&#62;unknown&#60;/b&#62; site&#60;/p&#62; &#60;input type='button' onclick='changeText()' value='Change Text'/&#62;]]></description>
			<content:encoded><![CDATA[<p>Changing text with innerHTML,</p>
<blockquote>
<pre>&lt;script type="text/javascript"&gt;
function changeText(){
	<span style="color: red;">document.getElementById('boldStuff').innerHTML = 'Semenit';</span>
}
&lt;/script&gt;
&lt;p&gt;Welcome to the &lt;b id='boldStuff'&gt;unknown&lt;/b&gt; site&lt;/p&gt;
&lt;input type='button' onclick='changeText()' value='Change Text'/&gt;</pre>
</blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.semenit.com/2010/06/04/changing-text-with-innerhtml/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

