2010-11-05から1日間の記事一覧
Railsの画像添付のためのプラグイン「Paperclip」を使った場合に、モデルで以下のように宣言する。 class User < ActiveRecord::Base has_attached_file :avatar, :styles => { :medium => "300x300>", :thumb => "100x100>" } end 何も難しいところはないけ…
Railsの画像添付のためのプラグイン「Paperclip」を使った場合に、モデルで以下のように宣言する。 class User < ActiveRecord::Base has_attached_file :avatar, :styles => { :medium => "300x300>", :thumb => "100x100>" } end 何も難しいところはないけ…