title: how to link submit button to another page in html
body: <p>i am trying to submit a set of input and then go to a certain html page(view.html) but cant figure it out, if i use action, it won't submit the value to the database. i also used onclick on the submit button, but it wont submit the values to the database</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>const firebaseConfig = {
    apiKey: "",
    authDomain: "",
    databaseURL: "",
    projectId: "",
    storageBucket: "",
    messagingSenderId: "",
    appId: ""
  };
  firebase.initializeApp(firebaseConfig);
  var db = firebase.database();
  
  const sendMessage = () =&gt; {
  
    let sender = document.getElementById("sender").value.trim();
    let reciever = document.getElementById("reciever").value.trim();
    let message = document.getElementById("message").value.trim();
    db.ref("card").push().set({
      "sender": sender,
      "reciever": reciever,
      "message": message
    });
    document.forms[0].reset();
    let message1 = document.getElementById("message")
    message1.value = ""
    return false;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;form onsubmit="return sendMessage();" class="form_container "&gt;
  
  
    &lt;input type="text" name="" id="sender" class="card_name mx-auto" placeholder="Your Name" autocomplete="off"&gt;
    &lt;input type="text" name="" id="reciever" class="card_name_reciever mx-auto" placeholder="To who" autocomplete="off"&gt;
    &lt;textarea class="card_message mx-auto" id="message" placeholder="Message..."&gt;&lt;/textarea&gt;
    &lt;input type="submit" class="card_submit mx-auto" id="card_submit"&gt;
  
  
  &lt;/form&gt;</code></pre>
  </div>
  </div>
  </p>