Search broken
daattali opened this issue · comments
Discussed in #1230
Originally posted by talonx October 31, 2023
My site repo is https://github.com/talonx/talonx.github.io/ and the site is live at https://code.deepinspace.net/
The search function does not seem to work at all. The search box comes up but nothing more happens when I type or press Enter. Anything I might be doing wrong?
Firefox 118.0.2 on Ubuntu 22 (snap).
Thanks for reporting. I can see from a quick look at the javascript console on your webpage that this is likely an issue with not properly escaping the search information.
This is what I'm seeing in the console:
And looking at the HTML, I see this:
I'll try to take a look to fix when I find time. Feel free to help with a PR as well if you can.
@talonx I'm keeping track of your issue here
Thanks for reporting. I can see from a quick look at the javascript console on your webpage that this is likely an issue with not properly escaping the search information.
This is what I'm seeing in the console:
And looking at the HTML, I see this:
I'll try to take a look to fix when I find time. Feel free to help with a PR as well if you can.
Ah I did notice this but did not realize it might be related.
Thanks for tracking it.
The problem was that you used an apostrophe in the file name. I did not think about having to escape file names, but it's now fixed. You'll have to use the latest version
The problem was that you used an apostrophe in the file name.
Ah - that happened when I imported some older posts into Jekyll.
Thanks for the quick turnaround. Would you be putting this in a release sometime soon?
i.e. I want to pin my Jekyll version to avoid other possible issues.
Yes of course, it will be in the next release. But I do suggest not using apostrophes (or any non alphanumeric/slashes/underscores) in file names, not just because of this issue, but in general it's not a good idea.
For now I've renamed the files and the problem is resolved. I'll upgrade the theme in the next release.
Thanks a lot for responding and resolving this so quickly.