<?xml version="1.0" encoding="iso-8859-1"?>

<rdf:RDF 
	xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns="http://purl.org/rss/1.0/"
>
		
		
		
	<channel rdf:about="http://www.justicesolutionsllc.com/blogcfm">
	<title>Justice Solutions LLC Blog</title>
	<description>Powered by BlogCFM</description>
	<link>http://www.justicesolutionsllc.com/blogcfm</link>
	
	<items>
		<rdf:Seq>
			
			
			
				
			<rdf:li rdf:resource="http://www.justicesolutionsllc.com/blogcfm/1/2008/02/Taming-the-CatTomcat-and-Coldfusion-8.cfm" />
			
			
			
				
			<rdf:li rdf:resource="http://www.justicesolutionsllc.com/blogcfm/1/2008/02/57.Getting-the-CRUD-out-in-your-code.cfm" />
			
			
		</rdf:Seq>
	</items>
	
	</channel>
		
		
		
		
		
		
		
		
		
  	<item rdf:about="http://www.justicesolutionsllc.com/blogcfm/1/2008/02/Taming-the-CatTomcat-and-Coldfusion-8.cfm">
	<title>Taming the Cat...Tomcat and Coldfusion 8</title>
	<description>&lt;p&gt;Ok, this week on Thursday Tips Day, I have a rather unique situation I was working on for a client.&amp;nbsp; The issue:&amp;nbsp; To get Tomcat 6 working on a Windows 2003 server running IIS and have ColdFusion 8 running on the Tomcat install.&lt;/p&gt;
&lt;p&gt;This is not as easy as it would seem.&amp;nbsp; According to the Adobe ColdFusion 8 site (&lt;a href=&quot;http://www.adobe.com/coldfusion&quot;&gt;www.adobe.com/coldfusion&lt;/a&gt;) Tomcat is not directly supported as is was in the past.&amp;nbsp; The only mention of Tomcat in any of the installation documentation is only in a JBOSS type instance.&amp;nbsp; So here&apos;s the first question...why would someone want to do this?&lt;/p&gt;
&lt;p&gt;The client&apos;s decision is actually a very good one.&amp;nbsp; Those of us familiar with ColdFusion over the years would agree that JRun is not the best Java server around.&amp;nbsp; In fact it sometimes causes more harm than good.&amp;nbsp; And in some unique situations it really ends up crashing the server and causing all kinds of Coldfusion errors when it gets too bogged down.&amp;nbsp; Now in CF8&apos;s Enterprise Edition, the server monitoring tools are very good in letting you know what is causing the overloads.&amp;nbsp; Sometimes it&apos;s your own code doing it.&amp;nbsp; Sometimes it&apos;s not.&amp;nbsp; However for those of us not willing to spend the $4,000+ to purchase a copy of Enterprise Edition, we&apos;re back to the same page as always.&lt;/p&gt;
&lt;p&gt;Anyway, by choosing a Java server such as Tomcat, which has plenty of public support and has been running Java apps for quite some time very reliably on both Linux and Windows platforms (and even a Macintosh here and there I&apos;ve seen), the client will be able to run their JSP apps, plus leverage Tomcat&apos;s excellence in running CF8&apos;s Java based programming technology.&amp;nbsp; Therefore a very lean and mean system and as the client puts it, &amp;quot;a smaller footprint&amp;quot; on their server.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The Installation Sequence&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Ok, so to start, go ahead and download the latest version of Tomcat (&lt;font face=&quot;Arial&quot;&gt;&lt;a href=&quot;http://tomcat.apache.org/download-60.cgi&quot;&gt;http://tomcat.apache.org/download-60.cgi&lt;/a&gt;) and install it on your Windows2003 Server.&amp;nbsp; You can do the direct services install or the longer more in depth binary install, but both work just fine.&amp;nbsp; After the installation is complete.&amp;nbsp; You should easily be able to browse to &lt;a href=&quot;http://localhost:8080&quot;&gt;http://localhost:8080&lt;/a&gt; to get the nice little Tomcat welcome page.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Next download a copy of CF8 from Adobe&apos;s website (&lt;font face=&quot;Arial&quot;&gt;&lt;a href=&quot;http://www.adobe.com/products/coldfusion/&quot;&gt;http://www.adobe.com/products/coldfusion/&lt;/a&gt;) and install that on your server next by using the &amp;quot;Deploy as J2EE, and as a .WAR&amp;quot; installation.&amp;nbsp; When the installation is complete you should have a .WAR file most likely if you used the defaults in your C:\ColdFusion8 root directory.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Stop the Tomcat Server via your services or direct command line.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;Now copy the .WAR file into your {TomcatRoot}\webapps directory.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;Start the Tomcat Server and within a few minutes, Tomcat should have expanded all of your directories into the webapps folder.&amp;nbsp; So at the end you should have a /cfusion directory sequence in your webapps directory.&lt;/p&gt;
&lt;p&gt;Stop the Tomcat Server again.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;Ok, now for a fun part.&amp;nbsp; Open up notepad and create a .bat file called setenv.bat and place it in the {TomcatRoot}\bin folder.&amp;nbsp; Place the following code in that .bat file making sure to change the bolded areas to your exact folder structure:&lt;/p&gt;
&lt;p&gt;&lt;font face=&quot;Courier New&quot;&gt;rem Set a few variables.&lt;br /&gt;
set JAVA_HOME=&lt;strong&gt;C:\Program Files\Java\jre1.5.0_14&lt;br /&gt;
&lt;/strong&gt;set CF_HOME=&lt;strong&gt;C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\cfusion&lt;br /&gt;
&lt;/strong&gt;set CF_WEB_INF=%CF_HOME%/WEB-INF&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face=&quot;Courier New&quot;&gt;rem Concatenate binary file directories into a single variable.&lt;br /&gt;
set CF_SHARED_LIB=%CF_WEB_INF%/cfusion/lib&lt;br /&gt;
rem The following variable must be on a single line.&lt;br /&gt;
set CF_SHARED_LIBS=%CF_SHARED_LIB%;%CF_SHARED_LIB%/_nti40/bin;&lt;br /&gt;
%CF_WEB_INF%/cfusion/jintegra/bin;&lt;br /&gt;
%CF_WEB_INF%/WEB-INF/cfusion/jintegra/bin/international&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face=&quot;Courier New&quot;&gt;rem Add libraries for binary files to the Windows system path. &lt;br /&gt;
set PATH=%PATH%;%CF_SHARED_LIBS%&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face=&quot;Courier New&quot;&gt;rem Set JVM options to enable sandbox security (all on one line).&lt;br /&gt;
set CF_SECURITY_JVM_OPTIONS=-Djava.security.manager &lt;br /&gt;
-Djava.security.policy=&amp;quot;%CF_WEB_INF%/cfusion/lib/coldfusion.policy&amp;quot; &lt;br /&gt;
-Djava.security.auth.policy=&amp;quot;%CF_WEB_INF%/cfusion/lib/neo_jaas.policy&amp;quot;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face=&quot;Courier New&quot;&gt;rem Set JVM options for CORBA. Uncomment this line if vbjorb.jar is not in&lt;br /&gt;
rem your JRE&apos;s lib/ext directory.&lt;br /&gt;
rem set CF_CORBA_JVM_OPTIONS=-Xbootclasspath/a:&amp;quot;%CF_WEB_INF%/lib/vbjorb.jar&amp;quot;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face=&quot;Courier New&quot;&gt;rem Consolidate JVM options.&lt;br /&gt;
rem * Uncomment this line if you&apos;ve configured CORBA&lt;br /&gt;
rem set CF_JVM_OPTIONS=%CF_SECURITY_JVM_OPTIONS% %CF_CORBA_JVM_OPTIONS%&lt;br /&gt;
rem * Uncomment this line if you haven&apos;t configured CORBA&lt;br /&gt;
set CF_JVM_OPTIONS=%CF_SECURITY_JVM_OPTIONS% &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face=&quot;Courier New&quot;&gt;rem Populate JAVA_OPTS, which will be used by the catalina.bat file&lt;br /&gt;
rem when starting the JVM.&lt;br /&gt;
set JAVA_OPTS=%CF_JVM_OPTIONS%&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Ok, go ahead and start Tomcat back up, and browse to localhost:8080/cfusion/cfide/administrator and with any luck, you should have the nice welcome screen of the ColdFusion 8 admin staring you in the face.&amp;nbsp; Go ahead and configure your instance with datasources, etc. and place any .cfm files you want to run in the /cfusion/cfide/ directory.&lt;/p&gt;
&lt;p&gt;That&apos;s it.&amp;nbsp; I&apos;m now in the process of getting the .cfm files to render in other directories and folder structures in the rest of the Tomcat so you can browse to other directories with .cfm files and get them to render.&amp;nbsp; Until next week!&lt;/p&gt;</description>
	<link>http://www.justicesolutionsllc.com/blogcfm/1/2008/02/Taming-the-CatTomcat-and-Coldfusion-8.cfm</link>
	<dc:date>2008-02-28T00:00:00-07:00</dc:date>
	
	<dc:subject>Web Development, Web Design, Web Consulting, Web Applications, Code Help,Coldfusion, ColdFusion8, Java, Tomcat</dc:subject>
	</item>
	
	
 	
		
		
		
		
		
  	<item rdf:about="http://www.justicesolutionsllc.com/blogcfm/1/2008/02/57.Getting-the-CRUD-out-in-your-code.cfm">
	<title>Getting the CRUD out in your code</title>
	<description>Ok, it&apos;s Thursday Tips Day, and I wanted to show you a very handy tool you can be using to speed along your development time, or help your web department speed their development time along at your own company.&lt;br /&gt;
&lt;br /&gt;
The tool is called an Object Generator or an O/R Mapper.&amp;nbsp; Some also like to call them &amp;quot;CRUD&amp;quot; Tools.&amp;nbsp; CRUD is an acronym we geeky coders like to use that stands for:&amp;nbsp; Create, Read, Update, Delete.&amp;nbsp; In almost every basic web application out there today, we are asked to interface with some type of database or datasource.&amp;nbsp; And in almost every instance of that interfacing we (the coders) are doing some type of call to the database.&amp;nbsp; It could be reading one record, getting several records, updating a record, or even deleting one.&amp;nbsp; &lt;br /&gt;
&lt;br /&gt;
Writing these calls can be very mundane.&amp;nbsp; Ones I usually save for my new coders to do &lt;em&gt;&lt;strong&gt;&amp;lt;insert evil laugh here&amp;gt;&lt;/strong&gt;&lt;/em&gt;.&amp;nbsp; However, these CRUD or Object Generator tools can help things along tremendously in development time, which then allows us or your web developers, time to focus on things that are usually overlooked or zipped through at the end of a project such as field validation, styles, SEO, etc.&lt;br /&gt;
&lt;br /&gt;
For ASP.net we personally like to use O/R Mapper (&lt;a target=&quot;_blank&quot; href=&quot;http://www.ornetmapper.com&quot;&gt;www.ornetmapper.com&lt;/a&gt;).&amp;nbsp; The thing I personally like about this open source tool is the simple fact that the developer continues to really improve this tool with newer and more awesome releases than its prior.&amp;nbsp; As of this updated blog, the latest version is version 6, and it&apos;s come a long way and really could be the easiest most comprehensive way to develop the business logic for your next .NET project.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;div align=&quot;center&quot;&gt;&lt;strong&gt;A Screen Shot of O/R Mapper (the ASP.NET Object Mapper Tool)&lt;br /&gt;
&lt;/strong&gt;&lt;img vspace=&quot;10&quot; hspace=&quot;5&quot; border=&quot;1&quot; src=&quot;http://www.justicesolutionsllc.com/images/ss_ormapper_1.jpg&quot; alt=&quot;O/R Mapper Screen Shot&quot; /&gt;&lt;br /&gt;
&lt;strong&gt;&lt;br /&gt;
&lt;/strong&gt;
&lt;div align=&quot;left&quot;&gt;And using the code is even easier than using the tool itself in .NET.&amp;nbsp; So here&apos;s a quick example.&amp;nbsp; Let&apos;s say you have a table called Users and in your datagrid you have your typical select button which triggers your onSelect event in your code behind.&amp;nbsp; So now you want to populate a few text boxes in your form for editing.&amp;nbsp; Here it goes....in C#.net&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  Users u = new Users();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  UsersAssembler a = new UsersAssembler();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp; UsersCriteria c = new UsersCriteria();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  c.Set_Username(CriteriaBase.AVAILABLE_STRING_OPERATORS.EQUALS, &amp;quot;doug&amp;quot;);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  u.ReadSingle(c);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &lt;br /&gt;
Now that you have the information loaded into the &amp;quot;u&amp;quot; object...you just assign your textboxes accordingly....&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  tbUsername.Text = u.Username;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  tbPassword.Text = u.Password;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  tbFirst.Text = u.FirstName;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp; tbLast.Text = u.LastName;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  etc.&lt;br /&gt;
&lt;br /&gt;
Did you blink and missed it?&amp;nbsp; Yes it&apos;s that quick.&amp;nbsp; You can also retrieve lists of results and do things like auto-bind it to your gridview, etc.&amp;nbsp; Really really cool.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
For PHP, we personally like to use POG.&amp;nbsp; (&lt;a target=&quot;_blank&quot; href=&quot;http://www.phpobjectgenerator.com&quot;&gt;www.phpobjectgenerator.com&lt;/a&gt;) This nifty little online tool will allow you to not only create the code classes you&apos;ll need to interface easily with your web application, but also build your tables for you.&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &lt;br /&gt;
&lt;/div&gt;
&lt;strong&gt; &lt;/strong&gt;&lt;strong&gt;A Screen Shot of POG (the PHP Object Generator Tool)&lt;/strong&gt;&lt;/div&gt;
&lt;img vspace=&quot;10&quot; hspace=&quot;5&quot; border=&quot;1&quot; src=&quot;http://www.justicesolutionsllc.com/images/ss_pog_1.jpg&quot; alt=&quot;POG Screen Shot&quot; /&gt;&lt;br /&gt;
&lt;br /&gt;
Once all of your code and tables are built, its a snap to interface with them.&amp;nbsp; Let&apos;s say you have a table which has your user&apos;s vital information in it and you want to retrieve a list of users that have signed up in the past week.&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;lt;?PHP&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; // Create a new instance of our POG class for Users&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; $u = new users();&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp; // Call the GetList Function to bring us back a list of users meeting our criteria&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  $userList = $u-&amp;gt;GetList(array(array(&amp;quot;signupdate&amp;quot;,&amp;quot;&amp;gt;=&amp;quot;,&amp;quot;2008-02-16 00:00:00&amp;quot;)));&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  // Now loop through the results and display them for the end user to view&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  foreach($userList as $user)&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  echo &apos;&amp;lt;p&amp;gt;User Name: &apos; . $user-&amp;gt;username . &apos; &amp;lt;br /&amp;gt;Name: &apos; . $user-&amp;gt;first . &apos; &apos; . $user-&amp;gt;last . &apos;&amp;lt;br /&amp;gt;Signup: &apos; . $user-&amp;gt;signupdate . &apos;&amp;lt;/p&amp;gt;&apos;;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  }&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  ?&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Pretty simple huh?&amp;nbsp; And you can send as many criteria you want in additional arrays all in that same GetList() function.&amp;nbsp; So the speed at which you get results and have the ability to update them are fast and easy.&lt;br /&gt;
&lt;br /&gt;
So take some time to check out POG or send this blog link to your favorite PHP coder.&amp;nbsp; They very well may thank you for it, however knowing most coders they&apos;ll probably say they already knew about it, thanks for the link, and then when people aren&apos;t looking will start to use it all the time.&amp;nbsp; Ha!!&amp;nbsp; Happy coding!&lt;br /&gt;
&lt;br /&gt;
Doug.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;  &amp;nbsp;&amp;nbsp;</description>
	<link>http://www.justicesolutionsllc.com/blogcfm/1/2008/02/57.Getting-the-CRUD-out-in-your-code.cfm</link>
	<dc:date>2008-02-21T08:44:00-07:00</dc:date>
	
	<dc:subject>Web Development, Web Design, Web Consulting, Web Applications, Code Help,Coldfusion, ColdFusion8, Java, Tomcat,ASP.NET,Web Development, Web Consulting, Web Applications,PHP, Code Help</dc:subject>
	</item>
	
	
 	
	</rdf:RDF>
	

