Thursday, January 6, 2011

Re: [Rails] Re: Document preview

On Jan 6, 2011, at 12:02 PM, Marnen Laibow-Koser wrote:

>> These files are rather large and a user may want to see the first
>> page/contents before deciding to download the entire document.
>>
>> I was wondering if there were any rails/web/js solutions for this or
>> something similar...
>
> JavaScript solutions exist. Try a Web search.


JavaScript can *show* the preview in a nice popup or overlay, true,
but I think the issue here is how do you get the preview in the first
place. It sounds like the OP wants to make something like Mac OS's
QuickLook here...

John, do you have a (hopefully) short list of document types that you
need to handle? Are you storing these files using Paperclip or
similar? I'm thinking that you could use Paperclip's Processors setup
to generate these preview files when they're uploaded, and access them
that way. But you'll need to engineer a mechanism for grabbing the
first page or whatever from each different file-type you plan to
store, along with a fall-back generic curled-page icon for those you
can't untwist.

Walter

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate