Uncaught ReferenceError: selectBox is not defined

Good day guys. In my view.list.php, I extended the query using this function


But when I use the clear filter (the button beside filter button), it returns me an error.

Uncaught ReferenceError: selectBox is not defined.

I am using v7.10 .

Im sorry, this is the function

to those who haven’t figured this out and don’t have time/choices left (like me). I did a little trick which is not recommended. Use jQuery.

  1. Remove the ONCLICK attribute of clear filter button.
  1. Trigger the CLEAR button in SEARCH/FILTER FORM.

3.Then trigger the SEARCH button in SEARCH/FILTER FORM


Again. This is recommended ONLY IF you have no more time/choices left. Good luck.

There is a non-existent variable referenced somewhere. This variable needs to be declared, or you need to make sure it is available in your current script or scope otherwise , it will endup throwing this ‘selectBox’ is not defined error . This usually indicates that your library is not loaded and JavaScript does not recognize the ‘selectBox’.

To solve this error: Load your library at the beginning of all your scripts.

There can be multiple other reasons for this issue:

  • Added JavaScript library after the script were you see that error
  • Conflict with Other JavaScript Libraries
  • Path to JavaScript library you included is not correct
  • The jQuery library file is corrupted
  • May be a chance where you are working offline