Add text in welcome page
Oxygen general issues.
-
- Posts: 41
- Joined: Thu Jun 08, 2017 3:41 pm
Add text in welcome page
Hi,
I was wondering if that was possible to add some text at the header of the welcome page. Is it? If yes, how can I do that? I can't find how.
See the picture below:
https://www.zupimages.net/viewer.php?id=20/03/3ric.png
Thanks!
I was wondering if that was possible to add some text at the header of the welcome page. Is it? If yes, how can I do that? I can't find how.
See the picture below:
https://www.zupimages.net/viewer.php?id=20/03/3ric.png
Thanks!
-
- Site Admin
- Posts: 275
- Joined: Thu Dec 24, 2009 11:21 am
Re: Add text in welcome page
Hello,
You can use the "webhelp.fragment.welcome" HTML Fragment extension point.
You can find more information in our User Manual about Inserting Custom HTML content in the WebHelp Responsive output: https://www.oxygenxml.com/doc/versions/ ... -html.html
Regards,
Alin
You can use the "webhelp.fragment.welcome" HTML Fragment extension point.
You can find more information in our User Manual about Inserting Custom HTML content in the WebHelp Responsive output: https://www.oxygenxml.com/doc/versions/ ... -html.html
Regards,
Alin
Alin Balasa
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 41
- Joined: Thu Jun 08, 2017 3:41 pm
Re: Add text in welcome page
Hello, thank you. It seems it's the right solution but it means I now need to use 2 different scenarios to get a version both for english and french languages. If there is any slution to get the translation into an only one scenario, I would be glad!
Thanks!
Thanks!
-
- Site Admin
- Posts: 275
- Joined: Thu Dec 24, 2009 11:21 am
Re: Add text in welcome page
Hello,
Do you want the text you are inserting in the welcome page to be translated according to the current language of your publication?
Regards,
Alin
Do you want the text you are inserting in the welcome page to be translated according to the current language of your publication?
Regards,
Alin
Alin Balasa
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Site Admin
- Posts: 275
- Joined: Thu Dec 24, 2009 11:21 am
Re: Add text in welcome page
Hello,
You can achieve this by using the localization support from WebHelp. You should follow the procedure described here: https://www.oxygenxml.com/doc/versions/ ... aid-title2
and add a localization entry for your welcome message for both English and French.
The content of the webhelp-extension-strings.xml (step 3) file should look like this:
The strings-fr-fr.xml file should look this:
The content of the strings-en-us.xml file should be:
As you can see in the two translations files (strings-en-us.xml and strings-fr-fr.xml) your welcome message has the same localization key assigned to it (i.e.: my.welcome.message).
After you finish the above procedure and integrate your newly custom localization extension plugin (step 5), you can use the WebHelp Macros support inside your webhelp.fragment.welcome HTML Fragment File to have your message localized to the current language of your DITA Map.
The content of the webhelp.fragment.welcome HTML Fragment File should be:
As you can see I have used the my.welcome.message localization key in the i18n() macro. If the root of your DITA map will have one of the following @xml:lang declarations, then the fragment will expand accordingly:
Alin
You can achieve this by using the localization support from WebHelp. You should follow the procedure described here: https://www.oxygenxml.com/doc/versions/ ... aid-title2
and add a localization entry for your welcome message for both English and French.
The content of the webhelp-extension-strings.xml (step 3) file should look like this:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<langlist>
<lang xml:lang="en" filename="strings-en-us.xml"/>
<lang xml:lang="fr" filename="strings-fr-fr.xml"/>
</langlist>
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<strings xml:lang="fr-fr">
<str name="my.welcome.message" js="true" php="false">Mon message de bienvenue</str>
</strings>
Code: Select all
<strings xml:lang="en-us">
<str name="my.welcome.message" js="true" php="false">My Welcome Message</str>
</strings>
As you can see in the two translations files (strings-en-us.xml and strings-fr-fr.xml) your welcome message has the same localization key assigned to it (i.e.: my.welcome.message).
After you finish the above procedure and integrate your newly custom localization extension plugin (step 5), you can use the WebHelp Macros support inside your webhelp.fragment.welcome HTML Fragment File to have your message localized to the current language of your DITA Map.
The content of the webhelp.fragment.welcome HTML Fragment File should be:
Code: Select all
<div class="welcome" xmlns:whc="http://www.oxygenxml.com/webhelp/components">
<whc:macro value="${i18n(my.welcome.message)}"/>
</div>
- <map xml:lang="fr-fr">
- <map xml:lang="en-us"> (this may be omitted as the default language is english)
Alin
Alin Balasa
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service