14

On a collective page (e.g.: Google Cloud), there are two question lists with the same ID.

The DOM view in the developer tools shows two adjacent <div>s with id="question".

This makes it difficult to select the second question list containing the questions using a userscript, since getElementById / querySelector returns the first element with that ID.


FWIW, I’m developing a new userscript to display more information about questions for frontpage / question lists: QuestionListsHelper, and came across this issue.

  • Shows you mini image and code previews, post text length count, and how many favourited.
  • Comment previews on hover.

Example screenshot of the points above.

  • Shows who hammered or which mod closed the question.

Example screenshot of the points above.

1
  • 4
    Thanks for pointing this out! We will fix this and add an answer to this question when it's fixed :).
    – JD-Stack Staff
    Commented Mar 3, 2022 at 15:29

1 Answer 1

4

Thank you for pointing this out. This request has been implemented and there is now only one element with the questions ID.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .