Archive for September, 2007

Sep
17
Flex Builder 2.0.1 (Win) Installing Subversion


Posted: 17th September 2007
Tags: ,
Posted in Flex
Comments: 5 Comments »

I thought I would share a quick overview of using Subclipse on Windows and one particular step that took a lot of digging around to find that lets you install it. On Windows Flex Builder 2 uses the Eclipse 3.2.x platform which is not compatible with the latests release of Subversion. To install subversion, you need to install from the 1.x branch using the following url:

http://subclipse.tigris.org/update_1.0.x

In Flex Builder, select Software Updates -> Find and Install from the Help Menu. You will need to add a new remote update site to install Subeclipse from, by clicking New Remote Site, giving it the name Subeclipse and entering the update URL above.

Click Finish, and after a little updating you will be asked to select what to install, on selecting Subeclipse you may get the following error:

Subclipse (1.2.0) requires plug-in org.eclipse.core.resources (3.2.0), or later version.
The key here, is to unselect: Show the latest version of a feature only. as shown below:

 

With this done, you can select the latest 1.x version of subeclipse and it should install fine.

If you are behind a proxy, you will need to add the following lines to your servers file, located in C:\\Document and Settings\\<username>\\Application Data\\Subversion :

  1. http-proxy-host = <proxy server address>
  2. http-proxy-port = <proxy server port>
  3. http-proxy-username = <proxy username>
  4. http-proxy-password = <proxy password>

You can now checkout a project by New -> Other from the FIle menu and selecting SVN -> Checkout Project from SVN





Sep
6
Live Validation - Custom Validator


Posted: 6th September 2007
Tags: , , , ,
Posted in Javascript
Comments: 3 Comments »

Following my article earlier today on Live Validation, I have had a response from Alec regarding how to create a custom validator to use with his Live Validation framework.

Having asked if a custom Validator could be passed in the .Now() function Alec had the following to say:

In regards to passing a custom validation method into the .now method, it will not \’91create\’92 the validation method as such, but will accept one you have made, as long as your custom validation method takes a value as the first argument, and throws a Validate.Error exception when it fails (in order to pass on the failure message made easier by using Validate.fail), and true if it passes. For example:

  1. Validate.Example = function(value, paramsObj)\{
  2. // the following sets up default options and overides them with those passed in
  3. var params = Object.extend(\{
  4. failureMessage: Default failre message goes in here!
  5. \}, paramsObj || \{\});
  6. // here you would check the value you wish to validate (the one passed in), against some expected value
  7. // if it fails then use the Validate.fail method will throw an exception containing the failure message
  8. if(value != My expected value) Validate.fail(params.failureMessage);
  9. // if the script reaches this far then no exception has been thrown, so the validation passed
  10. return true;
  11. \}

Alec clarified: “…if you take a look at some of the included validation methods they contain calls to some of the other ones internally, as they will throw exceptions and halt proceedings if they fail, so act in much the same way as the simple one we have above. Validate.Email is a simple example of this and can be easily adapted to make a reusable postcode format validation for instance.”

Following Alec’s example above, you can easily then use the validator using the following:

  1. Validate.now(Validate.Example(), value_to_validate, \{options\})

Using a custom validator opens up many possibilities such as making an AJAX call to the server to check the uniqueness of a username or password.

For more information:

Live Validation

Documentation for Validate.now()





Sep
6
Live Validation - Cross Platform, Rails style validation on the client.


Posted: 6th September 2007
Tags: , , , , ,
Posted in Javascript, Ruby on Rails, Usability
Comments: 1 Comment »

I came across a great new validation library the other day which I wanted to share with you all. Live Validation by Alec Hill is a cross-platform client-side JavaScript validation framework which provides real-time feedback to the user as they type.

 

val2


val1

Read the rest of this article »





Sep
5
Tktit.com - Running on Ruby on Rails


Posted: 5th September 2007
Tags: , ,
Posted in Ruby on Rails
Comments: No Comments »

TktIt.com is a self service ticketing solution for the social networking generation. It allows bands, clubs, companies etc to sell tickets, places to any event or activity they may run, for example gigs, training events, sports activities, festivals, exhibitions etc. Tickets can be sold directly from the users websites and payment is made directly to PayPal, in addition users can track their ticket sales directly from TktIt.

 

This was my first full development outing into the realms of Ruby on Rails which has been an inspirational and educating experience and I will be posting several articles in the near future on some of the techniques I used such as using script.aculo.us to produce a similar color selector to the one I did in .Net/JQuery.





Sep
3
Let the migration begin…


Posted: 3rd September 2007
Tags: , , , , , ,
Posted in Misc..
Comments: 1 Comment »

With my new focus on Rails, I have decided to move my blog to the excellent Mephisto Blog, from now on I will also be focusing my articles a little more towards not only Ruby on Rails but also Web Development, Web Design, UI Design and Javascript.

I have also used this opportunity to streamline the design of the site, there were a few things that didn’t work quite as they should on the old site and will have been improved along with a revamp of the colour scheme.

As I write this www.miletbaker.com still points to the old blog until all the content has been migrated and I have configured Apache to relay requests to my old urls to their new location. Once this is complete that will also be migrated across.

Also look out for the Jive (Javascript Input Validation Engine) for Prototype which I am currently working on with George which will feature real time inline validation as well as validation calls via Ajax and a Rails plug in. Check out Live Validation.