[Pro] Javascript for Search Field, Safari problems

Walter, you have not failed me. Nevertheless, I don’t want any Submit buttons. To me, that is a bit retro. I like the “type and hit return” approach.

So I did more research and found I could leverage the browser cache to resolve the Safari problem, as per this page:

I edited my JavaScript and confirmed it is working in Edge on Win10, IE11 on Win8.1, Safari, Chrome (even Chrome 36 on WinXP), FF (even FF48 on XP), and iOS 10 & iOS8.1 via the iOS Simulator on my Mac.

Try it:

https://kiramek.com/search-test2.html

Type “alarm” and hit return. Notice how the search results appear just fine. Then click the browser BACK button. Form gets reset perfectly! (No keywords stuck in the search field.)

–James W.


dynamo mailing list
email@hidden
Update your subscriptions at: