11155
(-- --)
December 16, 2010, 6:06pm
1
What is the rails way to do this? I'm using Rails 2.3.10
Error is:
undefined local variable or method `favicon_link_tag' for
#<ActionView::Base:0xb6e57034>
This module is needed I guess:
ActionView::Helpers::AssetTagHelper
Here is what I did:
app/views/layouts/application.html.haml
!!! 5
%html
%head
%title App1 - Rails Way
= favicon_link_tag
%body
#content
= yield
11155
(-- --)
December 16, 2010, 6:09pm
2
Craig Anderson wrote in post #968905:
What is the rails way to do this? I'm using Rails 2.3.10
Error is:
undefined local variable or method `favicon_link_tag' for
#<ActionView::Base:0xb6e57034>
Where would you expect favicon_link_tag to be defined? The error
message is accurate.
This module is needed I guess:
ActionView::Helpers::AssetTagHelper
Here is what I did:
app/views/layouts/application.html.haml
!!! 5
%html
%head
%title App1 - Rails Way
= favicon_link_tag
%body
#content
= yield
Best,
11155
(-- --)
December 16, 2010, 7:07pm
3
I'm just learning rails and trying to learn the rails way. I expected
that module ActionView::Helpers::AssetTagHelper
would be available in the view.
Marnen Laibow-Koser wrote in post #968906:
11155
(-- --)
December 16, 2010, 7:08pm
4
Please don't top-post.
Craig Anderson wrote in post #968919:
I'm just learning rails and trying to learn the rails way. I expected
that module ActionView::Helpers::AssetTagHelper
would be available in the view.
It is. But favicon_link_tag is not defined in there, at least according
to the docs. Where did you get the idea that this method even exists?
Best,
11155
(-- --)
December 16, 2010, 7:15pm
5
What is top-post?
Marnen Laibow-Koser wrote in post #968920:
11155
(-- --)
December 16, 2010, 7:16pm
6
11155
(-- --)
December 16, 2010, 7:29pm
7
Again: please don't top-post! Insert your replies inline as I have
done.
Craig Anderson wrote in post #968923:
favicon_link_tag (ActionView::Helpers::AssetTagHelper) - APIdock
Read the text in the big blue box.
Best,
11155
(-- --)
December 16, 2010, 7:39pm
8
Marnen Laibow-Koser wrote in post #968924:
Again: please don't top-post! Insert your replies inline as I have
done.
Craig Anderson wrote in post #968923:
favicon_link_tag (ActionView::Helpers::AssetTagHelper) - APIdock
Read the text in the big blue box.
Alright, I've now learned that the method was introduced in Rails 3.0.0.
Your responses strike me as rude, but I have learned somthing.
11155
(-- --)
December 16, 2010, 7:48pm
9
Craig Anderson wrote in post #968926:
Marnen Laibow-Koser wrote in post #968924:
Again: please don't top-post! Insert your replies inline as I have
done.
Craig Anderson wrote in post #968923:
favicon_link_tag (ActionView::Helpers::AssetTagHelper) - APIdock
Read the text in the big blue box.
Alright, I've now learned that the method was introduced in Rails 3.0.0.
Your responses strike me as rude, but I have learned somthing.
They were not meant to be rude. I was merely trying to figure out why
you would expect an apparently nonexistent method to work. I didn't
know that APIdock had that "helpful" (?) feature of displaying methods
that don't actually exist...
BTW, I recommend http://www.railsbrain.com for Rails docs.
Best,
hassan
(Hassan Schroeder)
December 16, 2010, 8:20pm
10
? Good for historical reference, I guess, but the most recent version
there is 2.3.2 ...
11155
(-- --)
December 16, 2010, 8:34pm
11
Hassan Schroeder wrote in post #968935:
BTW, I recommend http://www.railsbrain.com for Rails docs.
? Good for historical reference, I guess, but the most recent version
there is 2.3.2 ...
Aaaugh! Mistyped. I meant http://www.railsapi.com . Sorry!
--
Hassan Schroeder ------------------------ hassan.schroeder@gmail.com
twitter: @hassan
Best,
11155
(-- --)
December 17, 2010, 10:37pm
12
Marnen Laibow-Koser wrote in post #968937:
Aaaugh! Mistyped. I meant http://www.railsapi.com . Sorry!
'build your custom package' at railsapi.com looks like my new goto Rails
documentation.
Also, I was really not understanding the version information on
favicon_link_tag and that had me confused and frustrated. Thanks for
your help.