• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Warning - bookmarks in dropdowns do not work if they start with a number

Participant ,
Apr 15, 2024 Apr 15, 2024

Copy link to clipboard

Copied

RH 2022.3.93

Frameless output

---

Just a heads-up for people who use bookmarks in dropdowns: do not start bookmark IDs with a number in a dropdown. If you make a link to a bookmark starting with a number and click on the link, you will be directed to the general topic but the dropdown will fail to expand.

 

e.g. in topic B you have a dropdown with two bookmarks:

 <p><a class="dropspot" data-rhwidget="DropSpot" data-target="drop-down" href="#">dropdownz</a></p>
<div class="droptext" data-targetname="drop-down">
  <p><a id="test1"></a>test1</p>
  <p><a id="1test"></a>1test</p>
</div>

WoutJacobs_0-1713191129353.png

 

Create a topic A and add links to both bookmarks (hyperlinks or crossrefs both exhibit the same problem).

The first link will successfully auto-open the dropdown, the second will not.

WoutJacobs_1-1713191374657.png

Views

108

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 15, 2024 Apr 15, 2024

Copy link to clipboard

Copied

Sounds a bit like a bug - shouldn't make any difference what it starts with (special characters excepted, I imagine). Maybe you should log it with the Tracker (https://tracker.adobe.com/)?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 15, 2024 Apr 15, 2024

Copy link to clipboard

Copied

In HTML4 'name' and 'id' couldn't begin with a number.

"ID and NAME tokens must begin with a letter ([A-Za-z]) and may be followed by any number of letters, digits ([0-9]), hyphens ("-"), underscores ("_"), colons (":"), and periods (".")."

In HTML the only requirements are they must not contain white space, cannot be empty and must be unique to the page.

 

However, MDN still recommends not starting an id with a letter (and sticking with only letters, digits, _ and - ).

https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 16, 2024 Apr 16, 2024

Copy link to clipboard

Copied

LATEST

To clarify, I'm talking about the html specs here. The first paragraph is about the HTML4 spec and the second paragraph is about the HTML5 spec.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
RoboHelp Documentation
Download Adobe RoboHelp