Dynamic fields in forms

Hi all.

I am developing a rails app, more or less a car database.

The interresting part of the model is this :
Country (has_many) <-> (belongs_to) Car maker (has_many) <->
(belongs_to) model etc. But some categories are off this dependency
relationship, as for instance, Vintage, motors,…

The problem I am facing is making a new.rhtml file. More precisely, this
kind of apps needs whether:

  1. not to show the model until the country and the car maker have been
  2. (optional) the upper categories are automatically set when a sub
    category is selected. For example : US - Ford appear when Mustang is
    selected in the form.

I’ve got a couple of books on rails I work on, but non goes on this

I imagine that Ajax will be part of the answer and yet nothing like this
has resulted so far on gg.

Any help most welcome!

Alex Mic

Making myself clearer on the 1) up there :
The fields can or cannot be shown until the upper categories are filled,
but if shown they are blank or unselectable.