public
Description: A Ruby on Rails plugin that streamlines interactions with the Scribd service
Homepage: http://blog.matt-darby.com/category/code-stuff/scribd_fu/
Clone URL: git://github.com/mdarby/scribd_fu.git
mdarby (author)
Mon May 26 08:11:13 -0700 2008
commit  f63abb76936662dbbf20a1909ddac26d314eb15e
tree    36abed64ecfd172ce2046d080ecae2fb5dedcd07
parent  882d9ffbc550f91ebb4bbff97536131eca8aab29
name age message
file MIT-LICENSE Mon Mar 24 20:00:02 -0700 2008 Initial import of Scribd_fu [mdarby]
file README Mon May 26 08:11:13 -0700 2008 Updated the readme to reflect wiki changes [mdarby]
file Rakefile Mon Mar 24 20:00:02 -0700 2008 Initial import of Scribd_fu [mdarby]
file init.rb Wed Mar 26 07:36:10 -0700 2008 Working as a stand-alone plugin, Attachment_fu ... [mdarby]
file install.rb Mon Mar 24 20:00:02 -0700 2008 Initial import of Scribd_fu [mdarby]
directory lib/ Mon Apr 21 05:58:16 -0700 2008 adjusted and added mime-types for powerpoint an... [joergbattermann]
file scribd.yml.example Tue Mar 25 16:30:37 -0700 2008 Sequence from config reading to login is working [mdarby]
file uninstall.rb Mon Mar 24 20:00:02 -0700 2008 Initial import of Scribd_fu [mdarby]
README
Scribd_fu
------------
A Ruby on Rails plugin that streamlines interaction with the Scribd service (scribd.com), and even works with 
Attachment_fu!

What it does
------------
Scribd_fu hides out in the shadows like a document converting ninja, just waiting to process your data into a convenient 
Flash format (like YouTube) with the help of the black majick of Scribd.com. Imagine imbedding huge documents right 
inline with your web UI, no downloading, no necessary programs on the client side to view your data. It’s pretty da
mned cool.


Requirements
------------
Scribd_fu requires the wicked awesome Attachment_fu plugin. You probably already have it installed.
You also need the rscribd gem (sudo gem install rscribd will do the trick)


How to Install
------------
Clone the git repository into your app’s vendor/plugins directory
cd vendor/plugins && git clone git://github.com/mdarby/scribd_fu.git

Install the rscribd gem
gem install rscribd


How to Use
------------
Enter the below line into any attachment_fu-using model that you’d like to Scribdify
acts_as_scribd_document

Add the following fields into a new migration for the target model (and update your schema!):
t.integer :scribd_id
t.string :scribd_access_key

Sign up for Scribd (it’s totally free)

Copy the vendor/plugins/scribd.yml.example file to config/scribd.yml and fill out with your Scribd login credentials

Now, when you upload a file that is convertible in the Scribd system, Scribd_fu will automatically handle the CRUD for 
you. No muss, no fuss.

To view a Scribd document, just throw the below code into your view (where @document is an object of your 
Scribd/Attachment_fu model):
<%= display_scribd(@document) %>
That’s it!


Further Info
------------
You can make your Scribd documents private or public, to choose, just modify the scribd.yml file and enter ‘private’ or ‘
public’ in the ‘access’ key.


About the Author
------------
My name is Matt Darby. I’m a 28 year old professional Web Developer and IT Manager. I am the IT Manager and Lead Web De
veloper at Dynamix Engineering and recently earned a Master’s Degree in Computer Science from Franklin University in Co
lumbus, OH.

Feel free to check out my blog (http://blgo.matt-darby.com) or to recommend me on http://workingwithrails.com