top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

blogit gem dates posts a month ahead of today (rails)?

+1 vote
248 views

Anyone can help me figure out why the blogit gem dates posts a month ahead of today?

posted Feb 27, 2018 by Sidharth

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button

Similar Questions
+3 votes

I want to build a website like Mediafire where User can upload and download media files (Audio,Video,Images(All Formats)) and from already answered questions I have come through with a gem called paperclip.

so my question now is how do i integrate paperclip with devise(in order to build sign up form) and link my web pages with them ?

+1 vote

Rails seems to have a whole whack of them and I'm not sure which ones match my requirements. The library must:

  • be fully themeable; the overall layout is going to be made from scratch
  • allow custom content for pages (i.e. a developer-made page)
  • allow defining of different types of posts with different fields/data
  • support image upload for at least pages and preferably posts as well
  • be relatively easy to extract post content outside the CMS (e.g. for use in sending an e-mail digest)

Preferably it should:
- Be compatible with Rails 4
- allow individual pages to be user-edited with HTML/CSS after they've been created

Can anyone recommend one for me?

0 votes

I did the following to implement cron jobs in rails 3 using a "runner" instead of a rake task.

STEP 1: I have whenever gem installed and scheduler.rb has following:
set :environment, development set :output, { :error => "/log/error.log", :standard => "/log/cron.log" } every 1.minute do runner "Cron.sendAutomaticsSMS()" end

STEP 2:
Cron file: lib/cron.rb
class Cron $ # End Whenever generated tasks for: /code/rails_projects/new/bhk/bigbhk-dev/

STEP 3:
Running cron job:
$sudo service cron restart cron stop/waiting cron start/running, process 4027

This does not do anything. I wait for operation as defined in sendAutomaticsSMS() method to execute but the cron doesnt even enter this method.

I dont see any error in log/development.log and there is no log/cron.log in my rails app.

+1 vote

I'm looking for a function, gem, etc. that will help to unify dates as they come in different formats. If the date comes in (1/2/2012,2012-01-02,01-02-2012,20120102,01022012, etc.)

it would be nice to have it come out 2012-01-02. I've searched for a few days and only find ways to convert this format to that format. I might be using the wrong search terms and this may have already been addressed, if so, I apologize. In my previous PERL app I wrote a long If Else type converter that would test the date and then convert it in a specific order but I'm sure someone has solved it better then I could.

...