• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

cfpdfform (CF8) changes text-field font of an adobe 9 pdf form to Courier

New Here ,
May 19, 2010 May 19, 2010

Copy link to clipboard

Copied

I'm having problems getting cfpdfform to render the text-field font as it exists in the source pdf form.

The source pdf form was created in Acrobat 9 Standard.

When I download the pdf from the server using cfcontent, the text-fields look as expected, retaining their designated font (and the pdf has the desired fonts embedded).

However, when I do a cfpdfform action="populate", the text-field font is switched with Courier (even though the desired fonts remain embedded).

This happens regardless of what font I pick.

I have verified that the font exists on the server and in cf admin.

Here's my code:

<!--- populate --->
<cfpdfform action="populate"
           source="#pdfPathFile#"
           destination = "#pdfPathFile#"
           overwrite = "yes">

    <cfpdfformparam name="student_name" value="first name and last name" />
    <cfpdfformparam name="certificate_title" value="a cool certificate title" />
    <cfpdfformparam name="certificate_date" value="1/1/2010" />

</cfpdfform>

<!--- make read-only --->
<cfpdf action = "write"
       destination = "#pdfPathFile#"
       source = "#pdfPathFile#"
       flatten = "yes"
       overwrite = "yes"  />

<!--- return the content --->
<cfcontent
    file = "#pdfPathFile#"
    deleteFile = "yes"
    reset = "yes"
    type = "application/pdf" />

Commenting out the cfpdf action = "write" block produced the same outcome.

Using different source and destination filenames (vs overwriting  existing one) didn't make a difference, either.

Any ideas on how I can get cfpdfform to respect my predefined text-field fonts?

I truly appreciate your time.

TOPICS
Advanced techniques

Views

1.7K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 21, 2010 May 21, 2010

Copy link to clipboard

Copied

The problem was resolved.

Turned out to be the way the pdf was created by Adobe 9 Standard that made cfpdfform misbehave.

Three things we did seemed to have made the pdf acceptable by cfpdfform:

1. Downloaded the latest updates for Adobe 9 Standard
2. Checked on the text-field "Multi-line" property
3. Checked off the text-field "Rich Text Formatting" property

Cheers.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Aug 30, 2011 Aug 30, 2011

Copy link to clipboard

Copied

Thanks for the tip!

Any experience inserting images inside pdf forms?

It seems to work but won't 'survive' when flattening the pdf form to a static Acrobat file.  Any ideas?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 08, 2015 Jun 08, 2015

Copy link to clipboard

Copied

LATEST

Hi,

I am trying to send rich text data to the  pdf using cfpdfform and the pdf is not taking recognizing the codes.

Ex: it display <b> test data</b> instead of Test Data.

Do you have any suggestions?

Thanks!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation