<?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>Incero</title>
	<atom:link href="http://www.incero.com/feed" rel="self" type="application/rss+xml" />
	<link>http://www.incero.com</link>
	<description>Dedicated Server</description>
	<lastBuildDate>Fri, 03 Feb 2012 06:48:03 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Installing The Adaptec Hardware RAID Monitoring Utility (arcconf) on CentOS</title>
		<link>http://www.incero.com/sysadmin/installing-the-adaptec-hardware-raid-monitoring-utility-arcconf-on-centos</link>
		<comments>http://www.incero.com/sysadmin/installing-the-adaptec-hardware-raid-monitoring-utility-arcconf-on-centos#comments</comments>
		<pubDate>Sun, 26 Jun 2011 22:52:13 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[System Admin]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=1426</guid>
		<description><![CDATA[You can use arcconf to check the status of your Adaptec hardware RAID array. Below are the commands to download and install the program into a directory called /incero, and then the command to run the program. Tested with CentOS 5.5 64bit and CentOS 5.6 64bit. mkdir /incero cd /incero wget http://download.adaptec.com/raid/storage_manager/asm_linux_x64_v6_50_18579.tgz tar -zxf asm_linux_x64_v6_50_18579.tgz [...]]]></description>
			<content:encoded><![CDATA[<p>You can use arcconf to check the status of your Adaptec hardware RAID array. Below are the commands to download and install the program into a directory called /incero, and then the command to run the program. Tested with CentOS 5.5 64bit and CentOS 5.6 64bit.</p>
<p><code>mkdir /incero<br />
cd /incero<br />
wget http://download.adaptec.com/raid/storage_manager/asm_linux_x64_v6_50_18579.tgz<br />
tar -zxf asm_linux_x64_v6_50_18579.tgz<br />
rm -f asm_linux_x64_v6_50_18579.tgz<br />
cd cmdline/<br />
chmod +x arcconf<br />
yum -y install compat-libstdc++-33<br />
./arcconf getconfig 1 AL </code></p>
<p>If you wish for your server to email you if an array becomes sub optimal you can use a script like the one posted by &#8220;quad3datwork&#8221; here: <a href="http://www.sysadmintalk.net/forums/Thread-CentOS-Adaptec-RAID-2405-arcconf-monitoring" target="_blank">http://www.sysadmintalk.net/forums/Thread-CentOS-Adaptec-RAID-2405-arcconf-monitoring</a></p>
<p>Incero clients with our management services need not worry about RAID health, as it is constantly monitored 24/7 along with load and other server health parameters by our staff.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/sysadmin/installing-the-adaptec-hardware-raid-monitoring-utility-arcconf-on-centos/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>PHP MySQL Table Update Function</title>
		<link>http://www.incero.com/webdev/php-mysql-table-update-function</link>
		<comments>http://www.incero.com/webdev/php-mysql-table-update-function#comments</comments>
		<pubDate>Sun, 01 May 2011 13:03:20 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=1301</guid>
		<description><![CDATA[Typing out the full PHP/MySQL for each UPDATE query within a very dynamic PHP application quickly becomes a tedious task. Since starting out with PHP ten years ago I&#8217;ve written my own functions to make such tedious tasks easier, I keep them all in a functions.php file which I include in all my projects. It [...]]]></description>
			<content:encoded><![CDATA[<p>Typing out the full PHP/MySQL for each UPDATE query within a very dynamic PHP application quickly becomes a tedious task. Since starting out with PHP ten years ago I&#8217;ve written my own functions to make such tedious tasks easier, I keep them all in a functions.php file which I include in all my projects. It takes a while to create and remember the syntax for such functions, but once you do you will save a lot of time. The same concept as using a framework, but without the bulk.</p>
<p>Below is a function I wrote for running UPDATE queries which:</p>
<ul>
<li>automatically escapes data</li>
<li>allows MySQL functions to pass through with the use of *function* e.g. *NOW()*</li>
<li>allows you to update columns with empty string/null values</li>
<li>allows a single or an unlimited number of columns to be updated</li>
<li>saves you from typing out long UPDATE queries</li>
<li>assumes that you have a column called id, presumably a primary key</li>
</ul>
<p>Parameters are split with ::: and the first parameter is the table name, then the id of the row to update, then the column, and then the value. Add on as many columns and values as desired.</p>
<pre class="brush: php;">ut(&quot;jobs:::1:::status:::walking the dog:::server:::fileserver2&quot;);</pre>
<p>replaces</p>
<pre class="brush: php;">$query=&quot;UPDATE jobs SET status=&quot; . mysql_real_escape_string('walking the dog') .&quot;, server=&quot; . mysql_real_escape_string('fileserver2') . &quot; WHERE id=&quot; . mysql_real_escape_string('1');
$result=mysql_query($query);</pre>
<p>Below is the function and <a title="Screenshot of function code" href="http://www.incero.com/wp-content/uploads/2011/05/update-function-code1.png" target="_blank">here is a more readable screenshot</a> of the code.</p>
<pre class="brush: php;">
function ut($data)//update table function
 {
 /*  Update mysql table, save time. MySQL real escape data. Pass unlimited number of columns/values. Allow MySQL function passthrough with *function*, e.g. *NOW()*
 to update a column with a blank value simply skip the data. e.g. jobs:::123:::status:::  would set status to empty string for row 123
 table:::row id:::column:::value:::column:::value:::column:::value

 examples, don't forget that values have been through mysql_real_escaped_string(), so the equivalent query typed/sanitized manually would be much longer than shown below.
 jobs:::1:::status:::walking the dog:::server:::fileserver2
 UPDATE jobs SET status='walking the dog', server='fileserver2' WHERE id='1'

 jobs:::1:::status::::::server:::fileserver3422
 UPDATE jobs SET status='', server='fileserver342' WHERE id='1'

 jobs:::1:::status:::starting the job:::addedtime:::*NOW()*
 UPDATE jobs SET status='starting the job', addedtime=NOW() WHERE id='1'

 Questions/improvements welcome at http://www.incero.com/?p=1301
 */
 $data=explode(&quot;:::&quot;,$data);
 $table=addslashes(strip_tags($data[0]));//we know the column ID will always be an int, wont need to escape this data
 $id=intval($data[1]);//we know the column ID will always be an int, wont need to escape this data
 connect();//our own mysql connect function, omit this if you always keep mysql open (for the whole page load)
 $x=2;
 while($x&lt;sizeof($data))//Loop through the data array for all the update queries.
 {
 $column=strip_tags($data[$x]);
 $value=$data[$x+1];
 if($x==2){
 $queryString= mysql_real_escape_string($column);
 }
 else//this isn't the first data/column set so we need a comma
 {
 $queryString.= &quot;, &quot; . mysql_real_escape_string($column);
 }
 if(substr($value,0,1)==&quot;*&quot; &amp;&amp; substr($value,strlen($value)-1,1)==&quot;*&quot;)
 {
 $queryString.= &quot;=&quot; . substr($value,1,strlen($value)-2);//if the value is surrouned by * then omit single quotes, allowing mysql functions to pass through, e.g. *NOW()*
 }
 else
 {
 $queryString.= &quot;='&quot; .mysql_real_escape_string($value) . &quot;'&quot;;
 }
 $x=$x+2;
 }
 $sQuery = &quot;UPDATE $table SET $queryString WHERE id='$id'&quot;;
 //echo &quot;&lt;br&gt;the query was $sQuery&lt;br&quot;;
 $sQueryresult = mysql_query($sQuery);
 @mysql_close();//omit this if you always keep mysql open (for the whole page load)
 return $sQueryresult;
 }
</pre>
<p style="text-align: center;"><a href="../wp-content/uploads/2011/05/update-function-code2.png"><img class="aligncenter" title="Click to view larger screenshot" src="../wp-content/uploads/2011/05/update-function-code2-1024x613.png" alt="Click to view larger screenshot" width="655" height="392" /></a><a href="http://www.incero.com/wp-content/uploads/2011/05/update-function-code1.png"><br />
</a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/webdev/php-mysql-table-update-function/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Avoiding Downtime For Apache Config Changes</title>
		<link>http://www.incero.com/sysadmin/avoiding-downtime-for-apache-config-changes</link>
		<comments>http://www.incero.com/sysadmin/avoiding-downtime-for-apache-config-changes#comments</comments>
		<pubDate>Tue, 26 Oct 2010 19:41:18 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[System Admin]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[httpd]]></category>
		<category><![CDATA[reload]]></category>
		<category><![CDATA[restart]]></category>
		<category><![CDATA[web server]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=841</guid>
		<description><![CDATA[I come across people &#8220;restarting&#8221; Apache after adding a new virtual host, or making other changes to httpd.conf all the time. Restarting apache will cause all current connections to close, Apache to stop (causing your site to be down), and then Apache starts back up. The amount of downtime is minimal, but it is not [...]]]></description>
			<content:encoded><![CDATA[<p>I come across people &#8220;restarting&#8221; Apache after adding a new virtual host, or making other changes to httpd.conf all the time. Restarting apache will cause all current connections to close, Apache to stop (causing your site to be down), and then Apache starts back up. The amount of downtime is minimal, but it is not necessary.</p>
<p>The correct method of reloading httpd.conf would be to use &#8220;reload&#8221;, reload does not stop Apache from running, so no visitors are turned away, it simply reloads the configuration files and reparses any perl .pm files.</p>
<p>Usage: service httpd reload</p>
<p>Example:<br />
[scoobydoo@server11 public_html]# service httpd reload<br />
Reloading httpd:                                           [  OK  ]</p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/sysadmin/avoiding-downtime-for-apache-config-changes/feed</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>How To Install PERL For CSF Firewall</title>
		<link>http://www.incero.com/sysadmin/how-to-install-perl-for-csf-firewall</link>
		<comments>http://www.incero.com/sysadmin/how-to-install-perl-for-csf-firewall#comments</comments>
		<pubDate>Sun, 26 Sep 2010 22:33:19 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[System Admin]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=737</guid>
		<description><![CDATA[When installing CSF firewall, which is a great alternative to APF firewall, you may be presented with an error regarding PERL: [root@server27 csf]# sh install.sh Configuring for OS Checking for perl modulesfailed You need to install the LWP perl module (libwww-perl) and then install csf To correct this on a CentOS system, simply run the [...]]]></description>
			<content:encoded><![CDATA[<p>When <a href="http://www.configserver.com/free/csf/install.txt" target="_blank">installing CSF firewall</a>, which is a great alternative to APF firewall, you may be presented with an error regarding PERL:</p>
<pre class="brush: plain;">[root@server27 csf]# sh install.sh
Configuring for OS
Checking for perl modulesfailed
You need to install the LWP perl module (libwww-perl) and then install csf</pre>
<p>To correct this on a CentOS system, simply run the following command to install Perl:</p>
<pre class="brush: plain;">yum install perl-libwww-perl</pre>
<p>It will prompt you with the packages it will install, if all looks good then choose &#8220;Y&#8221; for yes.</p>
<pre class="brush: plain;">[root@server27 csf]# yum install perl-libwww-perl
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * addons: mirror.raystedman.net
 * base: centos.omnispring.com
 * extras: centos.mirror.netriplex.com
 * rpmforge: fr2.rpmfind.net
 * updates: centos.aol.com
Setting up Install Process
Resolving Dependencies
--&gt; Running transaction check
---&gt; Package perl-libwww-perl.noarch 0:5.805-1.1.1 set to be updated
--&gt; Processing Dependency: perl-HTML-Parser &gt;= 3.33 for package: perl-libwww-perl
--&gt; Processing Dependency: perl(URI::URL) for package: perl-libwww-perl
--&gt; Processing Dependency: perl(URI) for package: perl-libwww-perl
--&gt; Processing Dependency: perl(HTML::Entities) for package: perl-libwww-perl
--&gt; Processing Dependency: perl(Compress::Zlib) for package: perl-libwww-perl
--&gt; Processing Dependency: perl(URI::Heuristic) for package: perl-libwww-perl
--&gt; Processing Dependency: perl(URI::Escape) for package: perl-libwww-perl
--&gt; Running transaction check
---&gt; Package perl-HTML-Parser.x86_64 0:3.68-1.el5.rf set to be updated
--&gt; Processing Dependency: perl(HTML::Tagset) &gt;= 3 for package: perl-HTML-Parser
---&gt; Package perl-IO-Compress.noarch 0:2.024-1.el5.rf set to be updated
--&gt; Processing Dependency: perl(Compress::Raw::Bzip2) = 2.024 for package: perl-IO-Compress
--&gt; Processing Dependency: perl(Compress::Raw::Zlib) = 2.024 for package: perl-IO-Compress
---&gt; Package perl-URI.noarch 0:1.35-3 set to be updated
--&gt; Running transaction check
---&gt; Package perl-Compress-Raw-Bzip2.x86_64 0:2.024-1.el5.rf set to be updated
---&gt; Package perl-Compress-Raw-Zlib.x86_64 0:2.024-1.el5.rf set to be updated
---&gt; Package perl-HTML-Tagset.noarch 0:3.20-1.el5.rf set to be updated
--&gt; Finished Dependency Resolution

Dependencies Resolved

===============================================================================================================================================================================================================
 Package                                                     Arch                                       Version                                             Repository                                    Size
===============================================================================================================================================================================================================
Installing:
 perl-libwww-perl                                            noarch                                     5.805-1.1.1                                         base                                         376 k
Installing for dependencies:
 perl-Compress-Raw-Bzip2                                     x86_64                                     2.024-1.el5.rf                                      rpmforge                                     110 k
 perl-Compress-Raw-Zlib                                      x86_64                                     2.024-1.el5.rf                                      rpmforge                                     178 k
 perl-HTML-Parser                                            x86_64                                     3.68-1.el5.rf                                       rpmforge                                     151 k
 perl-HTML-Tagset                                            noarch                                     3.20-1.el5.rf                                       rpmforge                                      14 k
 perl-IO-Compress                                            noarch                                     2.024-1.el5.rf                                      rpmforge                                     242 k
 perl-URI                                                    noarch                                     1.35-3                                              base                                         116 k

Transaction Summary
===============================================================================================================================================================================================================
Install       7 Package(s)
Upgrade       0 Package(s)

Total download size: 1.2 M
Is this ok [y/N]:
</pre>
<p>Once you choose &#8220;Y&#8221; your packages will download and install:</p>
<pre class="brush: plain;">
Is this ok [y/N]: y
Downloading Packages:
(1/7): perl-HTML-Tagset-3.20-1.el5.rf.noarch.rpm                                                                                                                                        |  14 kB     00:00
(2/7): perl-Compress-Raw-Bzip2-2.024-1.el5.rf.x86_64.rpm                                                                                                                                | 110 kB     00:00
(3/7): perl-URI-1.35-3.noarch.rpm                                                                                                                                                       | 116 kB     00:00
(4/7): perl-HTML-Parser-3.68-1.el5.rf.x86_64.rpm                                                                                                                                        | 151 kB     00:00
(5/7): perl-Compress-Raw-Zlib-2.024-1.el5.rf.x86_64.rpm                                                                                                                                 | 178 kB     00:00
(6/7): perl-IO-Compress-2.024-1.el5.rf.noarch.rpm                                                                                                                                       | 242 kB     00:00
(7/7): perl-libwww-perl-5.805-1.1.1.noarch.rpm                                                                                                                                          | 376 kB     00:00
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                                                                          343 kB/s | 1.2 MB     00:03
Running rpm_check_debug
Running Transaction Test
Finished Transaction Test
Transaction Test Succeeded
Running Transaction
 Installing     : perl-Compress-Raw-Zlib                                                                                                                                                                  1/7
 Installing     : perl-Compress-Raw-Bzip2                                                                                                                                                                 2/7
 Installing     : perl-IO-Compress                                                                                                                                                                        3/7
 Installing     : perl-HTML-Tagset                                                                                                                                                                        4/7
 Installing     : perl-HTML-Parser                                                                                                                                                                        5/7
 Installing     : perl-URI                                                                                                                                                                                6/7
 Installing     : perl-libwww-perl                                                                                                                                                                        7/7

Installed:
 perl-libwww-perl.noarch 0:5.805-1.1.1

Dependency Installed:
 perl-Compress-Raw-Bzip2.x86_64 0:2.024-1.el5.rf        perl-Compress-Raw-Zlib.x86_64 0:2.024-1.el5.rf        perl-HTML-Parser.x86_64 0:3.68-1.el5.rf        perl-HTML-Tagset.noarch 0:3.20-1.el5.rf
 perl-IO-Compress.noarch 0:2.024-1.el5.rf               perl-URI.noarch 0:1.35-3

Complete!
</pre>
<p>Now you can install CSF firewall, or anything else requiring PERL:</p>
<pre class="brush: plain;">
[root@server27 csf]# ./install.sh

Configuring for OS

Checking for perl modulesok
Running csf generic installer
Installing generic csf and lfd
Check we're running as root

mkdir: created directory `/etc/csf'
mkdir: created directory `/etc/csf/zone'
mkdir: created directory `/etc/csf/stats'
`csf.generic.conf' -&gt; `/etc/csf/csf.conf'
`csf.allow' -&gt; `/etc/csf/./csf.allow'
`csf.deny' -&gt; `/etc/csf/./csf.deny'
`csf.dirwatch' -&gt; `/etc/csf/./csf.dirwatch'
`csf.ignore' -&gt; `/etc/csf/./csf.ignore'
`csf.generic.pignore' -&gt; `/etc/csf/csf.pignore'
`csf.rignore' -&gt; `/etc/csf/./csf.rignore'
`csf.fignore' -&gt; `/etc/csf/./csf.fignore'
`csf.signore' -&gt; `/etc/csf/./csf.signore'
`csf.suignore' -&gt; `/etc/csf/./csf.suignore'
`csf.mignore' -&gt; `/etc/csf/./csf.mignore'
`csf.sips' -&gt; `/etc/csf/./csf.sips'
`csf.dyndns' -&gt; `/etc/csf/./csf.dyndns'
`alert.txt' -&gt; `/etc/csf/./alert.txt'
`logfloodalert.txt' -&gt; `/etc/csf/./logfloodalert.txt'
`integrityalert.txt' -&gt; `/etc/csf/./integrityalert.txt'
`exploitalert.txt' -&gt; `/etc/csf/./exploitalert.txt'
`tracking.txt' -&gt; `/etc/csf/./tracking.txt'
`connectiontracking.txt' -&gt; `/etc/csf/./connectiontracking.txt'
`processtracking.txt' -&gt; `/etc/csf/./processtracking.txt'
`accounttracking.txt' -&gt; `/etc/csf/./accounttracking.txt'
`usertracking.txt' -&gt; `/etc/csf/./usertracking.txt'
`sshalert.txt' -&gt; `/etc/csf/./sshalert.txt'
`sualert.txt' -&gt; `/etc/csf/./sualert.txt'
`scriptalert.txt' -&gt; `/etc/csf/./scriptalert.txt'
`filealert.txt' -&gt; `/etc/csf/./filealert.txt'
`watchalert.txt' -&gt; `/etc/csf/./watchalert.txt'
`loadalert.txt' -&gt; `/etc/csf/./loadalert.txt'
`resalert.txt' -&gt; `/etc/csf/./resalert.txt'
`portscan.txt' -&gt; `/etc/csf/./portscan.txt'
`permblock.txt' -&gt; `/etc/csf/./permblock.txt'
`netblock.txt' -&gt; `/etc/csf/./netblock.txt'
`messenger' -&gt; `/etc/csf/./messenger'
`messenger/index.text' -&gt; `/etc/csf/./messenger/index.text'
`messenger/index.html' -&gt; `/etc/csf/./messenger/index.html'
`messenger/csf_small.png' -&gt; `/etc/csf/./messenger/csf_small.png'
`portknocking.txt' -&gt; `/etc/csf/./portknocking.txt'
`regex.custom.pm' -&gt; `/etc/csf/./regex.custom.pm'
`lfd.logrotate' -&gt; `/etc/logrotate.d/lfd'
`csfcron.sh' -&gt; `/etc/cron.d/csfcron.sh'
`lfdcron.sh' -&gt; `/etc/cron.d/lfdcron.sh'
`csf.pl' -&gt; `/etc/csf/csf.pl'
`csfui.pl' -&gt; `/etc/csf/csfui.pl'
`csftest.pl' -&gt; `/etc/csf/csftest.pl'
`lfd.pl' -&gt; `/etc/csf/lfd.pl'
`regex.pm' -&gt; `/etc/csf/regex.pm'
`servercheck.pm' -&gt; `/etc/csf/servercheck.pm'
`readme.txt' -&gt; `/etc/csf/readme.txt'
`sanity.txt' -&gt; `/etc/csf/sanity.txt'
`x-arf.txt' -&gt; `/etc/csf/x-arf.txt'
`changelog.txt' -&gt; `/etc/csf/changelog.txt'
`install.txt' -&gt; `/etc/csf/install.txt'
`version.txt' -&gt; `/etc/csf/version.txt'
`license.txt' -&gt; `/etc/csf/license.txt'
`uninstall.generic.sh' -&gt; `/etc/csf/uninstall.sh'
`remove_apf_bfd.sh' -&gt; `/etc/csf/remove_apf_bfd.sh'
`lfd.sh' -&gt; `/etc/init.d/lfd'
`csf.sh' -&gt; `/etc/init.d/csf'
`Net' -&gt; `/etc/csf/Net'
`Net/CIDR' -&gt; `/etc/csf/Net/CIDR'
`Net/CIDR/Lite.pm' -&gt; `/etc/csf/Net/CIDR/Lite.pm'
`Sys' -&gt; `/etc/csf/Sys'
`Sys/Hostname' -&gt; `/etc/csf/Sys/Hostname'
`Sys/Hostname/Long.pm' -&gt; `/etc/csf/Sys/Hostname/Long.pm'
`File' -&gt; `/etc/csf/File'
`File/Type' -&gt; `/etc/csf/File/Type'
`File/Type/Builder.pm' -&gt; `/etc/csf/File/Type/Builder.pm'
`File/Type.pm' -&gt; `/etc/csf/File/Type.pm'
`IP' -&gt; `/etc/csf/IP'
`IP/Authority' -&gt; `/etc/csf/IP/Authority'
`IP/Authority/auth.gif' -&gt; `/etc/csf/IP/Authority/auth.gif'
`IP/Authority/._auth.gif' -&gt; `/etc/csf/IP/Authority/._auth.gif'
`IP/Authority/ipauth.gif' -&gt; `/etc/csf/IP/Authority/ipauth.gif'
`IP/Authority/._ipauth.gif' -&gt; `/etc/csf/IP/Authority/._ipauth.gif'
`IP/._Authority.pm' -&gt; `/etc/csf/IP/._Authority.pm'
`IP/Country' -&gt; `/etc/csf/IP/Country'
`IP/Country/._Medium.pm' -&gt; `/etc/csf/IP/Country/._Medium.pm'
`IP/Country/._MaxMind.pm' -&gt; `/etc/csf/IP/Country/._MaxMind.pm'
`IP/Country/MaxMind.pm' -&gt; `/etc/csf/IP/Country/MaxMind.pm'
`IP/Country/Fast' -&gt; `/etc/csf/IP/Country/Fast'
`IP/Country/Fast/cc.gif' -&gt; `/etc/csf/IP/Country/Fast/cc.gif'
`IP/Country/Fast/._ip.gif' -&gt; `/etc/csf/IP/Country/Fast/._ip.gif'
`IP/Country/Fast/._cc.gif' -&gt; `/etc/csf/IP/Country/Fast/._cc.gif'
`IP/Country/Fast/ip.gif' -&gt; `/etc/csf/IP/Country/Fast/ip.gif'
`IP/Country/Medium.pm' -&gt; `/etc/csf/IP/Country/Medium.pm'
`IP/Country/._Slow.pm' -&gt; `/etc/csf/IP/Country/._Slow.pm'
`IP/Country/Slow.pm' -&gt; `/etc/csf/IP/Country/Slow.pm'
`IP/Country/._Fast.pm' -&gt; `/etc/csf/IP/Country/._Fast.pm'
`IP/Country/Fast.pm' -&gt; `/etc/csf/IP/Country/Fast.pm'
`IP/Country.pm' -&gt; `/etc/csf/IP/Country.pm'
`IP/Authority.pm' -&gt; `/etc/csf/IP/Authority.pm'
`Geography' -&gt; `/etc/csf/Geography'
`Geography/Countries.pm' -&gt; `/etc/csf/Geography/Countries.pm'
`Crypt' -&gt; `/etc/csf/Crypt'
`Crypt/CBC.pm' -&gt; `/etc/csf/Crypt/CBC.pm'
`Crypt/Blowfish_PP.pm' -&gt; `/etc/csf/Crypt/Blowfish_PP.pm'
chmod: cannot access `/var/log/lfd.log*': No such file or directory
mode of `/etc/csf/uninstall.sh' changed to 0700 (rwx------)
mode of `/etc/csf/csf.pl' changed to 0700 (rwx------)
mode of `/etc/csf/csfui.pl' changed to 0700 (rwx------)
mode of `/etc/csf/csftest.pl' changed to 0700 (rwx------)
mode of `/etc/csf/servercheck.pm' changed to 0700 (rwx------)
mode of `/etc/csf/lfd.pl' changed to 0700 (rwx------)
mode of `/etc/init.d/lfd' changed to 0700 (rwx------)
mode of `/etc/init.d/csf' changed to 0700 (rwx------)
mode of `/etc/cron.d/lfdcron.sh' changed to 0644 (rw-r--r--)
mode of `/etc/cron.d/csfcron.sh' changed to 0644 (rw-r--r--)
create symbolic link `/usr/sbin/csf' to `/etc/csf/csf.pl'
create symbolic link `/usr/sbin/lfd' to `/etc/csf/lfd.pl'

TCP ports currently listening for incoming connections:
22,80,111,957,3306

UDP ports currently listening for incoming connections:
111,631,951,954,5353,42114,50599

Note: The port details above are for information only, csf hasn't been auto-configured.

Don't forget to:
1. Configure the TCP_IN, TCP_OUT, UDP_IN and UDP_OUT options in the csf configuration to suite your server
2. Restart csf and lfd
3. Set TESTING to 0 once you're happy with the firewall

Adding current SSH session IP address to the csf whitelist in csf.allow:
Adding 91.77.128.14 to csf.allow only while in TESTING mode (not iptables ACCEPT)
*WARNING* TESTING mode is enabled - do not forget to disable it in the configuration

Installation Completed
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/sysadmin/how-to-install-perl-for-csf-firewall/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Supermicro IPMI2 + KVM Server Control</title>
		<link>http://www.incero.com/sysadmin/supermicro-ipmi2-kvm-server-control</link>
		<comments>http://www.incero.com/sysadmin/supermicro-ipmi2-kvm-server-control#comments</comments>
		<pubDate>Sat, 28 Aug 2010 10:08:32 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Hardware]]></category>
		<category><![CDATA[System Admin]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=653</guid>
		<description><![CDATA[With &#8220;mission critical&#8221; in mind all of our servers include the latest IPMI2 and KVM integrated into the motherboard. The web based control panel for the IPMI and KVM, which works even when the server is offline, allows complete remote control over the system. My favorite feature is the KVM for remote console access along [...]]]></description>
			<content:encoded><![CDATA[<p>With &#8220;mission critical&#8221; in mind all of our <a href="/servers">servers</a> include the latest IPMI2 and KVM integrated into the motherboard.</p>
<p>The web based control panel for the IPMI and KVM, which works even when the server is offline, allows complete remote control over the system. My favorite feature is the KVM for remote console access along with the ability to mount remotely hosted iso images as a local cdrom. The combination of these features allow you to completely reload an operating system remotely, and complete countless other tasks which previously have required physical access.</p>
<p>Click on each image to see the larger version:</p>
<p><a href="http://www.UploadScreenshot.com/image/114620/2914135" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903400623.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114622/4510572" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903411188.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114623/429933" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903412258.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114625/9140476" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903413557.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114626/4285231" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903415361.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114627/2261334" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903420087.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114628/9137416" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903421686.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114629/3594900" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903423447.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114630/7555154" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903425354.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114631/218270" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903430091.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114632/3482058" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903434799.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114634/9613838" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903441931.png" alt="Click here to view full size" /></a></p>
<p><a href="http://www.UploadScreenshot.com/image/114637/3370157" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/23903504886.png" alt="Click here to view full size" /></a></p>
<p>The final screenshot, shown below, shows the IPMIVIEW desktop software, which can be used instead of the browser based control panel if desired.</p>
<p><a href="http://www.UploadScreenshot.com/image/115267/3090803" target="_blank"><img src="http://img1.UploadScreenshot.com/images/thumb/8/24003502347.jpg" alt="Click here to view full size" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/sysadmin/supermicro-ipmi2-kvm-server-control/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Number Of Available CPU Cores In PHP</title>
		<link>http://www.incero.com/webdev/number-of-available-processing-cores-in-php</link>
		<comments>http://www.incero.com/webdev/number-of-available-processing-cores-in-php#comments</comments>
		<pubDate>Thu, 01 Jul 2010 04:26:22 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Web Development]]></category>
		<category><![CDATA[cores]]></category>
		<category><![CDATA[cpu]]></category>
		<category><![CDATA[cpus]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[processor]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=539</guid>
		<description><![CDATA[It is simple enough to check and then load the number of available processing cores on the current machine into a PHP variable. You can do so with the code below, which uses shell commands to grab data from /proc/cpuinfo and then removes unneeded data with PHP. &#60;?php /*How to check how many processors are [...]]]></description>
			<content:encoded><![CDATA[<p>It is simple enough to check and then load the number of available processing cores on the current machine into a PHP variable. You can do so with the code below, which uses shell commands to grab data from /proc/cpuinfo and then removes unneeded data with PHP.</p>
<pre class="brush: php;">&lt;?php
 /*How to check how many processors are available on the current machine.
 by gordon@incero.com http://www.Incero.com. Feel free to use this code,
 but keep this header. June 30th, 2010.*/
 $numberOfProcessors=`cat /proc/cpuinfo | grep processor | tail -1`;
 $numberOfProcessors=preg_replace('/\s+/', '',$numberOfProcessors);
 $numberOfProcessors=str_replace(&quot;:&quot;,&quot;&quot;, $numberOfProcessors);
 $numberOfProcessors=str_replace(&quot;processor&quot;,&quot;&quot;, $numberOfProcessors);
 $numberOfProcessors++;
 echo &quot;Number of processors on this machine is $numberOfProcessors!&quot;;
?&gt;</pre>
<p>We use this code to help our programs assign the most efficient parameters to others processes, such as FFMpeg video conversions, that we spawn from PHP across various machines.</p>
<p>Tested on CentOS 5.4, should work on most Linux distributions.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/webdev/number-of-available-processing-cores-in-php/feed</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Zend 2003120701 Error</title>
		<link>http://www.incero.com/webdev/zend-2003120701-error</link>
		<comments>http://www.incero.com/webdev/zend-2003120701-error#comments</comments>
		<pubDate>Mon, 14 Jun 2010 22:22:37 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=531</guid>
		<description><![CDATA[If you see an error on your website like the one below, it means that you need to install Zend Encoder to load the file. Zend�2003120701�1�2570�9363�xù Ÿ2Í[ÍoÜÆŸÚêH9(§^R€ÑEdY$g8œ‰½N¶ÒZÚÖ’ìõ:Ž$‹µ´–ÖÖ~˜Ëu¬¢h.íÑ@/Fs)KÓc½ô”? 7&#124;)£ƒÂ·…›\ú†‡ä– ®ï®ùÞ&#60;¾ù½ï!-’ÿ'½ážÕŠBXÑŸxk “YîqÌ\ŠEmÀÞt08:ßÝÛ €ÙëÃî ÷öŠC!œs?nÆAo¿3è†»sŽía‡Ù¶hW)šLoOÂ`ÎaÜõ=ß&#38;Å6êÍ:sî9Ì‹&#124;op4¹Ø‰:dîrÆ=øp£\Ó†ÓA'}1™s&#60;×§ÇBÜ Æ#¸È‰O˜í2uñ’¸ØÎ2l3îøÖî´{8šDÛ Ì¥&#62;¡4 „f\ìÄ�çÑ™80“¯·\ærØµ›�æ¢»gô  ¡NçróJ£Ó™´''JÀ±‘Ï9P)åTÄÔ5 $BõÕÝÑðNÿüø`ßýçÒ5ÓQ‹¦ªý»¨½c$aÁè›—Ñ£g/Ö£¿µwÝDûdýán²Œ~W¾ˆþl:ð$ÄÖGVrÛhû2[½syºÕ¸Üh5Z1ëµ&#124;Cç¦b~H„ñÐ;2ƒÏçrôíÑèÞ Ü;Í}ß&#38;€G›Â_&#124;úèZÂâ^ú±²æh{aèŠn&#62;Û»D´w•8‰Ø‰6Y&#60;É:� ??ûÁûa8~uuéƒ³Ÿ~¾úÙòÒ‡}Ý¸ò›ù‚’øüL¥3bþSÄg3YÓSG‚Œiì¹RyŸrê‰“'™`~-·›ØCÍ¨qRz&#38;Eèå8VD§ª¹WÛ… ?ÉÒ‰¾A¿›µd’êÒM¦ßÏHÔ¶ÈM¼Ça®mÑ�ƒ9c)N5N%N’…®gƒ/¿Í¸*/´³^(ˆ?”ÆƒpéV™òñôv¿\2Fÿ8•Y;¯Í =ÎãJ&#60;ý=7Ür}jc­míÝþÐºÜÚÙ²ÚA†Ú››±äõÚâ&#124;¦[½­Î t}ã£Aÿ&#38;§¨Žt7*Ù\&#38;Ôã\5ÈôšëW S/)t O5¡ša=•/¤€Œžž£L.Ïw5º=„Mg¬iÿm…í&#60;ô¸¤J G¡0Æ$b£èëVUÑC÷Íe•Ä¥èòNëf½µÞX—Ü¿7•(Q:sÚs3js®‘¿Ìi–èóO¥›Ù\¤ÎGÍºdû±J‘¹jE¾&#62;‘&#34;}£&#34;\â®ÿf!™ Råjkçã[0§noCh6w¶ß,@J­Íj½1´ˆŽVýF{s§Õü¤þÿ�˜-KƒMüz xýY%5ªåxîê:ýñíªq½eîW½Xó°¤Sßhl·%û¸¼!êO²£ý®žÖå»BO ZB¦Ç¹»Ì8¶ÎßT–¤…¾¦¿´Ò;¶›«ô0ö«ÕPÿßvù§1U­OaÎk5¶vÚN}}½%YÓŠïçªÿS,Ö®MIïå£l±&#38;,)ÖÑ¡sTª›ã­îX–êþøN0\¬5·íN½½³}vQÞZÊsMU[„Ñâ’Uß^áè’¾\®ËUû¬Pc+ º`z¥¹Õl[Žä¬h €ZÑ�õ¤M°–7@456Äj 0«j €úMp››u«&#124;S0ã`OÓä¯J[?maà—’Ëêþ±PËì³ÆÁèáQ-ú\–ÜOóÎA5QFG`ÏYáýŽä)x×˜½‹ Zº~£jý#ã^A‰Ãî$\jk7Z-èÖ:íæVãz»¾u57¿›qÑÃ 4•%™:v2¹?Óœ®èþLf/çÅîÏÐ{¦2ái5špôÛÂ3ré4ëÝ£Èe‚þp^½Ä&#34;V&#60;*³pJ–8úz38~d„©ñ´JÄÓ2ÒõÇUëKì³,éy/ÒC¢�?‰ˆWÇ€¢š.á [...]]]></description>
			<content:encoded><![CDATA[<p>If you see an error on your website like the one below, it means that you need to install Zend Encoder to load the file.</p>
<pre class="brush: plain;">Zend�2003120701�1�2570�9363�xù Ÿ2Í[ÍoÜÆŸÚêH9(§^R€ÑEdY$g8œ‰½N¶ÒZÚÖ’ìõ:Ž$‹µ´–ÖÖ~˜Ëu¬¢h.íÑ@/Fs)KÓc½ô”? 7|)£ƒÂ·…›\ú†‡ä– ®ï®ùÞ&lt;¾ù½ï!-’ÿ'½ážÕŠBXÑŸxk “YîqÌ\ŠEmÀÞt08:ßÝÛ €ÙëÃî ÷öŠC!œs?nÆAo¿3è†»sŽía‡Ù¶hW)šLoOÂ`ÎaÜõ=ß&amp;Å6êÍ:sî9Ì‹|op4¹Ø‰:dîrÆ=øp£\Ó†ÓA'}1™s&lt;×§ÇBÜ Æ#¸È‰O˜í2uñ’¸ØÎ2l3îøÖî´{8šDÛ Ì¥&gt;¡4 „f\ìÄ�çÑ™80“¯·\ærØµ›�æ¢»gô  ¡NçróJ£Ó™´''JÀ±‘Ï9P)åTÄÔ5 $BõÕÝÑðNÿüø`ßýçÒ5ÓQ‹¦ªý»¨½c$aÁè›—Ñ£g/Ö£¿µwÝDûdýán²Œ~W¾ˆþl:ð$ÄÖGVrÛhû2[½syºÕ¸Üh5Z1ëµ|Cç¦b~H„ñÐ;2ƒÏçrôíÑèÞ Ü;Í}ß&amp;€G›Â_|úèZÂâ^ú±²æh{aèŠn&gt;Û»D´w•8‰Ø‰6Y&lt;É:� ??ûÁûa8~uuéƒ³Ÿ~¾úÙòÒ‡}Ý¸ò›ù‚’øüL¥3bþSÄg3YÓSG‚Œiì¹RyŸrê‰“'™`~-·›ØCÍ¨qRz&amp;Eèå8VD§ª¹WÛ… ?ÉÒ‰¾A¿›µd’êÒM¦ßÏHÔ¶ÈM¼Ça®mÑ�ƒ9c)N5N%N’…®gƒ/¿Í¸*/´³^(ˆ?”ÆƒpéV™òñôv¿\2Fÿ8•Y;¯Í =ÎãJ&lt;ý=7Ür}jc­míÝþÐºÜÚÙ²ÚA†Ú››±äõÚâ|¦[½­Î t}ã£Aÿ&amp;§¨Žt7*Ù\&amp;Ôã\5ÈôšëW S/)t O5¡ša=•/¤€Œžž£L.Ïw5º=„Mg¬iÿm…í&lt;ô¸¤J G¡0Æ$b£èëVUÑC÷Íe•Ä¥èòNëf½µÞX—Ü¿7•(Q:sÚs3js®‘¿Ìi–èóO¥›Ù\¤ÎGÍºdû±J‘¹jE¾&gt;‘&quot;}£&quot;\â®ÿf!™ Råjkçã[0§noCh6w¶ß,@J­Íj½1´ˆŽVýF{s§Õü¤þÿ�˜-KƒMüz xýY%5ªåxîê:ýñíªq½eîW½Xó°¤Sßhl·%û¸¼!êO²£ý®žÖå»BO ZB¦Ç¹»Ì8¶ÎßT–¤…¾¦¿´Ò;¶›«ô0ö«ÕPÿßvù§1U­OaÎk5¶vÚN}}½%YÓŠïçªÿS,Ö®MIïå£l±&amp;,)ÖÑ¡sTª›ã­îX–êþøN0\¬5·íN½½³}vQÞZÊsMU[„Ñâ’Uß^áè’¾\®ËUû¬Pc+ º`z¥¹Õl[Žä¬h €ZÑ�õ¤M°–7@456Äj 0«j €úMp››u«|S0ã`OÓä¯J[?maà—’Ëêþ±PËì³ÆÁèáQ-ú\–ÜOóÎA5QFG`ÏYáýŽä)x×˜½‹ Zº~£jý#ã^A‰Ãî$\jk7Z-èÖ:íæVãz»¾u57¿›qÑÃ 4•%™:v2¹?Óœ®èþLf/çÅîÏÐ{¦2ái5špôÛÂ3ré4ëÝ£Èe‚þp^½Ä&quot;V&lt;*³pJ–8úz38~d„©ñ´JÄÓ2ÒõÇUëKì³,éy/ÒC¢�?‰ˆWÇ€¢š.á H·p\‰¼4D$–@ G‡Uš…c¥’Ã­’ýò»ïf,;¦0åUÕªÜ ’ÅUUŠWV).«Ô Â”›j½kSê«nÂ³µž æ6LUm«¹ÝÞ‰ ½ˆÕÒ2J ƒÚ¼fïz“š“ät¹¤Ü‡ŠÄt\9—±pn”Ú�ˆæ`­ÎÉþSòÂ‰iBÌáÄ„ƒÑ4¨™!Ð\«èÙ¬mkýÆÕ+Í5‘Õ¸eÉƒ}.;RÊ÷å.Ôçå.Ôg't`ý™ÚBî!ž¨úùÃí7s€\t7ŸræðTÎ»›Ë3îÖêÝé½ .½;bFP,6# :,jŽ–ñ\§E¢Ù¼¸ègX“ñè5˜«˜7™«²n2/F7Oj^œ{¸0ãbŠ.Nvƒþ8´Äûrµ…°÷0\½Û}Ð¯.@÷2ÜŸv÷ôK¸z=¾ziöA7°zÇý ×R¬š5ì}¥=ì]º0«QÎOzatY¿¶/¯-YË–C`ÁÞhw:è Ãó»£Ñ½¾·°vØß½7©Ùä}&amp;µàÖ¥„£­öõºƒýHÒÂkÜ j«FÍõšf}ÀÎ|.â3ôÚn¹Ù?]”wû®Ô©[2ýb´øYMrV-7VFñªß«íäâjlýKRüÅ¼sª¨§ž6í°4ê=ìSÅch…œÝi€M7!Ì¹¶oÁq‰xkavönÏ9Ì§˜ÛÞš‰ý9Sêx¾ Ñ%Eå‹}Î©xÔEýñ¬xÕÆaœÄOswÓC’9‡º&gt;và/ÚÊ³”9fHŒ™|?'žª`6å®Ëà)ø¶ž</pre>
<p>If you are running cPanel/WHM on your server you can easily install Zend Encoder from the &#8220;Easy Apache&#8221; menu. Below are some screenshots detailing the process in WHM, simply use your existing Apache/PHP settings and then check the Zend Encoder checkbox on the options list near the end of the process.</p>
<p><a href='http://www.UploadScreenshot.com/image/78462/7981177' target='_blank'><img src='http://img1.UploadScreenshot.com/images/thumb/6/16418180119.png' alt='Click here to view full size' /></a></p>
<p><a href='http://www.UploadScreenshot.com/image/78463/9888798' target='_blank'><img src='http://img1.UploadScreenshot.com/images/thumb/6/16418181947.png' alt='Click here to view full size' /></a></p>
<p><a href='http://www.UploadScreenshot.com/image/78464/6328208' target='_blank'><img src='http://img1.UploadScreenshot.com/images/thumb/6/16418183169.png' alt='Click here to view full size' /></a></p>
<p><a href='http://www.UploadScreenshot.com/image/78465/9427448' target='_blank'><img src='http://img1.UploadScreenshot.com/images/thumb/6/16418184271.png' alt='Click here to view full size' /></a></p>
<p><a href='http://www.UploadScreenshot.com/image/78466/4931295' target='_blank'><img src='http://img1.UploadScreenshot.com/images/thumb/6/16418190282.png' alt='Click here to view full size' /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/webdev/zend-2003120701-error/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP Upload Progress Bar Script</title>
		<link>http://www.incero.com/webdev/php-upload-progress-bar-script</link>
		<comments>http://www.incero.com/webdev/php-upload-progress-bar-script#comments</comments>
		<pubDate>Mon, 07 Jun 2010 19:00:18 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=479</guid>
		<description><![CDATA[We have developed an amazing PHP upload progress bar script, which uses Javascript and PHP to report back the upload status data to the user. This script makes it extremely easy to add an upload progress bar to your website without using Flash, Perl, cgi, or other complex solutions. Demo You can see the upload [...]]]></description>
			<content:encoded><![CDATA[<p>We have developed an amazing PHP upload progress bar script, which uses Javascript and PHP to report back the upload status data to the user. This script makes it extremely easy to add an upload progress bar to your website without using Flash, Perl, cgi, or other complex solutions.</p>
<p style="text-align: center;"><img class="size-full wp-image-517 aligncenter" style="border: 1px solid black;" title="progress" src="http://www.incero.com/wp-content/uploads/2010/06/progress.png" alt="" width="216" height="61" /></p>
<p><strong>Demo</strong></p>
<p>You can see the upload progress bar in action <a href="http://dev.incero.com/gordons/upload-test/" target="_blank">here</a>. You can also see a video of it in action at the bottom of this page.</p>
<p><strong>Features</strong></p>
<ul>
<li>Uses simple HTML form, allowing you to post additional data such as a description of the file, user-name, etc</li>
<li>100% PHP and Javascript</li>
<li>Customizable progress update interval, have it update as often as you like, specify the interval in milliseconds</li>
<li>CSS based upload progress bar, change colors and size easily</li>
</ul>
<p><strong>Customizable &amp; Well Documented</strong></p>
<p>All of the code is easily customizable by any novice web programmer. All of the PHP code is very well commented in clear and easy to understand English. If there are any features that you want to add you can easily edit the source code to meet your needs.</p>
<p><strong>Help Available, If You Need It!<br />
</strong></p>
<p>We answer emails to <a href="mailto:info@incero.com">info@incero.com</a> within 1 business day, but usually within a couple of hours. We can also be reached on (512) 394.8803.  We can install the script for you, integrate it into your website, or perform nearly any other programming task for you for a reasonable fee. We are a real web development company located in downtown Austin, TX and are always happy to assist our clients!</p>
<p><strong>Buy Now</strong></p>
<p>We are a PayPal verified business, once you have completed the payment we will email you a copy of the script. Please feel free to <a href="/contact-us">contact us</a> if you have any troubles, we are here to help!</p>
<table border="0" cellspacing="0" cellpadding="5" width="100%">
<tbody>
<tr>
<td align="center" width="200"><strong>Single Domain, $69</strong></td>
<td align="center"><strong>Personal Domains, $119</strong></td>
<td align="center"><strong>Developer, $249</strong></td>
</tr>
<tr>
<td>Use the code on only one domain.</td>
<td>Use the code on an unlimited number of domains that you personally own. May not be used by web developers or businesses.</td>
<td>For developers and business users. Use the code on any number of your own and your client&#8217;s domains.</td>
</tr>
<tr>
<td align="center"><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&amp;hosted_button_id=SS9CZ7C36C2AC"></a></p>
<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input name="cmd" type="hidden" value="_s-xclick" />
<input name="hosted_button_id" type="hidden" value="SS9CZ7C36C2AC" />
<input alt="PayPal - The safer, easier way to pay online!" name="submit" src="https://www.paypal.com/en_US/i/btn/btn_buynowCC_LG.gif" type="image" width="147" height="47"/> </form>
</td>
<td align="center">
<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input name="cmd" type="hidden" value="_s-xclick" />
<input name="hosted_button_id" type="hidden" value="V3L2HSQ334CGU" />
<input alt="PayPal - The safer, easier way to pay online!" name="submit" src="https://www.paypal.com/en_US/i/btn/btn_buynowCC_LG.gif" type="image" width="147" height="47" /> </form>
</td>
<td align="center"><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&amp;hosted_button_id=UDTTWSNPH2KGS"></a></p>
<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input name="cmd" type="hidden" value="_s-xclick" />
<input name="hosted_button_id" type="hidden" value="UDTTWSNPH2KGS" />
<input alt="PayPal - The safer, easier way to pay online!" name="submit" src="https://www.paypal.com/en_US/i/btn/btn_buynowCC_LG.gif" type="image" width="147" height="47" /> </form>
</td>
</tr>
</tbody>
</table>
<p><object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="500" height="320" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0"><param name="allowFullScreen" value="true" /><param name="allowscriptaccess" value="always" /><param name="src" value="http://www.youtube.com/v/jwx-DJlZz1o&amp;hl=en_US&amp;fs=1&amp;rel=0" /><param name="allowfullscreen" value="true" /><embed type="application/x-shockwave-flash" width="500" height="320" src="http://www.youtube.com/v/jwx-DJlZz1o&amp;hl=en_US&amp;fs=1&amp;rel=0" allowscriptaccess="always" allowfullscreen="true"></embed></object></p>
<p>Sever Requirements</p>
<ul>
<li>PHP 5.2 or newer</li>
<li>PHP PECL <a href="http://pecl.php.net/package/uploadprogress/" target="_blank">UploadProgress</a> (very easy to install)</li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/webdev/php-upload-progress-bar-script/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Securing Joomla Media Files With Login Sessions</title>
		<link>http://www.incero.com/webdev/securing-joomla-media-files-with-login-sessions</link>
		<comments>http://www.incero.com/webdev/securing-joomla-media-files-with-login-sessions#comments</comments>
		<pubDate>Tue, 11 May 2010 21:08:30 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Web Development]]></category>
		<category><![CDATA[file]]></category>
		<category><![CDATA[joomla]]></category>
		<category><![CDATA[leech]]></category>
		<category><![CDATA[protection]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=402</guid>
		<description><![CDATA[We recently completed an excellent Joomla file protection script which allows Joomla CMS webmasters to secure their digital files based on the current user login session preventing leeching. Using our Joomla file protection script you can simply drop our securefile.php in any folder that contains files that you want to protect and they will only [...]]]></description>
			<content:encoded><![CDATA[<p>We recently completed an excellent Joomla file protection script which allows Joomla CMS webmasters to secure their digital files based on the current user login session preventing leeching.</p>
<p>Using our Joomla file protection script you can simply drop our securefile.php in any folder that contains files that you want to protect and they will only be loadable by registered and logged in users.</p>
<p>Here&#8217;s how it works:</p>
<ol>
<li>All file requests for media files including videos and images are automatically passed to securefile.php</li>
<li>securefile.php checks that the user is already logged by checking the Joomla session and cookie data</li>
<li>displays the requested file, or shows an error message if permission is denied.</li>
</ol>
<p>An example usage would be that you have a several .swf presentations that you want to show to your registered users only, they view your webpage source code and then steal the link to the .swf (such as http://www.mywebsite.com/files/presentation4.swf). The user then shares that direct link to your presentation with non registered users resulting in bandwidth usage and lost revenue. With the leech protection system those direct links will not work for non registered users.</p>
<p>This beauty of this system is that you can keep using your existing video players and presentations on your site as you always have without having to modify your code. We can set this up for you, <a href="/contact-us" target="_self">contact us</a> for more information.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/webdev/securing-joomla-media-files-with-login-sessions/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Generate Thumbnails On The Fly With PHP</title>
		<link>http://www.incero.com/webdev/how-to-generate-thumbnails-on-the-fly-with-php</link>
		<comments>http://www.incero.com/webdev/how-to-generate-thumbnails-on-the-fly-with-php#comments</comments>
		<pubDate>Fri, 30 Apr 2010 21:25:03 +0000</pubDate>
		<dc:creator>Gordon</dc:creator>
				<category><![CDATA[Web Development]]></category>
		<category><![CDATA[automatic]]></category>
		<category><![CDATA[exif]]></category>
		<category><![CDATA[gd]]></category>
		<category><![CDATA[how to]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[thumbnail]]></category>

		<guid isPermaLink="false">http://www.incero.com/?p=420</guid>
		<description><![CDATA[There are two great ways to generate thumbnails for images on the fly with PHP: Use GD to resize the image on the fly and output it Extracts the thumbnail from the Exif data. (If this fails, you could revert to method 1 above.) The latter assumes that the image file has exif data, which [...]]]></description>
			<content:encoded><![CDATA[<p>There are two great ways to generate thumbnails for images on the fly with PHP:</p>
<ol>
<li> Use GD to resize the image on the fly and output it</li>
<li>Extracts the thumbnail from the <a href="http://en.wikipedia.org/wiki/Exchangeable_image_file_format" target="_blank">Exif data</a>. (If this fails, you could revert to method 1 above.)</li>
</ol>
<p>The latter assumes that the image file has exif data, which most photos  do. To ensure the fastest loading thumbnails it would be best to generate thumbnails when images are uploaded to the server, but there are times when you don&#8217;t want to have to store thumbnails for every image uploaded.</p>
<p><strong>Method 1: Using GD To Resize On The Fly</strong></p>
<p>Using this <a href="http://www.incero.com/codesamples/thumbnailonthefly/highres.jpg" target="_blank">8.5MB image</a>, and the code below, the following URL will load a thumbnail that is dynamically created: <a href="http://www.incero.com/codesamples/thumbnailonthefly/thumbnail.php?image=highres.jpg&amp;width=160" target="_blank">http://www.incero.com/codesamples/thumbnailonthefly/thumbnail.php?image=highres.jpg&amp;width=160</a></p>
<pre class="brush: php;">&lt;?php
 /*How to extract a thumbnail from Exif data using PHP
 Created by Gordon Page, gordon@incero.com. April 30th, 2010.
 Incero.com offers custom coding and hosting solutions.
 */
 header(&quot;Content-type: image/jpeg&quot;);

 // get image size
 $file = $_GET[image];
 if($size = GetImageSize($file)){
 $w = $size[0];
 $h = $size[1];
 //set new size
 $nw = $_GET['width'];
 $nh = ($nw*$h)/$w;
 }
 else{
 //set new size
 $nw = &quot;160&quot;;
 $nh = &quot;120&quot;;
 }
 //draw the image
 $src_img = imagecreatefromjpeg($file);
 $dst_img = imagecreatetruecolor($nw,$nh);
 imagecopyresampled($dst_img, $src_img, 0, 0, 0, 0, $nw, $nh, $w, $h);//resizing the image
 imagejpeg($dst_img,&quot;&quot;,100);
 imagedestroy($src_img);
 imagedestroy($dst_img);
?&gt;</pre>
<p>You&#8217;ll notice that with this method it takes about a second to generate the thumbnail so you may want to default to the method below which is faster, and if that method fails then fall back to this first method.</p>
<p><strong>Method 2: Extracting The Thumbnail From The Exif Data<br />
</strong></p>
<p>Using the same <a href="http://www.incero.com/codesamples/thumbnailonthefly/highres.jpg" target="_blank">8.5MB  image</a>, and the code below, the following URL will extract the thumbnail from the Exif data: <a href="http://www.incero.com/codesamples/thumbnailonthefly/exifthumb.php?image=highres.jpg" target="_blank">http://www.incero.com/codesamples/thumbnailonthefly/exifthumb.php?image=highres.jpg</a><a href="http://www.incero.com/codesamples/thumbnailonthefly/thumbnail.php?image=highres.jpg&amp;width=160" target="_blank"></a></p>
<pre class="brush: php;">

&lt;?php
 /*How to extract a thumbnail from Exif data using PHP
 Created by Gordon Page, gordon@incero.com. April 30th, 2010.
 Incero.com offers custom coding and hosting solutions.
 */
 // file to read
 $file =$_REQUEST['image'];
 $image = exif_thumbnail($file, $width, $height, $type);
 // width, height and type get filled with data
 // after calling &quot;exif_thumbnail&quot;
 if ($image) {
 // send header and image data to the browser:
 header('Content-type: ' .image_type_to_mime_type($type));
 print $image;
 }
 else {
 // there is no thumbnail available, handle the error.
 //This would be a great place to revert to the GD resize method.
 print 'No thumbnail available';
 }
?&gt;
</pre>
<p>Feel free to use the code above in your own projects. If you are in need of paid programming services please <a href="/contact-us">contact us</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.incero.com/webdev/how-to-generate-thumbnails-on-the-fly-with-php/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>

