I'm scripting a small RP game Text base. I found a site with chance.js script free to use but I am trying to find out how to use it within PHP.
This is the code they tell you to use:
<script src="chance.js"></script>
<script>
console.log(chance.bool());
</script>
But every time I put it in my PHP it blacks out everything and does not work. I have tried to search everywhere to try and find out why but found nothing. A lot of sites say I can't use JavaScript in PHP, but I know that can't be true.
Please, someone point me in the right direction... :)
P.S. the replay with be true or false http://chancejs.com/ <<< is the site it's from.