Displaying 20 results from an estimated 3000 matches similar to: "Doing destructive actions with a GET request"
2013 Sep 18
2
Accessing model attributes in ActiveSupport::Concern module
I have some models which share the same functionality just on other paths.
So I decided to put these methods in a module and set the path in the
model. My problem is that I''m not able to access the attribute in my module.
my model:
class Job < ActiveRecord::Base
include ImageModel
image_dir = "jobs"end
my module:
module ImageModel
extend ActiveSupport::Concern
2006 Mar 31
4
How to have a form within a form?
Say I am building a blogging platform, and I want to allow users to be
able to add an avatar without leaving the page, when they''re writing a
post. I need the avatar information to be included in the form for the
post. So for example, after a user adds a new avatar while writing a
new blog post, it would be available to be selected as the avatar to be
used for that post. What is
2011 Aug 07
2
PROBLEM WITH PAPERCLIP
hello,
i am trying to upload a image file ...using paperclip in rails 3
i did as follows
1. In gemfile => included gem paperclip
2.In config/environments /development.rb => Paperclip.options[:command_path]
= "/usr/bin/" (convert path)
3.created a controller *picusers *and defined => def create
@picuser = Picuser.create(params[:picuser])
end
4.created a model *picuser
2010 Jun 09
4
rails+sinatra sent image
Hi!
I have simple rails application - users with name and avatar and in
sinatra I want to create new user.
form for new user
<form action="/users/create" enctype="multipart/form-data"
method="post">
<p>
<label for="name">Name: </label>
<input type="text" id="name" name="user[name]" >
2007 Aug 14
2
AssociationTypeMismatch with RSpec 1.0.8, autotest running with drb
Before I chalk this up as a bug and report it, I just want to make sure I''m not
doing something silly.
Running ZenTest''s autotest on OS 10.4.10 with RSpec 1.0.8, drb, produces the
following failed test:
ActiveRecord::AssociationTypeMismatch in ''User should create an avatar with
uploaded_data''
Avatar expected, got Avatar
This only happens with that exact
2006 Mar 08
6
best practices for handling uploaded images and capistrano
Quick question: I am going to use the file_column plugin to manage uploading
thumbnails. By default the images are stored in the public/ dir of the
rails project. The problem I see is that when capistrano redeploys a new
build and symlinks it in none of the images will be in the new public/
dir... Does anyone have a solution for this?
Thanks,
Zack
-------------- next part --------------
An
2005 Dec 25
3
SQLite primary key schema
So after successfully getting the test SQLite db to run from memory, I
tried running some tests but found that somewhere in the schema
translation from Postgres (my devel database) and SQLite Rails fails
to properly set the ''id'' column, which breaks all kinds of things.
Take as an example my ''users'' table. In Postgres the schema is
(generated with pgAdmin III):
2001 Feb 12
2
patches for UnixWare v2.x pty (misc.c,configure.in)
I have attached two patches to the current source code. The first
addresses the pty problems with UnixWare 2.x with connecting with
SSH2. It sets the sigaction to SA_RESTART. This fixes UnixWare v2.x,
but haven't heard any feedback as to effects on other OS'.
The first patch is against misc.c.
The second patch adds a section "*-*-sysv4.2uw2*" to configure to
set the
2011 Apr 21
2
Rails 2.3.11 and carrierwave, can't find generator
I added carrierwave to a 2.3.11 app that I have updated with Bundler.
I just tried to use the following:
script/generate uploader Avatar
The following error is coming back:
NOTE: Gem.cache is deprecated, use Gem::source_index. It will be
removed on or after 2011-08-01.
Gem.cache called from /Library/Ruby/Gems/1.8/gems/rails-2.3.11/lib/
rails_generator/lookup.rb:234
.
Couldn''t find
2018 Aug 28
2
IceCast - Is it still being developed?
Hello! I was just wondering if the IceCast platform was still being
actively developed?
Thank you,
Jason
--
_DEFINE YOUR DESTINY IN ULTIMA GENESIS: CALL OF THE AVATAR [1]! PLAY FOR
FREE TODAY._
FOLLOW US ON SOCIAL MEDIA!
[2] [3]
Links:
------
[1] https://titanx.games
[2] https://www.facebook.com/titanxgames/
[3] https://twitter.com/intent/user?screen_name=_TitanXGames
--------------
2008 Sep 02
4
Attachment_fu, Paperclip, & S3
For various reasons, I made a git branch and installed Paperclip in
place of attachment_fu. Paperclip works great except that images seem to
have lost some quality; edges have gone a little too jaggy to be able to
drop attachment_fu just yet. After a post on the Paperclip Google Group,
someone suggested the :convert_options could be passed additional
attributes, like ''quality'',
2018 Aug 29
2
IceCast - Is it still being developed?
Is this the version of "Karl Heyes" with extra features? If not, there
can I find the "Karl Heyes"-version?
Am 28.08.2018 um 23:05 schrieb jake:
>
> https://gitlab.xiph.org/xiph/icecast-server/commits/master
>
> The last commit was a week ago, and it looks fairly active, so.... yes?
>
> On 2018-08-29 05:28, Chernabog wrote:
>
>> Hello! I was just
2010 Aug 07
12
Paperclip Trouble - Not Writing to the Database
Hello all,
I''m a Rails newbie trying to get a basic implementation of Paperclip up
but it''s giving me problems. I''m developing on Windows XP (I know...)
with WEBrick and MySQL.
In my model I have:
class User < ActiveRecord::Base
has_attached_file :avatar,:styles => { :medium => "300x300>", :thumb
=> "100x100>" }, :url =>
2006 May 19
9
Resize uploaded image file without creating temp file?
Hi,
I need to take a single uploaded image file and save three resized
versions of it, a thumbnail, normal and large version. I was planning on
doing this in my model by having an array of geometry strings and looping
through them, each time saving a new image object resized to the correct
geometry. I know that file column does similar stuff, but I would prefer
to have a separate database row
2008 Mar 20
0
Having trouble with a remote-crop-then-resize using attachment fu =(
Basically, I''m trying to crop multiple images out of a remote/original
scene.. Think flickr ''tagging'', only, the pixs in the tagged boxes
become their own unique images.. by way of simulating an upload from
the controller using attachment fu.. can''t quite figure out the
specific method in fu that would allow me to do this.. I''m so near the
edge right
2005 Jan 11
7
default error page
Help, please.
I need redirection to a custom error page, instead of
the default Rails messages (e.g. Unknown action).
I use WebRick, no Apache, and i think i can''t use
public/.htaccess (# General Apache options).
Thanks.
___________________________________
Nuovo Yahoo! Messenger: E'' molto più divertente: Audibles, Avatar, Webcam, Giochi, Rubrica
Scaricalo ora!
2009 Aug 02
1
Provide missing image
Hi
I have an application where people can upload avatar-like images to
the site. When I show the images I want to show a placeholder image if
no image has been uploaded for that user.
I was thinking of overloading the image_tag helper to check for
existance and provide :default => "path/to/default/image" for the
image to show in case the primary one does not exist.
So my questions
2009 Nov 27
1
Cucumber + Paperclip
Hello Friends,
First time I am writing a scenario for uploading images. But some how
things are not working as it should be
The cucumber scenario is
And I attach the file at "/home/user/Desktop/sdasd.png" to "avatar"
And I press "Upload Logo"
But I trace it. its showing up
avatar_file_name: "sdasd.png", avatar_content_type:* "text/plain",*
2011 Aug 13
1
Paperclip - could not find generator.
Hello there,
I installed plugin "paperclip" for working with images, but after
running a command
--
rails generate paperclip user avatar
I am getting error
--
Could not find generator paperclip.
If I will try run a command
--
bundle show paperclip
So I will get
--
/Library/Ruby/Gems/1.8/gems/paperclip-2.3.0
In Gemfile I have
--
gem "paperclip", "~> 2.3"
I
2001 Jan 30
3
dsa_verify signature incorrect
I am building version 2.3.0p1 of openssh on a UnixWare 2.03 system
and am unable to connect with SSH 2. The error I get is:
debug: len 55 datafellows 0
debug: dsa_verify: signature incorrect
dsa_verify failed for server_host_key
The build environment is as follows:
gcc 2.95.1
openssl-0.9.6-beta2
I've looked through the archives and found similar problems related
to version