Forum: Ruby on Rails include once in partial

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.
Gábor Sebestyén (Guest)
on 2006-03-16 18:25
(Received via mailing list)
Hi!

I have to include javascript code into my partial but I should do it
once. How can I do that?
What is the rule of thumb?

Gábor
Craig W. (Guest)
on 2006-03-16 18:34
(Received via mailing list)
On Thu, 2006-03-16 at 17:19 +0100, Gábor Sebestyén wrote:
> Hi!
>
> I have to include javascript code into my partial but I should do it
> once. How can I do that?
> What is the rule of thumb?
----
you would put it into whichever file has the
<html>
  <head>
    <body>
    </body>
  </head>
<html>

code which is generally the 'layout' file for the controller.

Craig
This topic is locked and can not be replied to.