Posted by Doug Hays on the 26th of November, 2008 at 11:02 pm under Coding.    This post has 319 comments.

In doing some research on ASP.NET MVC, Phil Haack mentioned a pattern that I had never heard of but love to use: PRG -or- Post, Redirect, Get.

Take a web form for example.  When the user clicks Save, the data is sent via POST back to the web application.  The web app saves the data to the database and then redirects the user to the next page within the application.  The user’s browser then requests that page via GET.  

The beauty of this pattern is made very clear by Phil.  This will eliminate the possibly confusing “Are you sure you want to resubmit this form data?” browser message.  But, for me, an even better reason is that it eliminates possible data issues when the browser re-posts the data after that refresh.  

Either way, I’m glad to have learned the name of this pattern and even more thankful that my use of it has been validated.

Posted by Doug Hays on the 23rd of October, 2008 at 3:18 pm under EastFace Software.    This post has 6 comments.

We are excited to announce that we now have a website to show off some of our handiwork:

http://www.eastfacesoftware.com

I guess it was ironic that a company that builds web applications had a website with only a logo and no content. But we did not really have a strong reason to create one. We have no need to actively market ourselves as we remain plenty busy (and are thankful for this). But, when new opportunities came by, we had nothing to give to folks to give them a feel for what we do, who we are and that we are legitimate.

Well, the site may not answer all of those concerns, but 2-for-3 isn’t bad.

Posted by Doug Hays on the 25th of September, 2008 at 12:51 pm under Flex.    This post has no comments.

I just ran into an interesting issue with ObjectUtil and its handy Copy function.  After performing a copy, I was attempting to cast the resulting object and the overall result was null:

oldField = new Field();
newField = ObjectUtil.copy(oldField) as Field;
//newField is null 

Thankfully, a quick trip to Google helped me find the solution 

I added this to my Field class:

[RemoteClass(alias="com.eastfacesoftware.Field")]
public class Field {...}

and I was a step further.  My last hurdle was using the Copy function on subclasses of Field.  As you might guess, you need to define the RemoteClass metadata on every class that you intend to copy. After I did this, ObjectUtil was again on my list of favorite ActionScript classes.

The reason?  ObjectUtil.Copy() uses AMF to serialize and de-serialize the original object to create the copy.  If AMF doesn’t have specific knowledge of your class, it will not return an object that will cast properly.

Thanks to Darron Schall for this helpful tip.

Posted by Doug Hays on the 16th of May, 2008 at 10:18 am under Software.    This post has no comments.

A client of mine, PositiveWare, just released version 2.2 of their project, time and billing management system. This is exciting to me for a couple of reasons. First off, I had a fairly large role in the development of the release and it always feels good to get something of this magnitude out to the users. Secondly, this even further aligns PositiveWare with the way its clients run their businesses.

The release adds functionality that allows an existing PositiveWare client to subcontract projects and tasks out to other PositiveWare clients. It means that, as a PositiveWare client, you will interact with your subcontractors the same way you do with your employees. No more wondering about what it is your subcontractors are doing.

As a PositiveWare client and as someone who occasionally uses subcontractors, this is very exciting.

Posted by Doug Hays on the 29th of April, 2008 at 11:20 am under CMS, CakePHP and MySQL.    This post has 910 comments.

We have written a very basic CMS system (just like everyone else has) that we use on a handful of our clients’ websites. We wanted a CMS system that was:

  • Easy to deploy
  • Simple to re-skin when provided an HTML/CSS design
  • Search Engine Friendly
  • Easy enough that non-technical people could administer the content of the site
  • Lightweight enough so that the system could be the foundation of a larger application or website
  • Built using CakePHP and MySQL

After looking around the web for 5 minutes, and not finding anything, we decided to build it ourselves. So, here it is, Dingus CMS.

In order to install and use Dingus CMS:

  1. You’ll need a basic PHP/MySQL/Apache environment. (Note: PHP 5 is recommended and Apache needs mod_rewrite)
  2. Download the source.
  3. Extract the source into the document root of your website. Note that the app, cake, docs, etc… directories should be at the root of your site
  4. Configure the database connection in app/config/database.php
  5. Run the SQL in sql/dingus_cms_db_setup.sql
  6. Go to http://localhost and you should be up and running!

Note that Dingus CMS comes with built-in search and site map pages available at http://localhost/search.html and http://localhost/site-map.html

Finally, you may be wondering what a Dingus is. You’ll have to stay tuned for a full explanation.