unset arg is bool:false & spell corection
add improvements and sugestions of gary-kim Co-Authored-By: Gary Kim <gary@garykim.dev>
This commit is contained in:
parent
ff4d374835
commit
38deca6a2c
8
sortt.js
8
sortt.js
@ -8,17 +8,15 @@
|
|||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
//creat global function with main routine
|
//create global function with main routine
|
||||||
window.sortt=function(normsort,revsort,isdefault){
|
window.sortt=function(normsort,revsort,isdefault){
|
||||||
//sortTable [normsort] (revsort) (isdefault)
|
//sortTable [normsort] (revsort) (isdefault)
|
||||||
|
|
||||||
//normsort is needet
|
//normsort is needet
|
||||||
if (typeof normsort === 'undefined') return false;
|
if (normsort) return false;
|
||||||
|
|
||||||
//default values of optinal parameters
|
//default values of optinal parameters
|
||||||
if (typeof revsort === 'undefined') revsort = "";
|
if (revsort) revsort = "";
|
||||||
if (typeof isdefault === 'undefined') isdefault = false;
|
|
||||||
if (!(typeof isdefault === 'boolean')) isdefault = false;
|
|
||||||
|
|
||||||
// parse URL
|
// parse URL
|
||||||
/* script check if url has already a sort=
|
/* script check if url has already a sort=
|
||||||
|
Reference in New Issue
Block a user