[Rails] Bug on blog - number of views not showing in ruby on rails app.below is the code used

2015-03-09 Thread Sailatha Kashamoni
app/assets/javascripts/blog/show.js.erb: $(document).ready(logView); function logView() { var id = $('div.blog_post').data('id'); InternalAnalytics.postEvent(id, 'view'); } app/views/blog/show.html.erb:  <%= @blog_post.view_count

[Rails] how to group posts by month and year,archive display

2015-02-24 Thread Sailatha Kashamoni
if i click on month i want to display only that months blog posts,this is an existing code which is working fine for few months not for all,where am i doing wrong ,should i change the code.can any one help me out.and also i want the month and date to display in reverse ,recent on top.like AR

[Rails] welcome mailer not working properly,mail is going every time a user logs in to site

2015-02-18 Thread Sailatha Kashamoni
welcome mail is going every time a user logs in to site,i only want it to go once when user signed up app/controllers/user_mailer.rb-- class UserMailer < ActionMailer::Base default from: "myemai...@gmail.com" def registration_confirmation(user) UserMailer.registration_confirmation(@user)

[Rails] loging out of site if navigatinhg to other pages in ruby on rails app

2015-02-18 Thread Sailatha Kashamoni
I have an issue when i am loging in to site after clicking on other menu tabs it is automatically loging out and if i wait for few minutes refresh and then login tabs are working fine.If i logout and login again and i click on other tabs geting loged out. I am not understanding where i need to