Update search to use new pre-combined indexes + local docs support#1586
Update search to use new pre-combined indexes + local docs support#1586derickr merged 2 commits intophp:masterfrom
Conversation
… search on local docs
… search on local docs
|
@AllenJB I hadn't noticed this made the tests fail. Can you have a look? |
|
@derickr I don't believe my changes caused these test failures. Based on manual testing, the code is doing what it always does and correctly sending the user to You can see this happen on php.net itself (in addition to testing with the My guess is that there's been a change in the Google CSE scripts causing this (hence why the tests passed when this PR was merged). Based on the PR Preview Action Logs this occurred some time on Nov 4th between 11am and 8pm GMT (between runs for PRs 665 and 666) My guess is the test needs to be updated to account for the Google CSE changes, but I'm not sure the best way to do that here. |
|
@saundefined Could you take a look? I don't have server permissions. I suspect it might be an issue with the script? web-php/.github/workflows/pr-preview.yml Lines 21 to 22 in 7d87155 The |
|
@sy-records the |


This PR is related to php/phd#212 and php/phd#204
IMPORTANT: At least one of the above 2 PRs to phd MUST be merged before this one.
These changes modify search.js to use the new pre-combined search indexes (significantly simplifying the code) added by both the above mentioned PRs.
Additionally the changes required for supporting the search on local docs (which set the language to
localto trigger the alternative behavior)The version of
search.jsused here is the same as that included in php/phd#204 . After this PR has been merged, phd can be modified to pull this copy ofsearch.jsinstead of duplicating it in the phd repository, the same as it does for stylesheets.