php - Issue with opening XFDF PDf's from PGP program -
I have a system that prepares the PDF field via XFDF.
This XFDF code looks ok, but when I try to open it with PHP in header ()
, PDF activates an error if I ignore it I'm refreshing the page, so it works fine and populates the form correctly.
Using the xfdf code as well as headers below ...
Any ideas why PDF does not display it immediately?
& lt; `? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; `Xfdf xmlns =" http://ns.adobe.com/xfdf/ "xml: space =" protected "& gt; & Lt; 'Regions' & gt; & Lt; `Field name =" user_name "& gt; & Lt; `Value & gt; Some names & lt; / Value & gt; & Lt; '/ Regions & gt; & Lt; `Field Name =" course_name "& gt; & Lt; `Value & gt; Some courses & lt; / Value & gt; & Lt; `/ Regions & gt; & Lt; `/ Regions & gt; & Lt; `F href =" http: // the_URL_to_the_PDF_that_needs_to_be_populated_with_the_XFDF info "/> & Lt; `/ Xfdf & gt;
I am trying to open up with the header command below.
header ("content-type: application / vnd.adobe.xfdf ");
Try:
// later No Place This Opening Tag $ xfdf = & lt; & Lt; & Lt; 'XFDF' & lt ;? XML version = "1.0" encoding = "UTF-8"? & Gt; & Lt; Xfdf xmlns = "http://ns.adobe.com/xfdf/" xml: space = "preserve" & gt; & Lt; Areas & gt; & Lt; Field name = "user_name" & gt; & Lt; Value & gt; Some names & lt; / Field & gt; & Lt; Field Name = "course_name" & gt; & Lt; Price & gt; Some courses & lt; / Field & gt; & Lt; / Regions & gt; & Lt; F href = "http: // the_URL_to_the_PDF_that_needs_to_be_populated_with_the_XFDF info" /> & Lt; / Xfdf & gt; XFDF; // There is no place before this closing tag header ('content-type: application / vnd.adobe.xfdf'); Echo $ xfdf;
Comments
Post a Comment