I have an infopath form which when submitted generates a pdf file with the same form content(XML) using itextsharp library.
I have a node in infopath form that contains the URL of an image from a sharepoint picture library. How do i embed this image into the pdf file generated? Any solution with xslt modification in my xsl file that i am using for transforming the form XML content?
Thanks for the help!
Someone's actually using InfoPath? First I've heard. Wow. Okay, so there's over 400 questions tagged infopath, but still...
iText's general HTML->PDF functions should convert standard <img src="..."> tags to PDF just fine. If that's not an option for some reason, iText's new XMLWorker may do the trick, released with 5.1.0.
There's even a demo page up: http://www.lowagie.com/xmlworker
Related
Is there a way to disable auto generated hyperlinks from pdf. For example, I have a string https://example.com/, after converting from html to pdf using Puppeteer, it automatically converts the string to an hyperlink, which does not exist.
Is there a flag or something in Chromium or puppeteer to disable auto linkification.
Puppeteer does not add any links to the PDF document that are not actually present in the page. It is very likely your PDF viewer that is adding these links.
Try it yourself.
Upload your PDF to this viewer (that uses PDF.js), button is in the top right. This viewer does not add any links to the document. If the link is not clickable in this document, your PDF viewer is adding the links.
I have two html tables(containing dynamic content stored in variables) along with headings and paragraphs. When the user clicks the download PDF button, he/she should be able to download one PDF of two pages containing the two tables.
I have read a lot of articles but I found no definite answer to this issue.Should I use jspdf or react-pdf for this scenario?
I am using react frontend and Nodejs backend.
https://github.com/MrRio/jsPDF
JSPDF is a perfect solution for converting tables into PDF in client-side. But if you want to do something from backend
Or you can refer to
https://www.npmjs.com/package/html-pdf
for rendering it in the backend, and make express download it.
Looks like you can call the window.print() method in componentDidMount() to print the complete div, though removing the footer through the script can be a challenge.
Using html2canvas with jspdf has a major drawback that the pdfs are blurred and their clarity varies with the page zoom, as it takes the screenshot of that portion. Hence, you must configure it correctly or compromise on quality.
I have little developing experience and I would really appreciate it if someone could point me in the right direction with my little project.
Basically, I have this first page where the user fills a form via radio buttons. These choices all represent pieces of texts in the database. When the form is submitted, an EJS page is rendered where these texts are merged. I've managed to make it work this far using Node, Express and MongoDB.
As the next step I'm trying to give the user the option to download the generated text as a nice looking PDF file. What would you recommend me to use?
You can use tools like node-html-pdf which takes a picture from your generated html page from EJS and print it using an headless browser.
Note : Since PhamtomJS is deprectated, node-html-pdf's too.
I have tried using 3 PDF libraries(ZendPdf, DomPDF and wkhtmltopdf) in Zend Framework 2 to generate PDF Reports. All of them can generate basic HTML to PDF but do not seem to support SVG tags. Text and styles are rendered but SVG element comes blank in PDF.
I am trying to generate PDF Report files for charts generated by ExtJs which uses SVG tags. I am able to render simple html tags like(P with css styles) but unable to render SVG tags. It comes blank for svg. It is unable to render svg tags but other text and html can be read and rendered.
Please suggest if there is any tweak or the libraries do not support SVG tags. If you need I can provide you Sample HTML to experiment.
Hence, the question remains the same:
Blockquote
Which pdf library supports SVG tag in ZF2 (Zend Framework 2) and how to do that(if possible, please provide example code)?
Blockquote
PHP wrapper for PD4ML should do the trick. Here is a list of supported SVG tags.
I am creating an ASP.NET web application. In one of my webpages (an ASCX control) I am placing a fusion chart inside a <div> tag. I want to provide an option for the client to download this fusion chart.
Is there any way that I can download
the fusion chart present in the Div
tag, as an image (Using javascript
because the div tag is a client side
control).
The request is that my client could save this fusion chart present in the <div> tag as an image when he visits the webpage.
The target browser is IE.
Please help me.
I can confirm that it is not possible to 'Export the chart as image' when using FusionCharts Free. However, as mentioned by Larsenal, you will be able to use FusionCharts v3.2.1 and it's updated JavaScript API to export pure JavaScript charts to JPEG, PNG, PDF, SVG formats.
Ref.- http://www.fusioncharts.com/docs/?ECPureJS.html
Furthermore, you may even export your Flash charts, if required, in a similar manner. DO check out the link below for a more detailed account of the same.
Ref.- http://www.fusioncharts.com/docs/?ECOverview.html
Hope this helps.
It is currently not possible to generate an image from a section of a webpage with JavaScript. Quoting myself from another question:
Firefox added something similar to
this to their canvas implementation.
You can find
CanvasRenderingContext2D.drawWindow()
documented in their wiki. It is
restricted to being used by plugins,
for security purposes, and isn't
supported by any other browsers.
There is
talk
of adding support to other browsers,
and perhaps removing some of the
security restrictions, but that is
probably a long way off. For now,
there isn't a good JavaScript solution
to your problem.
Sorry, there's no way to do it with Javascript.
I don't know about the Fusion controls, but some graphing libraries include a way to render to an image or PDF. Start looking there, not Javascript.
Update: FusionCharts claims to have the ability to export to JPG, PNG, PDF and CSV. Start with this page about exporting pure JS charts in their documentation.