Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Returning an inline pdf
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
West Wind Web Connection
Versions des environnements
Visual FoxPro:
VFP 8
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
Visual FoxPro
Divers
Thread ID:
00988459
Message ID:
00988472
Vues:
44
Hi Don,

The headers you listed should be sufficient. This is how returning a PDF file works in AFP:
<%
  * generate the PDF file and read it into lcPDF
  * FILETOSTR() is just an example
  lcPDF = FILETOSTR(JUSTPATH(FILE.GetLocation())+"\Sample.PDF")

  * Display the PDF file in the browser
  Response.ContentType = "application/pdf"
  Response.AddHeader( "Content-Disposition", "inline" )
  Response.BinaryWrite(m.lcPDF)
  
Make sure the Content-Length header is exactly the size of the PDF file and you don't send anything else to the browser.
--
Christof
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform