Jump to content


Photo

Render :update Do |page|


  • Please log in to reply
7 replies to this topic

#1 cosmolee

cosmolee

    New Member

  • Members
  • Pip
  • 4 posts

Posted 03 April 2009 - 07:58 PM

On pg 300 appears the code

render :update do |page|
if @seat.save
page.replace_html 'notice', 'seat was successfully booked'
else
page.replace_html 'notice', 'sorry - the seat could not be booked'
end
end
...

But there isn't any explaination of what this 'render :update' block does or why it's required.

Evidently it's needed, but we need an explanation for why the 'render :update' code is there...

One other issue - now we're not seeing the error messages from the model validations. We should have been told how we can now get those to display also, otherwise we now don't get the benefit of the validations, and the user only gets a not-terribly-helpful general error message.

HTH.

#2 mpechner

mpechner

    New Member

  • Members
  • Pip
  • 1 posts

Posted 17 January 2011 - 12:52 PM

YEAH. I've been looking also. All I find are people C&P large sections of the ruby on rails guide. What does this do?


QUOTE (cosmolee @ Apr 3 2009, 07:58 PM) <{POST_SNAPBACK}>
On pg 300 appears the code

render :update do |page|
if @seat.save
page.replace_html 'notice', 'seat was successfully booked'
else
page.replace_html 'notice', 'sorry - the seat could not be booked'
end
end
...

But there isn't any explaination of what this 'render :update' block does or why it's required.

Evidently it's needed, but we need an explanation for why the 'render :update' code is there...

One other issue - now we're not seeing the error messages from the model validations. We should have been told how we can now get those to display also, otherwise we now don't get the benefit of the validations, and the user only gets a not-terribly-helpful general error message.

HTH.



#3 tongclub18

tongclub18

    Active Member

  • Members
  • PipPip
  • 24 posts

Posted 12 December 2014 - 11:27 PM

but we need gclub an explanation for why the 'render.

#4 ned_58690

ned_58690

    New Member

  • Members
  • Pip
  • 6 posts

Posted 18 February 2015 - 05:07 AM

great one sbobet รับพนันกีฬา

Edited by ned_58690, 18 February 2015 - 05:07 AM.


#5 tleonline

tleonline

    Active Member

  • Members
  • PipPipPip
  • 81 posts

Posted 13 June 2015 - 09:35 PM

  Gclub         I like your idea  



#6 casnova

casnova

    New Member

  • Members
  • Pip
  • 6 posts

Posted 18 June 2015 - 08:11 PM

Thanks, in advance, for any info.

Very interesting thanks for sharing. smile.png

 

 

 

 

 

 

 

ที่วางในคาสิโนต่างๆ มาเล่นในคอมพิวเตอร์ หรืออุปกรณ์ต่างๆเช่น มือถือและแท็บเล็ต ได้ที่นี่ royal1688 สล็อต



#7 tleonline

tleonline

    Active Member

  • Members
  • PipPipPip
  • 81 posts

Posted 18 July 2015 - 11:15 PM

Thank you  information  Gclub    


#8 lobterm

lobterm

    Active Member

  • Members
  • PipPip
  • 13 posts

Posted 08 September 2015 - 12:26 AM

thank fo share information






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users