I’m also suffering from the ‘undefined local variable or method’ problem
after having update my rails version to 2.0.
All worked fine before and now I get the following error:
undefined local variable or method `start_form_tag’ in —>
<%= start_form_tag %>
What to do? If it can be at all helped I really don’t want to alter the
source code as this is part of the open source package I’m using and I’m
two days away from consignment, so don’t want it to break again if I
update later.
Any help would be much appreciated. Desperately trying to get this
deployed and working!!
I would really like to know the motivation behind getting rid of
start_form_tag and end_form_tag. It seems asinine to me.
My interpretation:
“Let’s make everyone change hundreds of lines of code in dozens of
projects, which all need to be tested now because someone thought there
was a better way to do it.”
I hope that one person just decided to do this by fiat, because if a
committee of people thought this was a good idea, then some of the more
acerbic comments I’ve seen about the Rails gurus starts making a little
more sense.
I won’t argue that it isn’t better: I’m sure you get better ‘forgot to
close the form’ error detection, or form within a form warnings, or
something. But there is really no good reason for it to break every
application out there that uses the old method. Progress for the sake
of progress isn’t.
I would really like to know the motivation behind getting rid of
start_form_tag and end_form_tag. It seems asinine to me.
start_form_tag is still available as the non_block version of form_tag.
This is the only way to do it when the form straddles an erb block,
such as a cache block.
–
We develop, watch us RoR, in numbers too big to ignore.
I would really like to know the motivation behind getting rid of
start_form_tag and end_form_tag. It seems asinine to me.
Because bloating the api isn’t in general a good thing ?
Fred
Which is I think is a pretty lame reason in this instance. I would
think that any reasonable analysis would show that effort required to
maintain a ‘bloated’ api is far and away less than the effort required
fix and test all of the existing code that uses the old method. Leave
it deprecated, so people don’t use it.
Or, make a script that goes in the script folder that automatically
updates the code seemlessly for all deprecated features. If you can’t
do that safely, then don’t drop support. Cause I’m sitting here looking
at 40 rails sites I need to update now, with 500+ start/end_form_tag’s
that I’ve got to go through and update and test. And while freezing
rails may let me put off the pain for some of the sites, at some point
it will have to be done.
And while functional testing, etc. might help automate some of this, the
reality is there are never enough test cases to find everything.
I would really like to know the motivation behind getting rid of
start_form_tag and end_form_tag. It seems asinine to me.
start_form_tag is still available as the non_block version of form_tag.
This is the only way to do it when the form straddles an erb block,
such as a cache block.
–
We develop, watch us RoR, in numbers too big to ignore.
form_tag is also a non-block form of form_tag. Just don’t put a do on
the end and close it with .
i totally agree, this is a ridiculous change. it’s a lot of work for
people for very little gain. i understand that the rails developers want
to have the best framework but at some point they need to realize that
you can spend too much time learning how to be productive, rather than
being productive.
it seems very sophomoric to constantly be rethinking these tags.
It was one change, once. Please get over it. I find the new syntax is
shorter (form_tag vs start_form_tag and end vs end_form_tag) and makes
more sense.