Jump to content

Field Dependencies


ryan

Recommended Posts

Hehe Antti - I seem to recognise the showIf() and requiredIf() calls from somewhere ;)

Oh yes. I remember those irc discussions very well. I actually ended building my own form class, which was conceptually kind of mixture from your work and pw inputfields. Field dependencies are a very powerful concept and it gives great pleasure to define once and see it just work in backend and frontend.

I am actually pretty hooked on that video. Have watched it three times already :)

  • Like 2
Link to comment
Share on other sites

Just out of interest: is there similar features in other cms you guys have used?

There is something that can give you a similar functionality in Textpattern (bot_wtc), but it doesn't translate to the frontend at all.

  • Like 1
Link to comment
Share on other sites

OK, what programme did you use to make that spoof video?! After effects or something? My goodness! Avoine/Antti, thank you very much!!!

As for you Mr Cramer, I don't know what to tell you. Seriously, mate, I can't pick an adjective apt enough. Let's just say that you Sir are one of the best things that has happened to the open source community. Hats off!

cheers

/k

  • Like 8
Link to comment
Share on other sites

I just watched the video at home (damn mobile won't let me). Amazing feature to have!

Watching this I think the "required" need to be more visible or red (asteriks). It can be missed too easily.

And the show animation need to be much quicker! (lol) :P;)

Not can we have also a hideIf() and a makeCoffeeIf()...



I already see the forum full of posts "It doesn't show when..."

  • Like 4
Link to comment
Share on other sites

It's weird how stuff Ryan puts out there always seems to be pretty much rock solid from the beginning. Awesome stuff.

Thanks Ryan, Antti and Avoine!

Edit: how are the variable widths controlled? There have to be many different situations for those fields on one row. When d  they get a new dedicated row if there too many popping up in one row (like the checkbox example with "Pool" and "Children welcome")?

Link to comment
Share on other sites

Edit: how are the variable widths controlled? There have to be many different situations for those fields on one row. When d  they get a new dedicated row if there too many popping up in one row (like the checkbox example with "Pool" and "Children welcome")?

I asked the same question from Ryan. It is pretty clever stuff actually:

So I set it up to do this: after any dependency action occurs, it maximizes the space available to the row of fields. It does this by modifying the last field in the row to consume the available space. There's actually a lot more to it than that (it took an entire day to get it right) but that's the gist of it. It also does this when the page is initially rendered.

There is also a hint why Ryan deliveres rock solid from the beginning :)

  • Like 8
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...