Ruby on Rails

Thursday, 4 February 2016

Call DateTime methods in Controller

include ActionView::Helpers::DateHelper
include ActionView::Helpers::NumberHelper

in controller

puts time_ago_in_words(created_at)
Posted by Unknown at 01:37
Email ThisBlogThis!Share to XShare to FacebookShare to Pinterest

No comments:

Post a Comment

Newer Post Older Post Home
Subscribe to: Post Comments (Atom)

Hemant Gupta

Unknown
View my complete profile

Blog Archive

  • ►  2017 (27)
    • ►  October (2)
    • ►  July (21)
    • ►  June (1)
    • ►  May (2)
    • ►  March (1)
  • ▼  2016 (24)
    • ►  October (1)
    • ►  September (1)
    • ►  August (3)
    • ►  July (2)
    • ►  June (1)
    • ►  March (5)
    • ▼  February (5)
      • Codes for less memory usage and fast interacting ...
      • Calendar with Date & Time $(function () {   $('....
      • Call DateTime methods in Controller include Act...
      • Croping Image (Crop Js with rails) 1. Add Crop j...
      • Push code on AWS or Digital Ocean with the use of...
    • ►  January (6)
  • ►  2015 (2)
    • ►  December (2)
Simple theme. Powered by Blogger.