Two forms conflict

In update user form, I want to split password from rest of the form.

In user model I validate it.

I want to have

form 1

  User infos fields

form 2

password and confirm fields.

in php I would do something like if post password is empty, ignore it.

is there something like

if :password 
    do validation

I need the model part, I have the rest.

just need an idea how to split validation in model or how to achieve this.


I hope i did understand you

class User << AR
  validates :password, 
     :lenght => {:between => 3..20}, 
     :confirmation => true,
     :if => { self.password }

Need Your Help

Adobe AIR packaging for Android

java xml air

I seem to be getting this error... I believe I am typing everything correctly:

CFC extends sibling folder

coldfusion cfc application.cfc

I've seen all kinds of solutions for extending cfcs in parent folders with access to parent files or the CF administration, but I have not seen a workable solution to extend a cfc in a "shared"/sib...

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.