context-sensitive help links break in Chrome and IE
Oxygen general issues.
-
- Posts: 86
- Joined: Sun May 03, 2015 7:34 pm
- Location: San Francisco
context-sensitive help links break in Chrome and IE
Post by urbanrobots »
Hello,
If a person views the webhelp in Chrome or IE, the webhelp links break after they click OK to the error about JavaScript. Is there any way to suppress this error message and automatically load the frameset version of the webhelp? We want to be able to link to any page in the webhelp no matter what browser a person uses.
Here is the error from Chrome for reference:
Take care,
- Nick
If a person views the webhelp in Chrome or IE, the webhelp links break after they click OK to the error about JavaScript. Is there any way to suppress this error message and automatically load the frameset version of the webhelp? We want to be able to link to any page in the webhelp no matter what browser a person uses.
Here is the error from Chrome for reference:
Thanks for your help.Chrome limits JavaScript functionality when a page is loaded from the local disk. This prevents the normal help viewer from loading.
You will be redirected to the frameset version of the help.
Take care,
- Nick
-
- Posts: 222
- Joined: Tue Jul 01, 2014 11:48 am
Re: context-sensitive help links break in Chrome and IE
Post by bogdan_cercelaru »
Hello,
To automatically load the frameset version of the WebHelp when you use it locally, you should edit the "OXYGEN_DIR/frameworks/dita/DITA-OT/plugins/com.oxygenxml.webhelp/oxygen-webhelp/resources/skins/desktop/toc_driver.js" file, changing the following code (line 47):
with:
Using this code, the browser will pass the contextId parameter to the frameset version of WebHelp.
Let me know if you need any further assistance.
Regards,
Bogdan
To automatically load the frameset version of the WebHelp when you use it locally, you should edit the "OXYGEN_DIR/frameworks/dita/DITA-OT/plugins/com.oxygenxml.webhelp/oxygen-webhelp/resources/skins/desktop/toc_driver.js" file, changing the following code (line 47):
Code: Select all
var warningMsg = 'Chrome limits JavaScript functionality when a page is loaded from the local disk. This prevents the normal help viewer from loading.\nYou will be redirected to the frameset version of the help.';
if (confirm(warningMsg)) {
// using Chrome to read local files
redirect('index_frames.html');
} else {
alert ("Not all features are enabled when using Google Chrome for webhelp loaded from local file system!");
var warningSign = '<span id="warningSign"><img src="oxygen-webhelp/resources/img/warning.png" alt="warning" border="0"></span>';
$('#productTitle .framesLink').append(warningSign);
$('#warningSign').mouseenter(function () {
$('#warning').show();
});
$('#warningSign').mouseleave(function () {
$('#warning').hide();
});
var warning = '<div id="warning">Not all features will be enabled using Google Chrome for webhelp loaded from local file system!</div>';
$('#productTitle .framesLink').append(warning);
};
Code: Select all
var p;
try {
p = parseUri(window.location.href);
} catch (e) {
debug(e);
}
redirect('index_frames.html?' + p.query);
Let me know if you need any further assistance.
Regards,
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
-
- Posts: 86
- Joined: Sun May 03, 2015 7:34 pm
- Location: San Francisco
Re: context-sensitive help links break in Chrome and IE
Post by urbanrobots »
Hi, Bogdan --
Thanks for the information. I like how the user does not need to interact with an error message to access the webhelp. However, this does not solve the problem of context-sensitive links. If you try to directly access a file that is not index_frames.html, does the webhelp load the page or does it just load index_frames.html? For me, any link to a specific file just loads index_frames.html and not the specific HTML page.
Is there a way to capture the file name in the JavaScript so that the page loads index_frames.html#<file_name>.html instead?
Thanks,
- Nick
Thanks for the information. I like how the user does not need to interact with an error message to access the webhelp. However, this does not solve the problem of context-sensitive links. If you try to directly access a file that is not index_frames.html, does the webhelp load the page or does it just load index_frames.html? For me, any link to a specific file just loads index_frames.html and not the specific HTML page.
Is there a way to capture the file name in the JavaScript so that the page loads index_frames.html#<file_name>.html instead?
Thanks,
- Nick
-
- Posts: 222
- Joined: Tue Jul 01, 2014 11:48 am
Re: context-sensitive help links break in Chrome and IE
Post by bogdan_cercelaru »
There is no easy way to do that.urbanrobots wrote: Is there a way to capture the file name in the JavaScript so that the page loads index_frames.html#<file_name>.html instead?
Instead, you can use the contextId parameter to link to specific file from your WebHelp. Here you can find more information regarding this parameter: Output Formats / WebHelp Output / Context-Sensitive WebHelp System.
Using that parameter, the modified code will automatically redirect your users to the frameset version of WebHelp, which will load the requested page.
Best regards,
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
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