NameError (uninitialized constant Mime::XLS):

Viewed 2769

I am getting the problem on my Ubuntu server, but it works on my local machine completely without any error.

ruby version 1.9.3

rails version 3.2.13

I have done the following configurations:

application.rb

require File.expand_path('../boot', __FILE__)
require 'csv'
require 'rails/all'

/initializers/mime_types.rb

Mime::Type.register "application/xls", :xls
#Mime::Type.register "application/vnd.ms-excel", :xls

I have got the reference from here

1 Answers
Related