pdf-css-html5 transformation :Add Localized String to footer

Post here questions and problems related to editing and publishing DITA content.
axhxu
Posts: 45
Joined: Thu Aug 27, 2015 9:28 pm

pdf-css-html5 transformation :Add Localized String to footer

Post by axhxu »

HI,
I am looking for way to add localized strings to the footer of our pdf transformations.

In webhelp I use a localized plugin that contains our string files with our localized strings for transformations I then added to our webhelp transformation to load those variables during the html transformation.

In the pdf-css-html5 transformation it looks like you are using i18n css to change strings.

I have created a css and can control the footer using your predefined variables:

Code: Select all

@page :right {
    @top-left{
        content:" ";
    }
    @top-right{
        content:" ";
    }
    @bottom-left {
        content: string(maptitle);
        border-top: 2px solid grey;
        vertical-align: top;
        padding-top:10px;
    }
    @bottom-right {
        content: counter(page);
        border-top: 2px solid grey;
        vertical-align: top;
        padding-top:10px;
    }
    @bottom-center{
        content:" ";
        border-top: 2px solid grey;
        vertical-align: top;
    }
}
Basically I need something like string(maptitle) but instead it would be string(copyright) and be able to load the string from my localized plugin string file.

Is there a way to use my code for the webhelp transformation to add the copyright in the footer of of the pdf transformation?

Or do I need to use the i18n css

Code: Select all

/
*  Custom string */
*[class ~= "map/map"]:lang(en) {
  string-set: footer-copyright "Copy right footer text";
}
In which case can I create i18n css files in my own template css folder and add just the strings we need to customize?

Thanks
Arron Varga