Invalid Character Imported HTML Style

Please post all questions on Help+Manual 8 here

Moderators: Alexander Halser, Tim Green

Post Reply
mscottallen
Posts: 4
Joined: Thu Sep 12, 2019 9:10 pm

Invalid Character Imported HTML Style

Unread post by mscottallen »

Hi,

Am following the instructions to normalize imported HTML styles with Premium Pack, but I can't seem to get past the first step of adding the imported styles as new styles in H&M due to invalid characters. Unsure the best way to resolve things.

The styles in the original HTML contains spaces in the style (e.g. send message).
After importing the HTML into H&M, the space in the style has been replaced with a dot (e.g. send.message).
When trying to add the style to H&M, the dot prohibits me from adding it as it's an invalid character.
If I remove the dot, I can add the style without issue.
But when I open Premium Pack to normalize the style with the rest of the imported HTML files, nothing happens since the style I added doesn't have a dot and all of the styles in the XML do have a dot.

Is there a way when importing HTML to have H&M replace the space in the style with a valid character of some sort? Or have the space deleted with the words combined (e.g. sendmessage)?

I've been using find/replace in each page's xml, but have about 10 styles to change and hoping to find an easier way.

Hope that all makes sense. Thanks for any suggestions.

Scott
Simon_Dismore
Posts: 206
Joined: Thu Jul 13, 2017 2:57 pm

Re: Invalid Character Imported HTML Style

Unread post by Simon_Dismore »

I might help if you could post a fragment of the source HTML showing these spaces. I imagine they are separating different class names?

For example, in the HTML below you'll see the contents, search and index items are all class "hmtabs", and the selected one has two classes "hmtabs" and "current":

Code: Select all

<nav id="navpane_tabs">
  <ul id="topictabs" class="tabs">
    <li id="contentstab" class="hmtabs current" title="Table of Contents">...</li>
    <li id="indextab" class="hmtabs" title="Keyword Index"><a id="indextablink">...</li>
    <li id="searchtab" class="hmtabs" title="Search Topics"><a id="searchtablink">...</li>
  </ul>
</nav>
User avatar
Tim Green
Site Admin
Posts: 23181
Joined: Mon Jun 24, 2002 9:11 am
Location: Bruehl, Germany
Contact:

Re: Invalid Character Imported HTML Style

Unread post by Tim Green »

I've been using find/replace in each page's xml, but have about 10 styles to change and hoping to find an easier way.
If you use an editor like the free Notepad++ you can do a global find/replace on all the topic files in your project's \Topics folders. (You need to save your project in the uncompressed HMXP format to get access to the topic files if you are using the single-file HMXZ format)
Regards,
Tim (EC Software Documentation & User Support)

Private support:
Please do not email or PM me with private support requests -- post to the forum directly.
Post Reply