Footer not displayed in Webhelp output with webhelp.footer.file
Post here questions and problems related to editing and publishing DITA content.
Footer not displayed in Webhelp output with webhelp.footer.file
I'm fairly new to customizing DITA transforms, so apologies in advance for such a basic question but I'm tearing my hair out trying to get a logo to display in the footer of my Webhelp output. I'm using oXygen 15.2 with DITA OT 1.7. I have a well-formed XHTML file that consists only of an image:
I have edited the Webhelp transformation scenario and set the path of the webhelp.footer.file parameter to point to the above file. When I run the transform, however, I only see the "alt" text and not the actual logo. I've spent hours reading through the documentation and searching the Web, but I can't find a solution anywhere.
Could anybody please tell me what I might be doing wrong here?
Thanks!
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Company Logo</title>
</head>
<body>
<img src="logo.jpg" alt="Logo goes here"/>
</div>
</body>
</html>
Could anybody please tell me what I might be doing wrong here?
Thanks!
-
- Posts: 222
- Joined: Tue Jul 01, 2014 11:48 am
Re: Footer not displayed in Webhelp output with webhelp.footer.file
Post by bogdan_cercelaru »
Hello,
Your logo image does not appear because it doesn't exists where the browser expects it to be. Your HTML fragment will be added in every topic file and the topics will be in various folders. The img element uses a relative path to the "logo.jpg" image but the image is not there.
If you will publish your WebHelp to a web server, than you can manually copy your image to a location on your server and refer it using the absolute path. Supposing that your logo is located into "image" folder in the root directory of the website, your footer file will be:
Another way to have your image correctly displayed in the footer is to use a base64 image for your logo. You can encode the actual logo and than your footer file will look like:
Regards,
Bogdan
Your logo image does not appear because it doesn't exists where the browser expects it to be. Your HTML fragment will be added in every topic file and the topics will be in various folders. The img element uses a relative path to the "logo.jpg" image but the image is not there.
If you will publish your WebHelp to a web server, than you can manually copy your image to a location on your server and refer it using the absolute path. Supposing that your logo is located into "image" folder in the root directory of the website, your footer file will be:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Company Logo</title>
</head>
<body>
<img src="/image/logo.jpg" alt="Logo goes here"/>
</div>
</body>
</html>
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Company Logo</title>
</head>
<body>
<img src="data:image/png;base64, iVBORw0KGgoAAAANSUhEUgAAAAUAAAAFCAYAAACNbyblAAAAHElEQVQI12P4//8/w38GIAXDIBKE0DHxgljNBAAO9TXL0Y4OHwAAAABJRU5ErkJggg==" alt="Logo goes here - red dot example" />
</div>
</body>
</html>
Bogdan
Bogdan Cercelaru
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Re: Footer not displayed in Webhelp output with webhelp.footer.file
Thanks Bogdan! I tried replacing the relative path with an absolute one but when I ran the transform again, nothing was displayed in the footer at all (not even the alt text). Your suggestion about the base64 encoding worked for me though
Return to “DITA (Editing and Publishing DITA Content)”
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