CWP and displaying PDF's

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

CWP and displaying PDF's

dealtek@gmail.com
Hi all,

Seems like a basic question but I haven't used containers on the web much: using CWP with php - is it possible to display a .pdf (or an image etc.) on a web page that is stored in a FM container field?

If so how would you do this?


--
Thanks,
Dave - DealTek
[hidden email]
[db-17]

_______________________________________________
FMPexperts mailing list
[hidden email]
http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: CWP and displaying PDF's

Beverly Voth-3
If you have the CWP guide (and you can get for various versions of FMS), then it explains how to. Remember that you can have different kinds of storages for containers.
> getContainerData() // specific record
&
// For images, use the HTML img tag
echo '<img src="'.$fm-> getContainerDataURL($record->getField('container')) .'">';
// For movies and PDF files, use the HTML embed tag
echo '<embed src="'.$fm-> getContainerDataURL($record->getField('container')) .'">';

(if this is different the CWP guide will tell you)
beverly

 

> On May 19, 2017, at 5:08 PM, [hidden email] wrote:
>
> Hi all,
>
> Seems like a basic question but I haven't used containers on the web much: using CWP with php - is it possible to display a .pdf (or an image etc.) on a web page that is stored in a FM container field?
>
> If so how would you do this?
>
>
> --
> Thanks,
> Dave - DealTek
> [hidden email]
> [db-17]
>
> _______________________________________________
> FMPexperts mailing list
> [hidden email]
> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au

_______________________________________________
FMPexperts mailing list
[hidden email]
http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: CWP and displaying PDF's

tim ballering-2
In reply to this post by dealtek@gmail.com
It is possible. However, you will find a huge performance increase for larger files if you upload pdfs and image to a folder on the web server and store the URL location in FMP.  

You can use AppleScript or a plugin to upload the images/pdf to the web server via FTP.

Tim Ballering
[hidden email]



> On May 19, 2017, at 5:08 PM, [hidden email] wrote:
>
> Hi all,
>
> Seems like a basic question but I haven't used containers on the web much: using CWP with php - is it possible to display a .pdf (or an image etc.) on a web page that is stored in a FM container field?
>
> If so how would you do this?
>
>
> --
> Thanks,
> Dave - DealTek
> [hidden email]
> [db-17]
>
> _______________________________________________
> FMPexperts mailing list
> [hidden email]
> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au

_______________________________________________
FMPexperts mailing list
[hidden email]
http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: CWP and displaying PDF's

Beverly Voth-3
My preferred method (have the web server do what it does best - serve files). Then make sure you have the path to those uploaded images/files as a text field in the record. :)
Beverly

> On May 19, 2017, at 6:19 PM, Tim Ballering <[hidden email]> wrote:
>
> It is possible. However, you will find a huge performance increase for larger files if you upload pdfs and image to a folder on the web server and store the URL location in FMP.  
>
> You can use AppleScript or a plugin to upload the images/pdf to the web server via FTP.
>
> Tim Ballering
> [hidden email]
>
>
>
>> On May 19, 2017, at 5:08 PM, [hidden email] wrote:
>>
>> Hi all,
>>
>> Seems like a basic question but I haven't used containers on the web much: using CWP with php - is it possible to display a .pdf (or an image etc.) on a web page that is stored in a FM container field?
>>
>> If so how would you do this?
>>
>>
>> --
>> Thanks,
>> Dave - DealTek
>> [hidden email]
>> [db-17]
>>
>> _______________________________________________
>> FMPexperts mailing list
>> [hidden email]
>> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
>
> _______________________________________________
> FMPexperts mailing list
> [hidden email]
> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au

_______________________________________________
FMPexperts mailing list
[hidden email]
http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: CWP and displaying PDF's

Bob Patin
I agree 100% with Bev; I store any extraneous files—images, PDFs, audio—on the web server, then store the names for those files in the database. Using this method, I have a client who has more than 300GB of PDFs on the web server, but the database is tiny and fast, and the PDFs load really fast.


Bob Patin
Longterm Solutions
[hidden email]
615-333-6858
FileMaker 9, 10, 11, 12 & 13 Certified Developer
http://www.longtermsolutions.com
-
iChat: [hidden email]
Twitter: bobpatin

FileMaker Consulting
FileMaker Hosting for all versions of FileMaker
PHP • Full email services • Free DNS hosting • Colocation • Consulting

> On May 19, 2017, at 6:18 PM, BEVERLY VOTH <[hidden email]> wrote:
>
> My preferred method (have the web server do what it does best - serve files). Then make sure you have the path to those uploaded images/files as a text field in the record. :)
> Beverly
>> On May 19, 2017, at 6:19 PM, Tim Ballering <[hidden email]> wrote:
>>
>> It is possible. However, you will find a huge performance increase for larger files if you upload pdfs and image to a folder on the web server and store the URL location in FMP.  
>>
>> You can use AppleScript or a plugin to upload the images/pdf to the web server via FTP.
>>
>> Tim Ballering
>> [hidden email]
>>
>>
>>
>>> On May 19, 2017, at 5:08 PM, [hidden email] wrote:
>>>
>>> Hi all,
>>>
>>> Seems like a basic question but I haven't used containers on the web much: using CWP with php - is it possible to display a .pdf (or an image etc.) on a web page that is stored in a FM container field?
>>>
>>> If so how would you do this?
>>>
>>>
>>> --
>>> Thanks,
>>> Dave - DealTek
>>> [hidden email]
>>> [db-17]
>>>
>>> _______________________________________________
>>> FMPexperts mailing list
>>> [hidden email]
>>> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
>>
>> _______________________________________________
>> FMPexperts mailing list
>> [hidden email]
>> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
>
> _______________________________________________
> FMPexperts mailing list
> [hidden email]
> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au

_______________________________________________
FMPexperts mailing list
[hidden email]
http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au
Loading...