Retrieving Multiple Search Results from the Same Document

26 views
Skip to first unread message

Jeffrey Spitz

unread,
Apr 8, 2021, 3:47:15 PMApr 8
to sphinx-users
Hello,

I noticed that when searching words on www.sphinx-doc.org and other sites like alabaster.readthedocs.io, the search would return multiple results on the same page as long as the word appears under different subsections. 

Screen Shot 2021-04-08 at 12.38.42 PM.png
Screen Shot 2021-04-08 at 12.46.17 PM.png


However when performing searches in my own documentation, the search will only return a single result per document even if it exists in multiple subsections.

Screen Shot 2021-04-08 at 12.39.42 PM.png
Screen Shot 2021-04-08 at 12.40.24 PM.png

How can i configure my search so that it can return multiple results from the same document?

Regards,
Jeffrey

Stefano David

unread,
Aug 27, 2021, 5:20:32 AMAug 27
to sphinx-users
Hello

I think I stumbled upon this exact issue on some of my projects: If a html page contains multiple instances of a word I am serching, only the first one is shown.

Odd enough, this issue arises only on a few of them and this makes it is difficult for me to find the root cause. Searching in the configuration and templates of the mentioned projects lead me nowhere. Has anyone ever experienced this? Does someone have any hint to help me investigate? Or it's me misunderstanding how search works?

Note: I also tried to use alabaster as theme, but without any luck, so I guess it must be some configuration issue, but there seems to be no related option in conf.py.

Thank you in advance,
Stefano
 
Reply all
Reply to author
Forward
0 new messages