[GH-ISSUE #171] [BUG] Enter key does work from search results page #123

Closed
opened 2026-02-25 20:34:57 +03:00 by kerem · 1 comment
Owner

Originally created by @g4jc on GitHub (Jan 19, 2021).
Original GitHub issue: https://github.com/benbusby/whoogle-search/issues/171

Describe the bug
A clear and concise description of what the bug is.

To Reproduce
Steps to reproduce the behavior:

  1. Search for anything
  2. Enter a new search term on search results page (e.g. https://whoogle.sdf.org/search )
  3. Press Enter key
  4. Nothing Happens

Additional context
The input field is labeled as type="text" rather than type="search", assuming this behavior was not intended, something like this should fix it:

--- a/app/templates/header.html
+++ b/app/templates/header.html
@@ -9,12 +9,12 @@
                 </a>
                 <div class="H0PQec" style="width: 100%;">
                     <div class="sbc esbc autocomplete">
+                        <input name="tbm" value="{{ search_type }}" type="hidden">
                         <input id="search-bar" autocapitalize="none" autocomplete="off" class="noHIxc" name="q"
                                style="background-color: {{ '#000' if dark_mode else '#fff' }};
                                        color: {{ '#685e79' if dark_mode else '#000' }};
                                        border: {{ '1px solid #685e79' if dark_mode else '' }}"
-                               spellcheck="false" type="text" value="{{ query }}">
-                        <input name="tbm" value="{{ search_type }}" style="display: none">
+                               spellcheck="false" type="search" value="{{ query }}">
                         <div class="sc"></div>
                     </div>
                 </div>
@@ -32,12 +32,12 @@
             <form id="search-form" class="search-form" id="sf" method="POST">
                 <div class="autocomplete" style="width: 100%; flex: 1">
                     <div style="width: 100%; display: flex">
+                        <input name="tbm" value="{{ search_type }}" type="hidden">
                         <input id="search-bar" autocapitalize="none" autocomplete="off" class="noHIxc" name="q"
-                               spellcheck="false" type="text" value="{{ query }}"
+                               spellcheck="false" type="search" value="{{ query }}"
                                style="background-color: {{ '#000' if dark_mode else '#fff' }};
                                        color: {{ '#685e79' if dark_mode else '#000' }};
                                        border: {{ '1px solid #685e79' if dark_mode else '' }}">
-                        <input name="tbm" value="{{ search_type }}" style="display: none">
                         <div class="sc"></div>
                     </div>
                 </div>

Originally created by @g4jc on GitHub (Jan 19, 2021). Original GitHub issue: https://github.com/benbusby/whoogle-search/issues/171 **Describe the bug** A clear and concise description of what the bug is. **To Reproduce** Steps to reproduce the behavior: 1. Search for anything 2. Enter a new search term on search results page (e.g. https://whoogle.sdf.org/search ) 3. Press Enter key 4. Nothing Happens **Additional context** The input field is labeled as `type="text" ` rather than `type="search"`, assuming this behavior was not intended, something like this should fix it: ``` --- a/app/templates/header.html +++ b/app/templates/header.html @@ -9,12 +9,12 @@ </a> <div class="H0PQec" style="width: 100%;"> <div class="sbc esbc autocomplete"> + <input name="tbm" value="{{ search_type }}" type="hidden"> <input id="search-bar" autocapitalize="none" autocomplete="off" class="noHIxc" name="q" style="background-color: {{ '#000' if dark_mode else '#fff' }}; color: {{ '#685e79' if dark_mode else '#000' }}; border: {{ '1px solid #685e79' if dark_mode else '' }}" - spellcheck="false" type="text" value="{{ query }}"> - <input name="tbm" value="{{ search_type }}" style="display: none"> + spellcheck="false" type="search" value="{{ query }}"> <div class="sc"></div> </div> </div> @@ -32,12 +32,12 @@ <form id="search-form" class="search-form" id="sf" method="POST"> <div class="autocomplete" style="width: 100%; flex: 1"> <div style="width: 100%; display: flex"> + <input name="tbm" value="{{ search_type }}" type="hidden"> <input id="search-bar" autocapitalize="none" autocomplete="off" class="noHIxc" name="q" - spellcheck="false" type="text" value="{{ query }}" + spellcheck="false" type="search" value="{{ query }}" style="background-color: {{ '#000' if dark_mode else '#fff' }}; color: {{ '#685e79' if dark_mode else '#000' }}; border: {{ '1px solid #685e79' if dark_mode else '' }}"> - <input name="tbm" value="{{ search_type }}" style="display: none"> <div class="sc"></div> </div> </div> ```
kerem 2026-02-25 20:34:57 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@benbusby commented on GitHub (Jan 19, 2021):

Thanks for the heads up -- fixed in github.com/benbusby/whoogle-search@5c69283e80.

<!-- gh-comment-id:762950202 --> @benbusby commented on GitHub (Jan 19, 2021): Thanks for the heads up -- fixed in https://github.com/benbusby/whoogle-search/commit/5c69283e802468ffa0de8844b217fdedfc4d730d.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/whoogle-search#123
No description provided.