QUESTION: What's the difference between FDF and XFDF?
ANSWER: FDF and XFDF are both file formats for representing the form data and annotations that are contained in a PDF form. There are two main differences between FDF format and XFDF format:
- The syntax used for representing information in FDF format is different than the syntax used for representing that same information in XFDF format.
- There are some kinds of information that can be represented in FDF format but cannot be represented in XFDF format. Specifically: the following information in a PDF form can be represented in FDF format but not in XFDF format: Status, Encoding, JavaScript, EmbeddedFDFs, Differences, Target, and Pages.
This is what FDF looks like
FDF stands for "Forms Data Format." In the FDF format, information is represented in the form of key/value pairs. Here is an example of some FDF code that represents a form field named Street with a value of 345 Park Avenue.
/T(Street)/V(345 Park Avenue)
In this example, there are two keys and two values: a key named T with a value of Street, and a key named V with a value of 345 Park Avenue.
This is what XFDF looks like
XFDF stands for "XML Forms Data Format" — so, as you would expect, XML syntax is used. Here is XFDF code that represents the information above.
<field name="Street">
<value>345 Park Avenue</value>
</field>
More information