Pdf Gallery View

Hello there,

I have a requirement from my client where I need to display all pdf in a specific directory. I want to display them as image gallery viewer where user can flip through various pdf’s. User would also like to make it touch screen responsible so that the pdf’s can be browse by dragging to side to side.

Thanks

Ashish Tyagi

Hi Ashish Tyagi

what exactly you want?

The implementation of that is to generate images from pdf (if you want it like thumbnails) and display by iterator all this images through model/controller/view including the links.

Post more details of your issue

  • I don’t know if exist an extension for that so you have to implement by yourself :)

Thank you very much for your reply, here is what I want.

  1. I will provide a button to user to upload the pdf file to a directory.

  2. View page should display all the pdf file in the directory in the either thumbnail view or Jquery slider view.

  3. End user can select a pdf by clicking on it otherwise the first pdf will appear.

  4. User can select previous or next button to view previous or next file.

  5. User should be able to scroll all pdf in touch screen device as well.

I am very new to php and Yii so I would need help.

Thanks

Ashish Tyagi

Dear friend

The thing you want to do is a custom Component with many functions

A way to do that is to do from scratch (write your own MVC Yii extension) or modify an already one

There are many gallery extensions for Yii for images

http://www.yiiframework.com/extensions/?tag=gallery

http://www.yiiframework.com/extension/gallerymanager

So the best way is to modify one of them to meet your needs

There’s a good chance you might be able to use imagick for the thumbnail creation. For the rest: It might be easiest to display the PDFs in an iframe. You wouldn’t want to got to the hassle of creating an image for every page in a PDF ;)

Yes That is what I am thinking but can we add the scrolling effect as of gallery to iframe pdfs