Hi all, for some reason adding the following is doing nothing... .post.hover { background: FAFAFA; I''ve got this in my posts.js coffee file $ -> $(''.post'').hover (event) -> $(this).toggleClass("hover") and my index is <% @posts.each do |post| %> <div class="post"> <strong><%= post.title %></strong> <p><%= post.content %></p> <div class="meta"> <%= link_to time_ago_in_words(post.created_at) + " ago", post %> <span class="admin"> | <%= link_to "Edit", edit_post_path(post) %> | <%= link_to "Delete", post, :confirm => "Are you sure you want to delete this post?", :method => :delete %> | </span> <div> </div> <% end %> Any ideas? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/nLNFo26DvSAJ. For more options, visit https://groups.google.com/groups/opt_out.
On Wed, Oct 31, 2012 at 1:28 AM, wragen22 <bradwrage-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: Hi,> for some reason adding the following is doing nothing...Please note this list is for Rails questions, not HTML/CSS questions.> .post.hover { > background: FAFAFA;FAFAFA is not a valid value for background, and you should be using background-color if you only have a colour just for semantics but to directly address your question, please try doing #fafafa, please also note that the pseudo class for hover is :hover so try .post:hover instead of .post.hover. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/groups/opt_out.
On Wed, Oct 31, 2012 at 2:28 PM, wragen22 <bradwrage-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi all, > for some reason adding the following is doing nothing... > > .post.hover { > background: FAFAFA; > > > I''ve got this in my posts.js coffee file > > $ -> > $(''.post'').hover (event) -> > $(this).toggleClass("hover") > > > and my index is > > <% @posts.each do |post| %> > <div class="post"> > <strong><%= post.title %></strong> > <p><%= post.content %></p> > <div class="meta"> > <%= link_to time_ago_in_words(post.created_at) + " ago", post %> > <span class="admin"> > | <%= link_to "Edit", edit_post_path(post) %> | > <%= link_to "Delete", post, :confirm => "Are you sure you want to delete > this post?", :method => :delete %> | > </span> > <div> > </div> > > <% end %> > > > > Any ideas? >can you check it via firebug or chrome''s developer tools and check if the class really toggles (i''m pretty it does). if you can''t see the changes maybe the change isn''t that obvious. FAFAFA is very close to white so if you have a white background, you may not notice the change.> > > > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to > rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > https://groups.google.com/d/msg/rubyonrails-talk/-/nLNFo26DvSAJ. > For more options, visit https://groups.google.com/groups/opt_out. > > >-- ------------------------------------------------------------- visit my blog at http://jimlabs.heroku.com -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/groups/opt_out.
it not work. background: FAFAFA; it work. background: #FAFAFA; 2012/10/31 Jim Ruther Nill <jvnill-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>> > > On Wed, Oct 31, 2012 at 2:28 PM, wragen22 <bradwrage-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > >> Hi all, >> for some reason adding the following is doing nothing... >> >> .post.hover { >> background: FAFAFA; >> >> >> I''ve got this in my posts.js coffee file >> >> $ -> >> $(''.post'').hover (event) -> >> $(this).toggleClass("hover") >> >> >> and my index is >> >> <% @posts.each do |post| %> >> <div class="post"> >> <strong><%= post.title %></strong> >> <p><%= post.content %></p> >> <div class="meta"> >> <%= link_to time_ago_in_words(post.created_at) + " ago", post %> >> <span class="admin"> >> | <%= link_to "Edit", edit_post_path(post) %> | >> <%= link_to "Delete", post, :confirm => "Are you sure you want to >> delete this post?", :method => :delete %> | >> </span> >> <div> >> </div> >> >> <% end %> >> >> >> >> Any ideas? >> > > can you check it via firebug or chrome''s developer tools and check if the > class really toggles (i''m pretty it does). if you can''t > see the changes maybe the change isn''t that obvious. FAFAFA is very close > to white so if you have a white background, you > may not notice the change. > > >> >> >> >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Ruby on Rails: Talk" group. >> To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> To unsubscribe from this group, send email to >> rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org >> To view this discussion on the web visit >> https://groups.google.com/d/msg/rubyonrails-talk/-/nLNFo26DvSAJ. >> For more options, visit https://groups.google.com/groups/opt_out. >> >> >> > > > > -- > ------------------------------------------------------------- > visit my blog at http://jimlabs.heroku.com > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Talk" group. > To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To unsubscribe from this group, send email to > rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > For more options, visit https://groups.google.com/groups/opt_out. > > >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/groups/opt_out.
Il 31/10/12 07:28, wragen22 ha scritto:> Hi all, > for some reason adding the following is doing nothing... > > .post.hover { > background: FAFAFA; > Any ideas?"background: #FAFAFA" ?? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/groups/opt_out.
That was it.... for some reason kept overlooking that I didn''t have the #.. Sorry all. On Tuesday, October 30, 2012 11:35:01 PM UTC-7, Jordon Bedwell wrote:> > On Wed, Oct 31, 2012 at 1:28 AM, wragen22 <brad...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org <javascript:>> > wrote: > Hi, > > > for some reason adding the following is doing nothing... > > Please note this list is for Rails questions, not HTML/CSS questions. > > > .post.hover { > > background: FAFAFA; > > FAFAFA is not a valid value for background, and you should be using > background-color if you only have a colour just for semantics but to > directly address your question, please try doing #fafafa, please also > note that the pseudo class for hover is :hover so try .post:hover > instead of .post.hover. >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msg/rubyonrails-talk/-/87wjlGAzcywJ. For more options, visit https://groups.google.com/groups/opt_out.