Displaying 20 results from an estimated 9000 matches similar to: "Paperclip + asset_host uploading to external URL"
2009 Sep 26
0
Paperclip with external url and asset_host?
Hi,
I''m trying to get Paperclip to work with asset_host and have totally
failed to do so.
The idea is to use asset_host to specify the url that I want to use for
my image hosting (www.unlimitedwebhosting.co.uk) so that link helpers
will use the image host location instead of the local file system.
This works really well and in truth I''m totaly blown away by the power
and
2009 Apr 16
6
Using Paperclip::Processor and RMagick to sharpen my thumbnails
Hi, I''m brand new to RMagick (and pretty new to Rails for that
matter!). Right now, site owners are allowed to upload product and
ingredient photos to the website. Everything works great, ingredients
are sized down and proportioned correctly...the problem is that the
resulting images are so blurry! So I''ve been doing some research and
it looks like Paperclip::Processor may be the
2009 Apr 08
1
Having issues with paperclip, S3, and Aptana Cloud
I''m using paperclip to allow users to upload an "avatar" (pretty
standard). The problem is, it works just fine in development, but when I
deploy the app, it will only upload the original image to S3, but not
the resized images. I''ve looked all over, and I suspect it may be a
problem with rmagick (although, I''m not sure about that), I checked the
list and
2008 Mar 20
2
Anyone having problems with asset_host not getting set up right?
Hey All,
I think I found a bug but I would be suprised since it would cause major
problems.
We setup the asset_host in init.rb with:
if File.exist?(facebook_config)
FACEBOOKER = YAML.load_file(facebook_config)[RAILS_ENV]
ENV[''FACEBOOK_API_KEY''] = FACEBOOKER[''api_key'']
ENV[''FACEBOOK_SECRET_KEY''] =
2011 Jan 08
1
Paperclip custom Interpolation in url
Folks,
I have a simple model hierarchy (reduced to example as below)
class Post < ActiveRecord::Base
has_many :comments
end
class Comment < ActiveRecord::Base
belongs_to :post
has_attached_file :photo,
# :url => "/assets/class_cal/<original post
date>/:id/:style/:basename.:extension"
:url =>
2011 Sep 02
1
can't compile assets on prod due to asset_host config && SSL requirement
My production asset_host config looks like this:
config.action_controller.asset_host = Proc.new { |source, request|
if request.ssl?
"#{request.protocol}#{request.host_with_port}"
else
"#{request.protocol}assets#{(source.length % 4) +
1}.example.com"
end
}
...which is more or less straight from the docs:
2009 Sep 03
12
paperclip is not saving the files
Hi all,
I''ve installed paperclips but
paperclip is not saving the files
my model has
has_attached_file :attachment,:styles => { :medium => "300x300>",
:thumb => "100x100>" }
and i have db migration as
class AddAttachmentToPolicies < ActiveRecord::Migration
def self.up
add_column :policies,
2008 Jun 13
1
asset_host and ssl pages problem
I am configuring assets hosts for our site but am running into problems
when navigating to an https page. Basically the server is trying to pull
the assests out on https:// rather than http:/ but i do not have https
configured on the assets server. I have dug around a bit and found this
bit of code which should when a page is https:// serve the assests from
the app server and when it is not https
2011 Feb 15
0
Question on Paperclip paths/urls
Note that if I use the default Paperclip :path (i.e. not setting this
attribute and files going to public/system), everything is fine. This
question is to do with setting an alternative path.
I have a model using paperclip for a file with a custom path:
has_attached_file :tu_raw_bill_csv,
:path =>
2010 Aug 05
5
asset_host and ActionMailer
After digging through the rails code to figure out why my asset_host
wasn''t getting applied to emails, I realized that it''s because the
config object in the context of a mailer is config.action_mailer and
not config.action_controller. This means you need to set asset host
separately for emails, as config.action_mailer.asset_host.
Should this be considered a bug? Is it really
2011 Mar 08
1
Bulk file upload in rails through paperclip
Hi all,
I have a rails application running and in my application am
uploading some very large file (SAY 2GB) ,as of now am doing one file at
time ,but i would like to do bulk file upload in my appliaction ,I came
to know about Paperclip as one of plug-in for bulk file upload....
But is it possible to have bulk upload of very
large file (SAY 2GB) through
2012 Jul 11
0
Paperclip duplicates uploaded images
Hi,
I''m using rails3 with paperclip to upload multiple images as in
http://www.emersonlackey.com/article/paperclip-with-rails-3
The problem is, every image is duplicated upon create/update, that is,
saved twice to the db (and afterwards displayed twice in the view as a
result)
In other pages, and even in the same page as well, I also have a single
upload file, which works fine.
As
2009 Apr 01
1
Paperclip - how to display images that were not uploaded?
I''m using Paperclip plugin to store images in my application.
In the database I have columns like: image_file_name,
image_content_type, image_file_size.
When I upload an image via form, everything works well. But when I put
filename directly into the database and place properly named image in
the place expected, the image doesn''t appear on the webpage. Even if I
just rename
2010 Feb 27
2
Paperclip upload fails sometimes
Hello,
My application is a rails-postgresql application which uses paperclip
("ImageMagick-6.5.4-10-Q16-windows-dll.exe" installed on WinXP).
The application''s image uploading feature works consistently right on
my development PC, however it is inconsistent on a different server PC
(used for deployment).
There are certain observations below.
a) For the first time the file
2011 Jun 03
0
valums ajax file upload + paperclip in Rails 2.x Options
Hello all,
I am trying to setup ajax file upload + ajax display in Rails 2.0.2
for project specific purposes. I am using valums ajax file upload
plugin(https://github.com/valums/file-uploader). Using this plugin, I
have been able to upload these files working in my javascript and I
am
able to pass them as params.
I have found a blog in which they have shown how to combine this
plugin with
2009 Aug 16
0
Can't upload pictures using Paperclip due to weird error
I''m developing in Ubuntu, already have installed ImageScience and I''m
getting this error everytime I try to upload a picture:
[paperclip] An error was received while processing:
#<Paperclip::NotIdentifiedByImageMagickError: /tmp/
stream20090816-10096-ddupoc-0 is not recognized by the ''identify''
command.>
Can someone guide me on a solution?
Thanks
2006 Aug 15
0
Using config.action_controller.asset_host with ActionController::AbstractRequest.relative_url_root
I''m looking for some help with an issue I''m having using an external
asset host. I''ve got the lines below in my environments/development.rb
file.
# Enable serving of images, stylesheets, and javascripts from an asset server
config.action_controller.asset_host = "http://assets.example.com"
#make rails think it lives in /app
2007 Dec 16
0
Specifying asset hosts via a proc (ActionController::Base.asset_host)
Hi all,
I just submitted a patch that would allow you to pass a proc to
ActionController::Base.asset_host rather than just using a %d
wildcard (e.g. assets%d.example.com). Basically this frees you from
the hard-coded assumption that you have 4 hosts numbered 0-3 and also
allows you to do smarter things depending on the asset (e.g. images
from a particular domain, stylesheets from another). The
2010 Feb 15
4
Changing the :path and :url options of has_attached_file in paperclip
Hello,
I am using the paperclip plugin to upload images and it works
absolutely fine.
I intend to save my uploaded images to C:\Application_name\public
folder. Accordingly, with some study over the i-net, I changed
the :path option of has_attached_file to -
:path => "C:/Application_name/
public/:class/:attachment/:id/:style_:basename.:extension"
Now, the files are being saved to
2009 Jul 07
2
paperclip unit testing
Hi,
Rails 2.3.2, paperclip 2.2.9.2
How can I unit test my model that has a paperclip attachment?
I add to my model:
--- CODE START ---
has_attached_file :image, :default_url => ''''
attr_protected :image_file_name, :image_content_type, :image_image_size
--- CODE END ---
Than I type a UNIT test:
--- CODE START ---
foo=FooModel.new({:image =>