Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

191
Views
Estoy usando la base de datos en tiempo real de Firebase para almacenar datos de mi página html después de hacer clic en el botón Insertar, pero no está agregando datos en la base de datos.
 <!DOCTYPE html> <html> <head> <title>FIREBASE/DATABASE</title> </head> <body> RollNo <input id="rollbox" type="text"></input><br><br> Name <input id="namebox" type="text"></input><br><br> Gender <input id="genbox" type="text"></input><br><br> <button id="insert">INSERT</button> <button id="select">SELECT</button> <button id="delete">DELETE</button> <script src="https://www.gstatic.com/firebasejs/9.6.1/firebase-app.js"></script> <script src="https://www.gstatic.com/firebasejs/9.6.1/firebase-auth.js"></script> <script src="https://www.gstatic.com/firebasejs/9.6.1/firebase-database.js"></script> <script id="MainScript"> const firebaseConfig = { apiKey: "AIzaSyD0h3tnkshN4rjSA9Iju08ntGJ72SM2LlY", authDomain: "fir-3d4fe.firebaseapp.com", projectId: "fir-3d4fe", storageBucket: "fir-3d4fe.appspot.com", messagingSenderId: "1055090212601", appId: "1:1055090212601:web:26a02d69edade66cf0ac28" }; var name,roll,gender; function Ready(){ name=document.getElementById("rollbox").value; roll=document.getElementById("namebox").value; gender=document.getElementById("genbox").value; } document.getElementById("insert").onclick=function(){ Ready(); firebase.database().ref('student/'+rollv).set({ nameOfStudent:name, rollNo:roll, genderOfStudent:gender }) } </script> </body> </html>

Arriba está el código de mi página html para agregar datos a la base de datos en tiempo real de firebase. Pero no está agregando datos después de hacer clic en el botón Insertar. Por favor, ayúdame con mi código. Quiero que mi código solo agregue datos de campos de entrada a la base de datos en tiempo real de firebase, verifique el código.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Oye, no has definido de dónde viene rollv, esto es undefine que da undefine en el camino de la referencia.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!