Forum: Ruby on Rails best practise

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
2101d75ccd71c5dfb984991a7ba53b9b?d=identicon&s=25 harm (Guest)
on 2007-07-15 20:53
(Received via mailing list)
Dear all,

I am making some sort of questioning system in which people and answer
different questions (with a limited answer set). These questions can
have comments but I will not directly show people that, think of blog
post with associated comments.
A page displays two or three things: 1) the next question unanswered,
2) the previous question with a tally of the given answers and 3)
possibly the comments on that previous question.
Now I made and URL much like:
http://localhost:3000/scribe/show?question=17&answ...

But this breaks down if I have a form where people can leave their own
comment and the new comment fails validation. Normally in the
controller I would write; render :action => new_question (or something
like that). But that does not work now because showing comments is
coded in show_comments=true. And I need to show on thesame page the
previous and next question as well.
Am I still making sense?
How would you solve this?

With kind regards,
Harm
This topic is locked and can not be replied to.