<?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>Sherif&#039;s Tech Blog</title>
	<atom:link href="http://sheriframadan.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://sheriframadan.com</link>
	<description>Tech Babble BS and a Few Wise Words</description>
	<lastBuildDate>Sat, 04 Sep 2010 15:58:57 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>How to Build Web Forums Using PHP and MySQL</title>
		<link>http://sheriframadan.com/2010/08/how-to-build-web-forums-using-php-and-mysql/</link>
		<comments>http://sheriframadan.com/2010/08/how-to-build-web-forums-using-php-and-mysql/#comments</comments>
		<pubDate>Tue, 24 Aug 2010 18:35:45 +0000</pubDate>
		<dc:creator>GoogleGuy</dc:creator>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[forum]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://sheriframadan.com/?p=63</guid>
		<description><![CDATA[If you have been online long enough and use the web frequently you most likely have run into web forums by now. They have been around for a very long time. Usenet Groups are possibly the closest resemblance to web forums and they have been around long before the world wide web. Web forums, sometimes [...]]]></description>
			<content:encoded><![CDATA[<p>If you have been online long enough and use the web frequently you most likely have run into web forums by now. They have been around for a very long time. Usenet Groups are possibly the closest resemblance to web forums and they have been around long before the world wide web. Web forums, sometimes also referred to as <em>Bulletin Boards</em> (BBs), are an essential tool of online web-based communication amongst online communities, both small and large.</p>
<p>The general idea is based on the concept of a centralized server that stores and displays messages from various users. If you&#8217;ve ever wondered how they work or how you could build your very own web forum from scratch this tutorial attempts to explain some of the fundamental underlying concepts. You will need a MySQL database to be able to store the messages &#8211; or whatever DBMS you prefer &#8211; along with a Server-Side-Scripting language such as PHP in order to process and handle requests from the various users of the forum.</p>
<p>Forums are actually rather simple in design. They work on a somewhat hierarchical system. The messages on forums are normally threaded, meaning they fit into neat little categories and span inwards. The messages are called posts. Every time a user submits a post to the forum it must be associated with some specific thread. The thread is a type of category that belongs to the forum. Most web forums will have multiple forums on the same web site, usually closely related in subject.</p>
<p>So in order to build our forum we will first need to design a database. For the purpose of demonstration in this tutorial we will use MySQL. We&#8217;ll call our MySQL database <em>_forum</em> and use the MyISAM engine, as this provides a very fast means of sending and retrieving multiple queries at once. The MyISAM storage engine is not a transactional storage engine. It provides table-level locking, which means it can slow down significantly if too many people are attempting to write to the database at once. However, for the purpose of an online web forum this should more than suffice. Given that the majority of forum users are reading rather than contributing to the forum and that the expected impact should not exceed a few hundred concurrent connections for even a large forum (this could potentially support hundreds of thousands of users).</p>
<p>The database will require four basic tables to become a fully functioning forum database:</p>
<ol>
<li>The Forums Table &#8211; Stores information about all the forums available to the web site</li>
<li>The Threads Table &#8211; Stores all the information about threads associated to the forums available in the forums table</li>
<li>The Posts Table &#8211; Stores all the messages posted to each of the threads in our forums</li>
<li>The Users Table &#8211; Stores the information about the registered users of the forum</li>
</ol>
<p>The bulkiest of these tables will probably be the Posts Table, since it is likely to handle &#8211; <em>potentially</em> &#8211; millions of records over a very long period of time. Here is a simple MySQL structure of the aforementioned tables to give you an idea.</p>
<pre class="brush: sql;">
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
--
-- Database: `_forum`
--
-- --------------------------------------------------------

--
-- Table structure for table `forums`
--

CREATE TABLE IF NOT EXISTS `forums` (
  `id` int(12) NOT NULL AUTO_INCREMENT,
  `user` int(12) NOT NULL,
  `title` varchar(256) NOT NULL,
  `desc` varchar(256) NOT NULL,
  PRIMARY KEY (`id`),
  KEY `user` (`user`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 ;

-- --------------------------------------------------------

--
-- Table structure for table `threads`
--

CREATE TABLE IF NOT EXISTS `threads` (
  `id` int(12) NOT NULL AUTO_INCREMENT,
  `user` int(12) NOT NULL,
  `forum` int(12) NOT NULL,
  `title` varchar(256) NOT NULL,
  `desc` varchar(256) NOT NULL,
  PRIMARY KEY (`id`),
  KEY `user` (`user`),
  KEY `forum` (`forum`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 ;

-- --------------------------------------------------------

--
-- Table structure for table `posts`
--

CREATE TABLE IF NOT EXISTS `posts` (
  `id` int(12) NOT NULL AUTO_INCREMENT,
  `user` int(12) NOT NULL,
  `thread` int(12) NOT NULL,
  `subject` varchar(256) DEFAULT NULL,
  `text` text NOT NULL,
  PRIMARY KEY (`id`),
  KEY `user` (`user`),
  KEY `thread` (`thread`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 ;

-- --------------------------------------------------------

--
-- Table structure for table `users`
--

CREATE TABLE IF NOT EXISTS `users` (
  `id` int(12) NOT NULL AUTO_INCREMENT,
  `name` varchar(12) NOT NULL,
  `pass` varchar(256) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 ;
</pre>
<p>As you can see every forum, thread, and post are each assigned a unique ID number in their respective tables. That number is sequential so it is set to auto-increment. Every time a new forum, thread, or post is added it is assigned the very next number in the sequence. These IDs are also indexed to allow us easier look ups in the database queries.</p>
<p>Now lets write some simple script to test out the functionality of our database. For the purpose of this tutorial we will use PHP. The script below demonstrates the most basic way to read from the database and output the data in the same traditional fashion that most web forums work. We start by listing all the forums on the front page. Each forum provides a link that leads to viewing all the threads within said forum. Now since each thread will also provide a link to view all the posts associated with this thread we are beginning to see how more and more data ties together in a web forum and this can make it a little more complicated down the road if the integrity of our data structure does not remain intact.</p>
<pre class="brush: php;">
&lt;?php
/*
# Lets just assume this entire script is stored in a file named forum.php
# Whenever forum.php is called without GET arguments it will list all of the forums available in the database. Because it outputs the HTML with the proper GET arguments included in the links for each forum/thread all the user has to do is simply click on a link and the data is generated for them automagically. That's pretty much how a forum works.
#
# Of course if you want to try this script you will need to set these variables to your database name, user, and password.
*/
$db = 'urdbname';
$dbuser = 'urdbuser';
$dbpass = 'urdbpass';
$dbhost = 'localhost';
$link = mysql_connect($dbhost, $dbuser, $dbpass);
mysql_select_db($db, $link);

// List Forums
function GetForums() {
  global $link;
  $result = mysql_query(&quot;SELECT COUNT(*) FROM forums&quot;, $link);
  $forums = mysql_fetch_row($result);
  $result = mysql_query(&quot;SELECT COUNT(*) FROM users&quot;, $link);
  $users = mysql_fetch_row($result);
  $put = &quot;There are &quot; . $forums[0] . &quot; forum(s) and &quot; . $users[0] . &quot; user(s) in the database.&quot;;

  for ($i = 0; $i &lt; $forums[0]; $i ++) {
    $data = mysql_fetch_row(mysql_query(&quot;SELECT * FROM forums LIMIT &quot;.$i.&quot;,1&quot;, $link));
    $put .= &quot;&lt;p&gt;&lt;a href='?f=&quot;.$data[0].&quot;'&gt;&quot; . $data[2] . &quot;&lt;/a&gt; - &lt;i&gt;&quot; . $data[3] . &quot;&lt;/i&gt;&lt;/p&gt;&quot;;
  }
  return $put;
}

// List Threads
function GetThreads($var) {
  global $link;
  $forumnum = $var;
  $result = mysql_query(&quot;SELECT COUNT(*) FROM threads WHERE forum = '&quot;.$forumnum.&quot;'&quot;, $link);
  $threads = mysql_fetch_row($result);
  $result_test = mysql_num_rows(mysql_query(&quot;SELECT * FROM forums WHERE id = '&quot;.$forumnum.&quot;'&quot;, $link));
  if (!$result_test) { echo &quot;This forum does not exist in the database...&quot;; exit; }
  $forum = mysql_fetch_assoc(mysql_query(&quot;SELECT * FROM forums WHERE id = '&quot;.$forumnum.&quot;'&quot;, $link));
  $put = &quot;There are &quot;.$threads[0].&quot; threads in the '&quot;.$forum['title'].&quot;' forum.&quot;;
  for ($i = 0; $i &lt; $threads[0]; $i ++) {
    $data = mysql_fetch_row(mysql_query(&quot;SELECT * FROM threads WHERE forum = '&quot;.$forum['id'].&quot;' LIMIT &quot;.$i.&quot;,1&quot;, $link));
    $put .= &quot;&lt;p&gt;&lt;a href='?t=&quot;.$data[0].&quot;'&gt;&quot; . $data[3] . &quot;&lt;/a&gt; - &lt;i&gt;&quot; . $data[4] . &quot;&lt;/i&gt;&lt;/p&gt;&quot;;
  }
  return $put;
}

// List Posts
function GetPosts($var) {
  global $link;
  $threadnum = $var;
  $result = mysql_query(&quot;SELECT COUNT(*) FROM posts WHERE thread = '&quot;.$threadnum.&quot;'&quot;, $link);
  $posts = mysql_fetch_row($result);
  $result_test = mysql_num_rows(mysql_query(&quot;SELECT * FROM threads WHERE id = '&quot;.$threadnum.&quot;'&quot;, $link));
  if (!$result_test) { echo &quot;This thread does not exist in the database...&quot;; exit; }
  $thread = mysql_fetch_assoc(mysql_query(&quot;SELECT * FROM threads WHERE id = '&quot;.$threadnum.&quot;'&quot;, $link));
  $put = &quot;There are &quot;.$posts[0].&quot; posts in the '&quot;.$thread['title'].&quot;' thread.&quot;;
  for ($i = 0; $i &lt; $posts[0]; $i ++) {
    $data = mysql_fetch_row(mysql_query(&quot;SELECT * FROM posts WHERE thread = '&quot;.$thread['id'].&quot;' LIMIT &quot;.$i.&quot;,1&quot;, $link));
    $put .= &quot;&lt;p&gt;&quot; . $data[4] . &quot;&lt;/p&gt;&quot;;
  }
  return $put;
}

if ($_GET['f']) $ui = GetThreads($_GET['f']); elseif ($_GET['t']) $ui = GetPosts($_GET['t']); else $ui = GetForums();
echo $ui;
mysql_close($link);
?&gt;
</pre>
<p>This code will merely show you how to read and display data from the database. Now all we need is a way for users to add their posts to the threads. We can accomplish this by using an HTML form. The elements of the HTML form we will need are very basic. A <strong>textarea</strong> is used to capture the users message and a <strong>submit button</strong> is used to send the request to the script. Here is some very basic HTML code to write a form to your script.</p>
<pre class="brush: xml;">
&lt;form id=&quot;form1&quot; name=&quot;form1&quot; method=&quot;post&quot; action=&quot;&quot;&gt;
  &lt;label&gt;
  &lt;textarea name=&quot;text&quot;&gt;&lt;/textarea&gt;
  &lt;/label&gt;
  &lt;label&gt;
  &lt;input type=&quot;submit&quot; name=&quot;Submit&quot; value=&quot;Submit&quot; /&gt;
  &lt;/label&gt;
&lt;/form&gt;
</pre>
<p>Next the script needs to handle the request through $_POST and add the post to the database. The example below is a simplistic approach to using post data from the form.</p>
<pre class="brush: php;">
$msg = $_POST['textarea'];
$msg = htmlspecialchars($msg); // Minimalistic method for preventing html/script injection
$result = mysql_query(&quot;INSERT INTO posts (thread, text) VALUES ('&quot;.$var.&quot;', '&quot;.$msg.&quot;')&quot;, $link);
</pre>
<p>Of course you will need to make sure your code has some basic error handling methods as well as best security practices to prevent nuances like <em>mysql injections</em> or <em>html/script injections</em> as these examples are meant for demonstration and educational purposes only. So in a nut shell that is how web forums work and, as outlined in this tutorial, you now have the fundamental building blocks of a web forum. You would need to include some method of maintaining user sessions, for example by storing login information such as usernames and passwords in the users table of the database. This will allow you to keep track of who has posted what messages and the threads they start. Also it might be a good idea to add a time column to the forums, threads, and posts tables in order to keep a record of when each record was added to the database. Other suggestions may include adding a paging system that will divide forums/threads/posts in to pages so as not to have the user load hundreds of posts or threads in one page. This will also reduce the overhead on your mysql server. Such methods are not described here in detail. Rather they are left for a more conclusive technical documentation or implementation. The purpose of this tutorial was to merely introduce the basic concepts of web forums using MySQL and PHP.</p>
]]></content:encoded>
			<wfw:commentRss>http://sheriframadan.com/2010/08/how-to-build-web-forums-using-php-and-mysql/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Understanding DNS in Order to Host Your Web Sites</title>
		<link>http://sheriframadan.com/2010/08/understanding-dns-in-order-to-host-your-web-sites/</link>
		<comments>http://sheriframadan.com/2010/08/understanding-dns-in-order-to-host-your-web-sites/#comments</comments>
		<pubDate>Fri, 13 Aug 2010 04:29:22 +0000</pubDate>
		<dc:creator>GoogleGuy</dc:creator>
				<category><![CDATA[DNS]]></category>
		<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[dns]]></category>
		<category><![CDATA[domain names]]></category>
		<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://sheriframadan.com/?p=39</guid>
		<description><![CDATA[Introduction This tutorial attempts to explain some of the inner-workings of DNS specifically in regards to web hosting. If you are thinking of getting in to web hosting, or have been hosting web sites for a while, you will likely benefit from this DNS tutorial. There are entire books written about DNS so I will [...]]]></description>
			<content:encoded><![CDATA[<h2>Introduction</h2>
<p>This  tutorial attempts to explain some of the inner-workings of DNS  specifically in regards to web hosting. If you are thinking of getting  in to web hosting, or have been hosting web sites for a while, you will  likely benefit from this DNS tutorial. There are entire books written  about DNS so I will not attempt to fully explain, in exhaustive detail,  the complex system that makes up DNS. It is not the purpose of this  tutorial to serve as a complete reference for DNS, but rather it is  meant to act as a guide in helping you understand what parts of DNS to  focus on for web hosting and maintaining a fully functioning web site.<br />
Before  we can begin let us first familiarize ourselves with some common  terminology associated with DNS. First off, DNS is an acronym, which is  commonly known as<em> Domain Name System</em> or<em> Domain Name Service</em>.  DNS relies on some protocols that have been refined over time &#8211; and  some that have refined DNS &#8211; as the Internet has grown and expanded to  what it is today. Such protocols as <em>HTTP</em>, <em>FTP</em>, <em>TCP</em>, <em>IP</em>, and <em>UDP </em>should  be basic general knowledge for those of us with a solid understanding of  the Domain Name System. These protocols fall under the <em>Internet Protocol Suite</em> or what’s more commonly known as <em>TCP/IP</em>. What we need to know about  this suite, for the purpose of this tutorial, focuses mostly on those  aforementioned protocols.</p>
<h2>Starting With The Domain Name</h2>
<p>If  you want to host a web site you will need a domain name. You can  register a domain name with any of the registrars available online,  through your ISP, or through a web hosting company. The process begins  by selecting a <em>Top Level Domain</em> or TLD. This is a domain like com, net, or org, for example. The TLD is  at the root of the domain hierarchy. To a human we read a domain from  left to right. For example, www.domain.com is read starting with the www and ending with com. To a computer or DNS  server, the domain name is read from right to left starting with the  TLD and ending with the lowest point in the domain name space relative  to the tree of the domain hierarchy. So www.domain.com translates to com.domain.www in a DNS because the DNS needs to start at  the top of the domain name space and work its way down in order to  resolve. You may ask, why use this nonsensical routine that contradicts  the way you read and understand domain names? To us it seems  contradicting based on how we may have become accustomed to reading a  domain name, but to computers it makes sense based on how the DNS is  designed. What you need to remember is that DNS is a hierarchical system  and finds authoritative name servers by searching at the top of the  hierarchy and working its way down until it finds the parent name  servers. DNS is also delegated into zones and subzones to make it more  efficient.<br />
A  <em>Fully Qualified Domain Name </em>or FQDN is distinguished by its uniqueness  in the domain name space and is some times referred to as an absolute  domain name. For example, if we have a server on a network with the  host-name server1 then server1 will be relative to its root domain. If  that root domain, including the TLD, happens to be domain.com then server1.domain.com is an FQDN as there can only be one server1.domain.com even though there may be many server1’s in other parts of the domain  name space (e.g. server1.mydomain.com, server1.yourdomain.com,  server1.ourdomain.com, etc). The host is thus unique in the domain name  space and this is an important part of how the DNS was designed to  remain hierarchical in a host-to-client fashion. The machine can now be  uniquely identified on the Internet by server1.domain.com regardless of one’s physical location.</p>
<h2>Name Servers</h2>
<p>ISPs  setup DNS servers and DNS resolvers that communicate with each other to  locate information about domain names. The Name Servers tell us where  to look for information about a particular domain name. Registrars  retain the name server information that points to a particular domain  name. This is called an NS record. It shows up on dig (a linux  networking tool) as domain.com. 86400 IN NS ns1.domain.com,  for example. You can set multiple name servers, but the general  practice is that you have at least two name servers for each domain.  This way if one fails then hopefully the secondary name server will  still resolve. You can use the same name servers for multiple domains.  Name servers can be both public and private. When the name servers point  to the domain itself then the IP or Internet Protocol address must also be set in the A records of that domain name.<br />
If  you are using a shared hosting account you will most likely use your  web hosts name servers set on that server. Some web hosts will allow you  to use private name servers. In this matter you will set <strong>ns1.yourdomain.com</strong> and<strong> ns2.yourdomain.com</strong> as the name servers for you domain with your domain registrar and  specify the IPs that your web host provides you for those name servers.<br />
If  you are running a dedicated server you will need to have your own DNS  software installed. The standard is usually BIND. BIND stands for <em>Berkley Internet Name Daemon</em> and is sometimes referred to as named.  Low-end VPS machines or some home networks may use smaller foot-print  DNS server software such as Dnsmasq. While BIND has had some security  vulnerabilities BIND9 is still certainly popular in use. Your focus  should be on DNS cacheing and recursive DNS queries rather than  authoritative DNS, unless you really know what you’re doing.</p>
<h2>A Records, CNAMEs, PTR, and MX Records</h2>
<p>People will commonly use www.domain.com in their browsers rather than domain.com when visiting a website. If you are hosting your web sites thinking  these two are one and the same you are mistaken. They are in fact viewed  as two different web sites. Common search engine bots like Google’s  Google Bot will crawl these URLs as two different web sites. To avoid  any confusion there is a good way to work around this both on the DNS  side and through your web server software (for example, configuring your .htacess file to treat this with a 301 perm redirect).<br />
First,  you should consider that CNAME records (<em>Canonical Name</em>) will create a  second lookup when retrieving the records. They can be avoided by simply  using the alias as an A record. The A record can then look something  like this:</p>
<p><a rel="attachment wp-att-47" href="http://sheriframadan.com/2010/08/understanding-dns-in-order-to-host-your-web-sites/dig-example_com-2/"><img class="alignnone size-full wp-image-47" title="dig-example_com" src="http://sheriframadan.com/wp-content/uploads/2010/08/dig-example_com1.gif" alt="" width="572" height="398" /></a></p>
<p>If  we add www.example.com. to A 192.0.32.10 then the alias will still  point to the same IP without creating an CNAME lookup. This is because  the server will first find www.example.com IN CNAME example.com and then proceed to lookup example.com to find it IN A 192.0.32.10</p>
<p><a rel="attachment wp-att-46" href="http://sheriframadan.com/2010/08/understanding-dns-in-order-to-host-your-web-sites/dig-google_com-2/"><img class="alignnone size-full wp-image-46" title="dig-google_com" src="http://sheriframadan.com/wp-content/uploads/2010/08/dig-google_com1.gif" alt="" width="541" height="313" /></a></p>
<p>If you’re not familiar with the numbers showing up in the dig these are called TTL or Time To Live.  They represent how often the records should be updated. The settings  can vary based on record type. Again because DNS is a hierarchical  distributed system the authoritative name servers will pass the records  on to the caching name servers until the TTL has expired. This can cause  different load issues depending on how low or high the TTL is set. It  is generally not a good idea to lower your TTL too much unless you are  constantly updating your DNS records, which is likely never the case.<br />
Your MX records (Mail Exchange)  are prioritized. So MX 0 should always be the first point of mail  delivery. The lower the number set in the MX record the higher priority  it gets.<br />
Its also important to consider rDNS or <em>Reverse DNS</em> for your domain especially if you plan on sending mail from that domain. Some mail servers will attempt to verify fcrDNS, or <em>Forward Confirmed Reverse DNS</em>, from ips they receive mail from in order to prevent domain name spoofing (this is where a malicious server attempts to use some one else&#8217;s domain in their email header). Reverse DNS is basically the opposite of what we discussed earlier. Instead of the resolver using the domain name to find an IP address it is using an IP address to find a domain name. This can be done through a PTR record or <em>Pointer Record</em>. The IPv4 uses the in-addr.arpa domain and IPv6 uses the ip6.arpa domain. The pointer record helps us resolve the reverse DNS lookup in these domains. Forward Confirmed Reverse DNS is a full loop. The mail server will usually take the IP that the mail was received from and will attempt to resolve it to a domain using the reverse DNS lookup. That domain is then resolved back to an IP address and if the IPs match then the the fcrDNS test is a pass (i.e. we can be pretty sure that this IP is the one that correctly delivered the mail). Failing the fcrDNS test does not necessarily prevent your mail from being delivered, but most large email servers &#8211; especially ones that handle millions of emails per day like Yahoo, MSN, or Gmail &#8211; will delay or possibly reject the mail delivery. It might also get filtered out as spam so make sure you have correctly configured your rDNS. This process will require a dedicated IP address to become a fully qualified loop.</p>
<p>There  are many other areas to be looked at in setting up and configuring DNS  so I will try to update this tutorial where possible. Feel free to let  me know if you have any questions or suggestions for this tutorial or to  correct/append anything I may have overlooked.</p>
]]></content:encoded>
			<wfw:commentRss>http://sheriframadan.com/2010/08/understanding-dns-in-order-to-host-your-web-sites/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>A Little Tech on Web Hosting</title>
		<link>http://sheriframadan.com/2010/08/a-little-tech-on-web-hosting/</link>
		<comments>http://sheriframadan.com/2010/08/a-little-tech-on-web-hosting/#comments</comments>
		<pubDate>Mon, 02 Aug 2010 14:33:41 +0000</pubDate>
		<dc:creator>GoogleGuy</dc:creator>
				<category><![CDATA[Web Hosting]]></category>
		<category><![CDATA[cloud hosting]]></category>
		<category><![CDATA[dedicated hosting]]></category>
		<category><![CDATA[free hosting]]></category>
		<category><![CDATA[shared hosting]]></category>
		<category><![CDATA[vps]]></category>
		<category><![CDATA[web hosting]]></category>

		<guid isPermaLink="false">http://sheriframadan.com/?p=8</guid>
		<description><![CDATA[I&#8217;ve decided to intrigue my humble audience with a brief look at the web hosting industry. Supposing most of you are already familiar with web hosting and, generally, how it works works, we&#8217;ll begin by breaking down the different types of web hosting that are commercially available today. Free Web Hosting Free can mean not-so-free, [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve decided to intrigue my humble audience with a brief look at the web hosting industry. Supposing most of you are already familiar with web hosting and, generally, how it works works, we&#8217;ll begin by breaking down the different types of web hosting that are commercially available today.</p>
<h2 style="padding-left: 30px;">Free Web Hosting</h2>
<p style="padding-left: 60px;">Free can mean not-so-free, sometimes. This type of web hosting is offered, usually, as an introductory hosting service to sell other paid web hosting services. It can be ad-free or otherwise. There are many limitations and constraints that are normally associated with this type of hosting. For example, you may not be able to host certain types of content with a non-paid hosting account. The host may restrict disk space and monthly data-transfer allotments stringently. The host may or may not allow you to use your own domain name. There can also be restrictions on certain files. For example, the host may prohibit you from using a custom <strong>404 &#8211; Page Not Found</strong> error page or other types of error documents. This type of hosting is generally discouraged for business use as it does not set a good impression. Using a free hosting service is much like using a free email account for your business. It may lead your customers to view your business as unprofessional or result in other criticism. You should invest in a quality web hosting service as you would invest in your business.</p>
<h2 style="padding-left: 30px;">Shared Web Hosting</h2>
<p style="padding-left: 60px;">This type of hosting is fairly common and you&#8217;ve probably come across this terminology by now. <em>Shared web hosting</em> is essentially when a user pays to use a small portion of a server for hosting their websites. However, the user can be limited to a specific number of constraints such as disk space, monthly data transfer, number of domains, database access, or even server-side-scripting access. The user is sharing that server with many other users who are also paying a small fee to host their own web sites. The users do not generally interact with one another or even know that they exist on the same server apartment from knowing that it is a shared web hosting server.<br />
With shared web hosting you don&#8217;t have to worry about any of the techy stuff behind closed doors. You are usually going to find web hosts that provide some control panel interface for their users to utilize their server resources. This makes managing things on a linux server, for example, much easier for users who do not know linux. You can find popular control panels such as <a href="http://www.webmin.com/">webmin</a>, <a href="http://www.cpanel.net/" target="_blank">cPanel</a>, <a href="http://www.parallels.com/landingpage/dskd42-3/?source=google_us&amp;_kk=plesk&amp;_kt=eef1256a-9ef9-49c1-ac75-cc07ba7821ee" target="_blank">Plesk</a>, <a href="http://www.psoft.net/hsphere-overview.html" target="_blank">H-Sphere</a> and many more online and try a demo for free. Since the majority of all computer users use Windows, and are generally accustomed to this type of GUI, it puts those users with a better understanding of *nix based operating systems at an advantage; since a great number of web hosting companies will run their servers on linux.</p>
<h2 style="padding-left: 30px;">Dedicated Hosting</h2>
<p style="padding-left: 60px;">With a dedicated hosting solution you are given a server that is dedicated solely to you. Here you will need to whip out all those tech skills in order to use the server. This is a much more costly solution vs. shared hosting. On shared hosting you are paying a fraction of what it costs the web hosting company to run and manage that server, but with dedicated hosting you are taking on the full cost of the server by yourself. This has its benefits as well as its drawbacks.<br />
In a dedicated hosting environment you are offered a more heightened security level. You have control and freedom over your security protocols, software configurations, and root privileges. This puts you front and center in the cockpit of hosting. With dedicated hosting solutions you have the ability to build your own network, create virtual private networks, enable virtual private servers on your machines, and even create your own firewalls.<br />
There are many reasons why people will choose dedicated hosting over shared hosting and it primarily leads back to freedom. On a shared hosting environment the host must maintain the server adequately for all of its users. This means the host will likely put in place certain policies to prohibit the abusive users from consuming too many server resources, posing security risks that may otherwise harm other users or compromise the server, or overloading the server. These policies are usually defined in a document called the <em>AUP</em> or Acceptable Usage Policy and somtimes is contained or outlined in the <em>TOS</em> or Terms of Service Agreement that the host enforces.</p>
<p>Many other solutions have been introduced to the web hosting industry over the years. Terms like <em>VPS Hosting</em>, <em>Cloud Hosting</em>, <em>Reseller Hosting</em>, <em>SEO Hosting</em>, <em>Semi-dedicated Hosting</em> and <em>Unlimited Hosting</em> are becoming increasingly popular.</p>
<p>A <strong>VPS </strong>or Virtual Private Server is a software-based server. It acts and feels like a real dedicated machine, much like having your own dedicated server, but it runs on a single machine where several other virtual private servers may be running. So in essence it is much like the shared hosting concept, but with more flexibility and control. This is a much cheaper alternative to having your own dedicated server.</p>
<p><strong>The Cloud</strong> is simply stemming from the idea that we now live in a world where everyone wants to share with everyone else. Sharing doesn&#8217;t necessarily mean giving up privileges, as some may suspect. Cloud hosting means you are on a network of virtual private servers, where everything is automated to utilize the network as a whole. You can provision a VPS within minutes using automated virtualization software and get your server online through the cloud immediately. Additionally, the cloud offers some substantial benefits in the areas of scalability. For example, most clouds are designed with the ideology that you pay for what you use. Companies like RackSpace and Amazon offer cloud computing that you pay for by the hour. You can quickly setup a few dozen servers to test your applications and take them down when you&#8217;re done. Most hardware specs are customizable and easily upgraded or downgraded. The cloud also allows us to share file storage systems and applications. This makes for more efficient web 2.0 utilization since most of us use the same apps online anyway. What&#8217;s more is that you can easily rely on the cloud to migrate your servers near-instantaneously. If a server goes down or crashes, the instance can easily be migrated to a different machine or even a different data center within minutes, as opposed to hours with a dedicated server.</p>
<p>I hope this quick glance at the web hosting industry has caught your attention. Stay tuned for more on tech and web hosting talk!</p>
]]></content:encoded>
			<wfw:commentRss>http://sheriframadan.com/2010/08/a-little-tech-on-web-hosting/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hello World!</title>
		<link>http://sheriframadan.com/2010/07/hello-world/</link>
		<comments>http://sheriframadan.com/2010/07/hello-world/#comments</comments>
		<pubDate>Thu, 15 Jul 2010 12:44:07 +0000</pubDate>
		<dc:creator>GoogleGuy</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://sheriframadan.com/?p=1</guid>
		<description><![CDATA[And so the blogging begins&#8230; &#60;?php echo &#34;Hello World!&#60;br /&#62;&#34;; $ideal = array(&#34;journal&#34;, &#34;publish&#34;, &#34;typewriter&#34;); $conceptual = array(&#34;blog&#34;, &#34;post&#34;, &#34;laptop&#34;); $txt = &#34;I have decided to restart my journal and publish a few things online. Sorry that my site went offline for a while. I lost my typewriter and my domain expired, but luckily no [...]]]></description>
			<content:encoded><![CDATA[<p>And so the blogging begins&#8230;</p>
<pre class="brush: php;">
&lt;?php
echo &quot;Hello World!&lt;br /&gt;&quot;;
$ideal = array(&quot;journal&quot;, &quot;publish&quot;, &quot;typewriter&quot;);
$conceptual = array(&quot;blog&quot;, &quot;post&quot;, &quot;laptop&quot;);
$txt = &quot;I have decided to restart my journal and publish a few things online. Sorry that my site went offline for a while. I lost my typewriter and my domain expired, but luckily no one grabbed it while I was offline and I was able to re-register it and get my journal back online! I've decided to go with WordPress since it seems to be all the rage these days.&quot;;
$intro = str_ireplace($ideal, $conceptual, $txt);
echo $intro;
// Output:
/*
Hello World!
I have decided to restart my blog and post a few things online. Sorry that my site went offline for a while. I lost my laptop and my domain expired, but luckily no one grabbed it while I was offline and I was able to re-register it and get my blog back online! I've decided to go with WordPress since it seems to be all the rage these days.
*/
?&gt;
</pre>
<p>I thought I&#8217;d start things off by posting this Hello World php script. Just <a href="http://sheriframadan.com/helloworld.php" target="_blank">click here</a> if you&#8217;d like to actually try it yourself. Thanks!</p>
]]></content:encoded>
			<wfw:commentRss>http://sheriframadan.com/2010/07/hello-world/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
