Results 1 to 3 of 3

Thread: Can you open a pdf witin an Iframe

  1. #1
    tj@estreet.com is offline Sugar Community Member
    Join Date
    Feb 2006
    Posts
    163

    Default Can you open a pdf witin an Iframe

    How may I open a pdf file within an iframe, within SugarOS?

    From within a custom Orders Module and subsequent online Order Form, I am creating and saving a contract.pdf file to a PDF_TEMP folder. I would like to returnt to ContractViewConfm.html+php with the newly created contract.pdf open for customer review and acceptance within an Iframe, within ContractView.htm, within SugarOS. Has this been done?

  2. #2
    stevec is offline Sugar Community Member
    Join Date
    Oct 2005
    Location
    London
    Posts
    1,100

    Default Re: Can you open a pdf witin an Iframe

    try this:

    Edit the equivalent of the DetailView.html file you are using and add something like this to somewhere appropriate:

    Code:
    <tr>
    <td colspan="2" class="tabDetailViewDF">
    <iframe src="pathto/test.pdf"  class="tabDetailViewDFLink" name="pdfaccept" width="100%" height="600"></iframe>
    </td>
    </tr>
    This works in Internet Explorer but the acrobat plugin for firefox seems to be a bit flakey when opened in an iframe.

    All you'll need to do is set up a variable to pass to the code to represent pathto/test.pdf. If the filename is stored as a custom field - you could just refer to it as any custom field is referred to in the studio edited html files.

  3. #3
    tj@estreet.com is offline Sugar Community Member
    Join Date
    Feb 2006
    Posts
    163

    Default Re: Can you open a pdf witin an Iframe

    Thanks! I'll give it a go.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •