Senior & Expert RoR Developers Discussion Forum by Nyros Technologies

HIRE Ruby on Rails Expert Developers Programmers Coders From India
Ruby on Rails PHP .Net Developers Community, Nyros Technologies, Kakinada
 
Log in  or IF not a member please REGISTER
Username:
Password:   


Keyword
Log in | Profile 

FileColumn - easy handling of file uploads in Rails

 
Post new topic   Reply to topic    Senior & Expert RoR Developers Discussion Forum by Nyros Technologies Index -> A little Ruby programming (Basic programming in RoR)
View previous topic :: View next topic  
Author Message
Anu



Joined: 01 Jan 2010
Posts: 36

PostPosted: Mon Feb 08, 2010 1:53 pm    Post subject: FileColumn - easy handling of file uploads in Rails Reply with quote

This file_column plugin handles saving files to the file system.

Resizing of images,creation of thumbnails.

here is a an example:
+Make the "image" column ready for handling uploaded files...

class Entry < ActiveRecord::Base
file_column :image
end

+ To generate file fields uploaded images form redisplays to your view...

<%= file_column_field "entry", "image" %>


+And display uploaded images in your view

<%= image_tag url_for_file_column("entry", "image") %>

+To resize uploaded image to a maximum size of 640x480, we have to declare an additional option.

class Entry < ActiveRecord::Base
file_column :image, :magick => { :geometry => "640x480>" }
end

list of features of file_column:

*Uploaded files are stored in the filesystem.

*For example, a uploaded file "test.png" is stored at "public/test.png".

*New uploaded files are stored in a temporary directory first, and they are available for redisplay the files.

*You can easily generate a file upload field in views .

Installtion of the file_column plugin:

script/plugin install http://opensvn.csie.org/rails_file_column/plugins/file_column/trunk


Thank you,
Anasuya.N
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Senior & Expert RoR Developers Discussion Forum by Nyros Technologies Index -> A little Ruby programming (Basic programming in RoR)
Page 1 of 1

 latest topics 
 Topics   Replies   Author   Views   Last Post 
No new posts About Modules,Mixins and Namespaces
0 swaminadhan 6 Sat Mar 20, 2010 12:01 pm
swaminadhan View latest post
No new posts Railsdav plugin
0 swaminadhan 8 Sat Mar 20, 2010 11:20 am
swaminadhan View latest post
No new posts Deploying the rails applicatin in Heroku
0 Divya 11 Fri Mar 19, 2010 12:23 pm
Divya View latest post
No new posts overridig existing methods
0 Raja 13 Fri Mar 19, 2010 11:28 am
Raja View latest post
No new posts Class Methods
0 Raja 10 Fri Mar 19, 2010 11:04 am
Raja View latest post
No new posts Objects methods
0 Raja 12 Fri Mar 19, 2010 10:50 am
Raja View latest post
No new posts Documentation
0 Anu 23 Thu Mar 18, 2010 4:01 am
Anu View latest post
No new posts File handling in ruby
0 Anu 30 Wed Mar 17, 2010 2:14 pm
Anu View latest post
No new posts sending an email from rb file
0 umamahesh_nyros 21 Wed Mar 17, 2010 6:13 am
umamahesh_nyros View latest post
No new posts difference bewteen render component and render partial
0 umamahesh_nyros 19 Wed Mar 17, 2010 6:06 am
umamahesh_nyros View latest post




Hire an expert Ruby on Rails developer / coder / programmer or development team from India now!!

Other Forums : PHP   ::   .Net   |   Free unlimited HTML CSS templates download

Nyros Technologies   |   Kakinada City Portal   |   Developers Blog   |   About Ruby on Rails Experts   |   More