I have build many shortcode to show somme data from a training cours. If y put a value, it works well.
[TEST_PHP cours = <script>document.write("1")</script>]
But if I try to use a const or a global var for the value, It doesent work, coursID = "" ?
<script>
const coursID = "1";
</script>
[TEST_PHP cours = <script>document.write(coursID)</script>]
How to call a shortcode in Javascript with a const als attribute ?