Please select To the mobile version | Continue to access the desktop computer version
| |
| | |

CodersClub

 Forgot password?
 Register
Search
View: 2039|Reply: 6
Collapse the left

Enter search words bug

[Copy link]

 United States

Post time: 2019-2-19 01:34
| Show all posts |Read mode
Hey Vot/Codersclub,

I wish you a Happy New Year!

A silly bug which I didn't notice so far. My search bar shows the text "Enter search content" by default as shown in the attached image. Every time when I need to perform a search, I have to delete the text first and then enter keywords which is a pain for users. If I delete that text, I get "Enter search words" and unlike before, it allows me to type any text without deleting which is same as your site.




Can you fix this problem or let me know how to do it?

Cheerios...............


This post contains more resources

You have to Login for download or view attachment(s). No Account? Register

x
Post time: 2019-2-21 16:20
| Show all posts
The problem is easy to solve,You just edit template/default/common/pubsearchform.htm
Find
  1. <td class="scbar_txt_td"><input type="text" name="srchtxt" id="scbar_txt" value="{lang enter_content}" autocomplete="off" x-webkit-speech speech /></td>
Copy the Code


Modified to
  1. <td class="scbar_txt_td"><input type="text" name="srchtxt" id="scbar_txt" placeholder="{lang enter_content}" autocomplete="off" x-webkit-speech speech /></td>
Copy the Code



Rate

Number of participants 1Rating +1 Collapse Reason
vot + 1 Good job!

View Rating Log

 United States

 Author| Post time: 2019-2-22 18:54
| Show all posts
roxmake 2019-2-21 16:20
The problem is easy to solve,You just edit template/default/common/pubsearchform.htm
Find

great tip roxmake!

@vot: Quick revision already! I figured out, you annotated the the lang_js file with a comment regarding this. Now after this  placeholder change, does it mean the lang_template.php will take preference over the js file or vice versa? Can the js "enter_search_string" be deleted.

I am really happy since I am able to find things quickly after using Discuz for almost an year. Credit goes to codersclub folks.

Cheerios.........


 Russia

Post time: 2019-2-22 19:49
| Show all posts
does it mean the lang_template.php will take preference over the js file or vice versa?

No it does not. And vice versa does not too
Can the js "enter_search_string" be deleted.

No. That value "enter_search_string" is still used
in a case when your browser is not compatible with the modern "placeholder" attribute.

 United States

 Author| Post time: 2019-2-26 11:48
| Show all posts
vot 2019-2-22 19:49
No it does not. And vice versa does not too

No. That value "enter_search_string" is still used

thanks vot!

If it works, I have an other bug fix for you.

Background -> Forum -> Forum Management -> Add new Forum -> here, can the placeholder attribute be added to "New forum name"?



Cheerios.........


This post contains more resources

You have to Login for download or view attachment(s). No Account? Register

x

 Russia

Post time: 2019-2-27 20:51
| Show all posts
Did you read the forum rules?

One bug = One thread!

 United States

 Author| Post time: 2019-2-28 14:29
| Show all posts
vot 2019-2-27 20:51
Did you read the forum rules?

One bug = One thread!

Oops! I forgot. Will do it right away buddy.

You have to log in before you can reply Login | Register

Points Rules

Archive|Mobile|Dark room|CodersClub  

2019-11-19 00:25 GMT+3 , Processed in 0.103567 sec., 10 queries .

Powered by Discuz! X3.4

Release 20170801, © 2001-2019 Comsenz Inc.

MultiLingual version, Rev. 710, © 2009-2019 codersclub.org

Quick Reply To Top Return to the list