Copy link to clipboard
Copied
At my company, we're looking to implement a new help method for a SaaS-based website. It requires both:
I'm running into an issue with #1. Here's what's going on:
Looking into it, I saw that RoboHelp writes links using relative paths ("../../MoreInfo/X.htm" vs "~/help/MoreInfo/X.htm").
The problem we're running into is that the relative paths for links are taking into account the page they're being displayed on, rather than the project. This is due to how the information is being loaded: not as a standalone window pop-up, but as an embedded div, integrated into the page:
<div class="modal" id="divhelpinfopopup">
<ul class="modal-menu">
<li class="close-menu-button" title="Close" onclick="$('#divhelpinfopopup').hide();">
<span aria-hidden="true" class="icon-close pull-right"></span>
</li>
</ul>
<h3>Help</h3>
<div class="modal-content" id="divhelpcontent">
</div>
</div>
Example: If I'm on http://example.com/UserFinancials/Cashflow/page.htm and I click Help for the Cashflow section, http://example.com/help/Financial/Users/Cashflow.htm comes up. However, when I click on the "More Information" link, the system looks for ../../MoreInfo/X.htm -- but it's doing the ../ relative to the web page (http://example.com/UserFinancials/Cashflow/page.htm) rather than the help page (http://example.com/help/Financial/Users/Cashflow.htm). The final URL is therefore http://example.com/MoreInfo/X.htm, instead of http://example.com/help/MoreInfo/X.htm.
So my question: Is there any way for me to insert an absolute path for links (/help/) instead of relative paths (../../) without using the standard shell (/help/index.htm)?
I realize this may be a complicated question, and that the only answer may be "hard code links or use the shell", but I thought I'd try. Haven't seen this addressed anywhere.
Thanks in advance
Copy link to clipboard
Copied
Hi,
If I understand the problem correctly, I see two ways of going forward:
1. Hard code the entire URL.
2. Calculate the correct URL with JavaScript. I have a JS function for that on: http://www.wvanweelden.eu/blog/2012/08/03/get-relative-link-project-root
Greet,
Willam