Tags:
create new tag
view all tags

Question

I have GenPDFAddOn configured, and have it patched for Dakar to recursively add topics to my PDF. To my dismay, those pages that use a TWikiForm do not have that form data populated within the generated PDF. Is there a way to generate the PDF such that it includes the TWikiForm?

Environment

TWiki version: TWikiRelease04x00x00
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS: RedHat Linux
Web server: Apache 2.0
Perl version: perl 5.8.5
Client OS:  
Web Browser:  
Categories: Forms, Plugins

-- TWikiGuest - 07 Apr 2006

Answer

ALERT! If you answer a question - or someone answered one of your questions - please remember to edit the page and set the status to answered. The status selector is below the edit box.

I am not familiar with this add-on. If you do not get an answer here ask in GenPDFAddOnDev.

-- PeterThoeny - 09 Apr 2006

Guest, the simple answer is "no". GenPDF uses it's own renderer, which doesn't render form data.

Note that I recently released a TWiki-4 compatible version of GenPDFPlugin.

I also recently added PDF support to PublishContrib, which might help.

-- CrawfordCurrie - 10 Apr 2006

On second (third) thoughts, the forms ought to be visible as long as your selected skin includes them. Try generating using, for example, print.pattern skin.

-- CrawfordCurrie - 11 Apr 2006

Testing both PublishContrib and GenPDF, neither seem to pay attention to the skin, with respect to the TWikiForms as they come out of the box. Nothing I've seen in the TWikiForms documentation suggests that they can't be exported, but I've not yet seen mention of anyone doing it, either.

-- TWikiGuest - 11 Apr 2006

OK: checking code, I've found in the templates where it lists

and am using skins that include that (print.classic and print.pattern do). Inserting in my page itself, to show what form it thinks is attached, I get nothing, which might explain why the generated file doesn't include the form. Note that the printable link does print out the form, though doesn't show any output for the META{"form"} tag I have embedded in the page.

-- TWikiGuest - 11 Apr 2006

Final notes after much poking, and now giving up in frustration: [forgive the lack of line numbers, but I've now added enough print statements to my local copy to be sure to be out of whack]

  • GenPDF has the concept of the form up until the line in _fixHtml where META info is explicitly removed via a pattern match substitution
  • Attempting to render that text before the substitution using either Twiki::Func::renderText or TWiki::Render::getRenderedVersion was unfruitful. renderText leaves the tags in there untouched, as does getRenderedVersion.
  • It looks as if Render.pm has methods for rendering fields (see renderFormField), but neither GenPDF nor Publish iterate over the set of form fields to populate them.

For the moment, my conclusion is that it's not possible to export TWikiForm content, either via PublishContrib or via GenPDF. Happy to be proven wrong, but leaving my notes here for the next traveler.

-- TWikiGuest - 11 Apr 2006

Edit | Attach | Watch | Print version | History: r11 < r10 < r9 < r8 < r7 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r11 - 2006-04-20 - PeterThoeny
 
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2026 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.