Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

file previews


Go to End


3 Posts   472 Views

Avatar
Guy Van Bael

Community Member, 61 Posts

18 March 2015 at 12:09am

Hi,

Does anyone know if it's possible to automatically extract previews from files to use later on in the templates. Files can be images, but also doc, docx, xls, pdf etc.
I know there's a pdf extraction module, but i would like my client to upload a file (make it available as download for others) and i would like to show it on the frontend with a preview.

Thanks
Guy

Avatar
Pyromanik

Community Member, 419 Posts

20 March 2015 at 11:49pm

Edited: 20/03/2015 11:50pm

You'll have to use some kind of helper library, possibly in league with some kind of message queue and process it outside of silverstripe I'd imagine, creating an image.
You could then show the image if it exists, or a pending picture with/or a file type extention generic logo image.

There are probably other solutions, but this is how I'd approach this problem.