Dear all
In my above code all the department gets loaded before the form gets
loaded.
I want to render my partial after the document is loaded completely.
i am not sure how to do this..
Kindly help me out
The short answer is, you can’t - all <% … %> code is run, then the
page is
displayed.
The long answer is, you could, but there’s probably a better solution.
The
way you could do this is to add an event to the document’s onload event How to call scripts - Unobtrusive Javascript that
does an ajax call to the controller that renders the partial.
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.