Fulltext search does not work in code section #3836

Closed
opened 2026-02-05 07:37:44 +03:00 by OVERLORD · 6 comments
Owner

Originally created by @zden2ksobotka on GitHub (Jun 3, 2023).

Describe the Bug

When inserting a page edited in a markdown editor with embedded syntax code on multiple lines (three back apostrophes are used in markdown). After the page is saved, the markdown syntax looks ok. But a Full-text search is unable to find any result in the code section.

Steps to Reproduce

  1. Markdown editor
  2. Insert markdown syntax:
# Some headline
Some example code: 
```
rpm -i ZzZzZz   # example of text in which fulltext search will not be able to find anything.
ls -la
```

Expected Behaviour

Fulltext search in BookStack sites will be able to find string "ZzZzZz"

Screenshots or Additional Context

No response

Browser Details

No response

Exact BookStack Version

v23.05

PHP Version

No response

Hosting Environment

Debian 11, php8.2

Originally created by @zden2ksobotka on GitHub (Jun 3, 2023). ### Describe the Bug When inserting a page edited in a markdown editor with embedded syntax code on multiple lines (three back apostrophes are used in markdown). After the page is saved, the markdown syntax looks ok. But a Full-text search is unable to find any result in the code section. ### Steps to Reproduce 1. Markdown editor 2. Insert markdown syntax: <pre> # Some headline Some example code: ``` rpm -i ZzZzZz # example of text in which fulltext search will not be able to find anything. ls -la ``` </pre> ### Expected Behaviour Fulltext search in BookStack sites will be able to find string "ZzZzZz" ### Screenshots or Additional Context _No response_ ### Browser Details _No response_ ### Exact BookStack Version v23.05 ### PHP Version _No response_ ### Hosting Environment Debian 11, php8.2
OVERLORD added the 🐛 Bug label 2026-02-05 07:37:44 +03:00
Author
Owner

@esakkiraja100116 commented on GitHub (Jun 3, 2023):

image

@zden2ksobotka I can't able to find that issue. Can you please provide any screenshots like this ?

@esakkiraja100116 commented on GitHub (Jun 3, 2023): ![image](https://github.com/BookStackApp/BookStack/assets/57084732/fe831cc6-f890-4d8b-ae1f-53f18bdf78dd) @zden2ksobotka I can't able to find that issue. Can you please provide any screenshots like this ?
Author
Owner

@zden2ksobotka commented on GitHub (Jun 4, 2023):

Sorry, at first I thought it was because of the back apostrophes. But try this.:

```
rpm -i ZzZzZz   # example of text in which fulltext search will not be able to find anything.
ls -la
echo "deb [arch=amd64] http://something.com/apt-stable/ $CODENAME main"
```

I'm attaching screenshots:
Snímek obrazovky z 2023-06-04 10-44-44
Snímek obrazovky z 2023-06-04 10-45-00
Snímek obrazovky z 2023-06-04 10-45-12
Snímek obrazovky z 2023-06-04 10-45-34

@zden2ksobotka commented on GitHub (Jun 4, 2023): Sorry, at first I thought it was because of the back apostrophes. But try this.: <pre> ``` rpm -i ZzZzZz # example of text in which fulltext search will not be able to find anything. ls -la echo "deb [arch=amd64] http://something.com/apt-stable/ $CODENAME main" ``` </pre> I'm attaching screenshots: ![Snímek obrazovky z 2023-06-04 10-44-44](https://github.com/BookStackApp/BookStack/assets/48833683/070f1d76-8f6f-465d-9249-5fcb64df2d24) ![Snímek obrazovky z 2023-06-04 10-45-00](https://github.com/BookStackApp/BookStack/assets/48833683/fbbfdf2f-5020-4753-a925-599a4be7bc90) ![Snímek obrazovky z 2023-06-04 10-45-12](https://github.com/BookStackApp/BookStack/assets/48833683/fbdb8b50-f784-4fae-8b22-461c44d6a0ae) ![Snímek obrazovky z 2023-06-04 10-45-34](https://github.com/BookStackApp/BookStack/assets/48833683/9511bba7-91a7-4bd1-a4b6-407027442264)
Author
Owner

@esakkiraja100116 commented on GitHub (Jun 8, 2023):

@zden2ksobotka So apt-stable is not listed in the last snap right ?

@esakkiraja100116 commented on GitHub (Jun 8, 2023): @zden2ksobotka So `apt-stable` is not listed in the last snap right ?
Author
Owner

@zden2ksobotka commented on GitHub (Jun 9, 2023):

The Full-text search in Booksctack has probably trouble finding strings with hyphens or braces. Nothing more.

@zden2ksobotka commented on GitHub (Jun 9, 2023): The Full-text search in Booksctack has probably trouble finding strings with hyphens or braces. Nothing more.
Author
Owner

@esakkiraja100116 commented on GitHub (Jun 9, 2023):

can you put double quotes over there ?

@esakkiraja100116 commented on GitHub (Jun 9, 2023): can you put double quotes over there ?
Author
Owner

@zden2ksobotka commented on GitHub (Jun 9, 2023):

You're right! Solved.

@zden2ksobotka commented on GitHub (Jun 9, 2023): You're right! Solved.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#3836