Getting an error when exporting with in5 can be overwhelming, but there is often a clue in the error box that comes up. One such culprit is InDesign’s hyperlinks, which is cited in the error in the screenshot below.
One error we’ve encountered now and then is when a hyperlink text source—the text that is clicked to jump to the hyperlink destination—contains just a blank space or where there are two hyperlinks assigned to different portions of the same word. The error mostly crops up when text is rendered with one of the HTML text options in the Export to HTML5 with in5 dialog box.
This can happen when the hyperlink itself is auto-generated from a script, though it can also happen if text isn't carefully selected when manually setting the hyperlink source.
Regardless, it’s a good idea to troubleshoot and fix the issues with hyperlinks, if you’re able. You might be able to see which page is causing the issue, as that’s often listed in the error message. Keep in mind that if there are issues throughout, only the first page might be listed. You can delete text or text frames and try to export, which helps you narrow down the troublemaker.
Once you know which text frame or general area the error is in, open the Hyperlinks panel (Window > Interactive > Hyperlinks), put your cursor in the text, and use the arrow keys to “step through” the text. You will see the hyperlink highlighted in the panel as you move through, keeping an eye out for issues mentioned earlier.
Once you spot the issue, you can fix it. Chances are you don’t need a hyperlink assigned to just a blank space, so you can select any of those hyperlinks in the panel and delete them by clicking on the trash icon at the bottom.
For the cases where multiple hyperlinks are assigned within a word, it’s going to take a little bit of fixing. If you’ve manually assigned them and it’s not difficult, you can simply select the proper text and re-assign the links. But if you’ve used a script, it may generate the same issue again, so you’ll need to manually adjust the source text.
In the sample above, there is a link assigned to “land” and another to “scape,” but we only want the link currently assigned to “scape” applied to the whole word. Select “land” and delete that hyperlink. Now select “landscape” and go to the Hyperlinks panel menu and choose Reset Hyperlink. You can always check that the markers are in place by viewing the text in the Story Editor (Command/Ctrl+Y). It is possible to adjust the link in the Story Editor but it’s very tricky as you can’t see the invisible marker… use the Reset Hyperlink option instead.
Exporting with text rendered as images doesn’t have any of these issues. You’ll find that InDesign’s hyperlinks can be a little tricky at times, but it’s a good practice to make them as smartly set up as possible for the best possible outcome.