javascript – Add music to html page according to the function output-ThrowExceptions

Exception or error:

I want my HTML page to voice out the numbers when they get displayed on the page as an output from a function. Code is as follows

<html lang="en">
    .home_text {
     color: #ff0026;
     font-size: 150pt;
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <meta name="description" content="">
    <meta name="author" content="">
    <title>Goplan Project Selection</title>

    <link rel="canonical" href="">

    <!-- Bootstrap core CSS -->
    <link href="" rel="stylesheet">
    <script src=""></script>

  <div class="jumbotron">
  <div class="text-center">
        <img src="cissoiree.jpg" width="80px" height="80px">
    <div style="padding-top:5px;" class="text-center">
      <button class="btn-lg btn-primary" onclick="grandom()">Click!</button><br>
      <h1 class="home_text" id="demo"><h1>
    var q=[2,3,1,5,4,7,6];
    var x=7;
    function grandom()
    var i;
            var random;

                random = Math.floor(Math.random()*x);
            document.getElementById("demo").innerHTML = q[random];

            q.splice(random,1); }

I want my page to play audios of numbers(which I have) in the background according to the result from
from grandom(). Chrome is my browser.

How to solve:

Leave a Reply

Your email address will not be published. Required fields are marked *