xsl-fo

How to show page number (N of N) using xslt in PDF Report

孤街醉人 提交于 2019-12-01 03:13:53
I am using XSLT to generate PDF report. My requirements are to display page number in the format of Page N of N (e.g.Page 1 of 3) at the footer of the report. For static values it works fine and it repeats on each page. As total number of pages in the report are not known and it changes run time, so how I will accomplish this task. My XSLT code snippet <xsl:template name="footerall"> <xsl:variable name="maxwidth" select="7.07000" /> <fo:static-content flow-name="xsl-region-after"> <fo:block> <xsl:variable name="tablewidth29" select="$maxwidth * 1.00000" /> <xsl:variable name="sumcolumnwidths29

How to show page number (N of N) using xslt in PDF Report

痞子三分冷 提交于 2019-11-30 23:10:28
问题 I am using XSLT to generate PDF report. My requirements are to display page number in the format of Page N of N (e.g.Page 1 of 3) at the footer of the report. For static values it works fine and it repeats on each page. As total number of pages in the report are not known and it changes run time, so how I will accomplish this task. My XSLT code snippet <xsl:template name="footerall"> <xsl:variable name="maxwidth" select="7.07000" /> <fo:static-content flow-name="xsl-region-after"> <fo:block>

Preserving whitespace in PDF after XSL transform

北战南征 提交于 2019-11-30 22:59:30
问题 I'm converting an XML to PDF using XSL transformation. Unfortunately, it is not preserving the whitespace from the XML. For example: I want to convert this: Test Line Data : 0xAA to PDF from an XML. It looks fine in the XML, it has the 9 spaces between Data and : but in the PDF it shows Test Line Data : 0xAA Here is what I currently do. After writing the data to the XML, I will perform the following: XPathDocument xPathDocDiag = new XPathDocument(this.FileNameDiagXml); XslCompiledTransform

Using XSLT to create XSL-FO with nested bold/italic tags

廉价感情. 提交于 2019-11-30 20:16:37
I'm creating xslt file, which should convert my xml into xsl-fo. XML is something like that: <doc> <par> <point> <text>some text</text> </point> </par> </doc> Of course, there are many paragraphs and points in document. I would like to add possibility to format "some text", for example <bold>bolded text</bold> and <italic>italic</italic> Should give <fo:block><fo:inline font-weight="bold">bolded text</fo:inline> and <fo:inline font-style="italic">italic</fo:inline> Now I have quite simple xslt document, like this: <xsl:stylesheet version="1.1" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"

PDF report with embedded HTML

江枫思渺然 提交于 2019-11-30 18:40:31
We have a Java-based system that reads data from a database, merges individual data fields with preset XSL-FO tags and converts the result to PDF with Apache FOP . In XSL-FO format it looks like this: <?xml version="1.0" encoding="utf-8" ?> <!DOCTYPE Html [ <!ENTITY nbsp " "> <!-- all other entities --> ]> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:fo="http://www.w3.org/1999/XSL/Format"> <xsl:output method="xml" indent="yes" /> <xsl:template match="/"> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:svg="http://www.w3.org/2000/svg" font

Vertical alignment of text in a table cell

青春壹個敷衍的年華 提交于 2019-11-30 17:11:58
I would like to align the text to bottom in the second cell. The first cell extends to 2 lines, because of insufficent width and that's OK But the text in the second cell is only one line and shows up at the top of the cell. How can I align it to bottom? I tried vertical-align="bottom" text-align="bottom" text-align="end" on row , cell and block levels.. Any of them worked?!? <fo:table font="normal 10 pt Arial, sans-serif" width="100%"> <fo:table-column column-width="40mm"/> <fo:table-column column-width="130mm"/> <fo:table-body> <fo:table-row> <fo:table-cell padding-before="3pt" padding-after

XSLT - XML (Word) to XSL-FO (PDF)

試著忘記壹切 提交于 2019-11-30 16:05:16
I'm looking for some basic instructions on how to implement an XSLT sheet to transform my XML (Word Template) into an XSL-FO (PDF) template. I'm having trouble finding an actual place to download such a sheet (or get an example for re-coding), and I'm not entirely sure how to implement one once I find it. Note that I cannot just convert these into PDFs manually. This project requires that they be automatically generated, and thus require the XSLT sheet to convert them. Thank you in advance. I know this is a pretty generic question, but I really don't know what I'm doing with XSLT. Take a look

what are the leading XSL-FO implementations? How do I decide among them?

笑着哭i 提交于 2019-11-30 14:23:23
I'm evaluating PDF rendering technologies. XSL-FO is our chosen path because its an open standard and our source data is XML. What experiences have people had with the various implementations of XSL-FO? The implementations I've found so far are: renderX ecrion Antenna House Apache FOP The criteria I'm using to evaluate are: performance, stability, supportability, price, template management tools. Also important: good java APIs and ability to run on Unix. Whatever product we end up choosing, we will also be asked to find consulting services to help us build our templates, so the ability to find

What's the difference between XSLT and XSL-FO?

断了今生、忘了曾经 提交于 2019-11-30 12:37:19
问题 What's the difference between XSLT and XSL-FO ? Every resource I've read deal with them as if they were 1, or at least very closely tied.. 回答1: I was wondering about the basis of the question because I thought it was easy to answer, however as soon as you go here: http://www.w3.org/TR/xsl/ it becomes clear that its actually a good question - because pretty much the first thing on the page is this statement: This specification defines the features and syntax for the Extensible Stylesheet

Cakephp Security

此生再无相见时 提交于 2019-11-30 09:09:51
I am new to Security of Web apps. I am developing an application in Cakephp and one of my friends told me about the Cross-site request forgery (CSRF) and cross-site scripting (XSS) attacks etc. not sure how many more are there. I need some help in understanding how to make Cakephp defend my web app against these. we are low budget and we cant hire a security consulant as of now. We are still developing the app and plan to release in by the end of the month. so wanna take care of the initial stuff that can help me stand un hacked ;) There is not (and cannot be) one tool you can deploy and then