-
-
Save shlomif/d111290dab4c4469b635 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script type="text/javascript"> | |
var settid = "sitelocked"; | |
var status2 = false; | |
var data = { "sitelocked":true, "officelocked":false, "paging":20 }; | |
if(status2 === true){ | |
console.log('ITS TRUE'); | |
data[settid] = status2; | |
}else if(status2 === false){ | |
console.log('ITS FALSE'); | |
data[settid] = status2; | |
} | |
console.log(data); | |
alert(JSON.stringify(data)); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment