<?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>Eric Williams</title>
	<atom:link href="http://www.ecwilliams.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ecwilliams.net</link>
	<description>Yadda Yadda......</description>
	<lastBuildDate>Wed, 26 Aug 2009 15:25:28 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Sending Text Messages Via PHP</title>
		<link>http://www.ecwilliams.net/2009/08/26/sending-text-messages-via-php/</link>
		<comments>http://www.ecwilliams.net/2009/08/26/sending-text-messages-via-php/#comments</comments>
		<pubDate>Wed, 26 Aug 2009 15:14:20 +0000</pubDate>
		<dc:creator>Eric Williams</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Text Message]]></category>

		<guid isPermaLink="false">http://www.ecwilliams.net/?p=15</guid>
		<description><![CDATA[Sunday is family day for us.  We try on most Sundays to get together for lunch after church.  It is nice to get together and catchup on what is happening in everyone&#8217;s lives.
The problem is it is so hard to get everyone to agree on a restaurant!  Honestly this is usually a [...]]]></description>
			<content:encoded><![CDATA[<p>Sunday is family day for us.  We try on most Sundays to get together for lunch after church.  It is nice to get together and catchup on what is happening in everyone&#8217;s lives.</p>
<p>The problem is it is so hard to get everyone to agree on a restaurant!  Honestly this is usually a 15 to 20 minute ordeal.  Lots of I don&#8217;t care, whatever you want, anything but that kind of comments.</p>
<p>The solution, write down all the restaurants within a 5 mile radius that everyone can tolerate, then either go down the list or choose randomly.</p>
<p>Below is a fun little script that I wrote to choose a random restaurant and text the results too us.</p>
<p>Most of the cell phone carriers allow sending of text messages via email Verizon&#8217;s format is thenumber@vtext.com, other carriers you will have to check.</p>
<pre>
<code>set_time_limit(0);

//Creating Restaurants List
$restaurants = array();
$restaurants = array("Applebees", "Red Lobster", "Red Robin", "Chilis", "Sweet Tomatos", "Culvers", "Olive Garden", "Macayos", "Rio Marage", "Golden Corral", "Brookside", "Chipolte", "My Greek Corner", "Fridays", "Paridise Bakery", "Chuy's", "Streets of New York", "Taco Bell", "Charleys", "Wendy's", "Long John Silvers", "Out Back", "Buffalo Wild Wings", "Burger King", "A&amp;W KFC", "NYPD Pizza");

//Selecting Random Restaurant
$rand_restaurant = array_rand($restaurants,1);

//Creating Email List
$emailaddress = array();
$emailaddress = array("1111111111@vtext.com,2222222222@vtext.com");

//Setting Email Properties
$emailsubject = "Today we are eating at....";
$emailbody = $restaurants[$rand_restaurant];
$fromaddress = "you@youremail.com";

//Getting email Count
$i = count($emailaddress);

$z = 0;

//Loop only if we have some email addresses
if ($i != 0)

{

while ($i != $z)

{
// Send the Mail
mail($emailaddress[$z], $emailsubject, $emailbody, "From: " .$fromaddress. "\nX-Mailer: PHP 4.x");

echo $z + 1 . " out of " . $i . " emails sent. (" . $emailaddress[$z] . ")
";

++$z;

}

}

else

{

echo "Warning: No emails in array.";
}</code></pre>
<p>Also I wanted the text to be sent out every Sunday at 10:05AM so I added the following line to /etc/crontab</p>
<p><code>5  10 * * sun php /path/to/file.php</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ecwilliams.net/2009/08/26/sending-text-messages-via-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setting Up OpenBD on a Linux Cpanel Server</title>
		<link>http://www.ecwilliams.net/2009/08/21/setting-up-openbd-on-a-linux-cpanel-server/</link>
		<comments>http://www.ecwilliams.net/2009/08/21/setting-up-openbd-on-a-linux-cpanel-server/#comments</comments>
		<pubDate>Fri, 21 Aug 2009 22:47:04 +0000</pubDate>
		<dc:creator>Eric Williams</dc:creator>
				<category><![CDATA[Coldfusion]]></category>
		<category><![CDATA[Cpanel]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[OpenBD]]></category>
		<category><![CDATA[Tomcat]]></category>

		<guid isPermaLink="false">http://ecwilliams.net/?p=5</guid>
		<description><![CDATA[There is an excellent writeup on openbluedragon.org that explains installing OpenBD on Centos/Redhat with Apache and Tomcat.  Cpanel can be used to install Tomcat so the setup is a little different.
Install Tomcat
This can be done in WHM under EasyApache (Apache Update).  Just check the Tomcat option when saving your build.
Install OpenBD
cd /usr/local/jakarta/
wget http://openbd.viviotech.net/downloader.cfm/id/64/file/openbd.war
cp /usr/local/jakarta/openbd.war [...]]]></description>
			<content:encoded><![CDATA[<p>There is an excellent writeup on openbluedragon.org that explains <a href="http://wiki.openbluedragon.org/wiki/index.php/Apache_Tomcat_on_CentOS/RedHat">installing OpenBD on Centos/Redhat with Apache and Tomcat</a>.  Cpanel can be used to install Tomcat so the setup is a little different.</p>
<h3>Install Tomcat</h3>
<p>This can be done in WHM under <strong>E</strong>asyApache (Apache Update).  Just check the Tomcat option when saving your build.</p>
<h3>Install OpenBD</h3>
<p><code>cd /usr/local/jakarta/</code><br />
<code>wget http://openbd.viviotech.net/downloader.cfm/id/64/file/openbd.war</code><br />
<code>cp /usr/local/jakarta/openbd.war /usr/local/jakarta/tomcat</code></p>
<p>Go to <a href="http://localhost:8080/openbd/bluedragon/administrator">http://localhost:8080/openbd/bluedragon/administrator</a>.  Login with the password <em>admin</em> and change the default password to whatever you want.</p>
<h3>Enable CFM</h3>
<p>By default Tomcat will execute any jsp page for an account that has jsp enabled.  To enable cfm we have to modify the setup script slightly.  To do this open /scripts/addservlets2 in your favorite editor and modify the IfModule mod_jk.c portion of the file to look like the code below.</p>
<p><code>&lt;IfModule mod_jk.c&gt;<br />
JkMount /*.cfm ajp13<br />
JkMount /*.cfc ajp13<br />
JkMount /*.do ajp13<br />
JkMount /*.jsp ajp13<br />
JkMount /*.cfchart ajp13<br />
JkMount /*.cfres ajp13<br />
JkMount /*.cfm/* ajp13<br />
JkMount /*.cfml/* ajp13<br />
JkMount /servlet/* ajp13<br />
JkMount /servlets/* ajp13<br />
&lt;/IfModule&gt;</code></p>
<h3>Enable Tomcat for your Domain</h3>
<p><code>/scripts/addservlets2 --domain=yourdomain.com</code></p>
<h3>Copy Directories</h3>
<p>Unfortunately with this setup you have to have an admin for every domain.</p>
<p><code>cp -Rf /usr/local/jakarta/tomcat/bluedragon /home/yourdomaindirectory/public_html</code><br />
<code>cp -Rf /usr/local/jakarta/tomcat/WEB-INF /home/yourdomaindirectory/public_html</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.ecwilliams.net/2009/08/21/setting-up-openbd-on-a-linux-cpanel-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
