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

96
Views
Agregar cuadro de comentarios al hacer clic en el botón

Me gustaría agregar un código HTML a mi página cuando se hace clic en un botón, esto es lo que me gustaría agregar

 <form action="#" id="Reactie_form"> <input id="Form_voornaam" type="text" placeholder="Voornaam" style="width: 50%"> <br> <input id="Form_achternaam" type="text" placeholder="Achternaam" style="width: 50%"><br> <input id="Form_email" type="email" placeholder="E-mail" style="width: 50%"> <textarea id="Form_bericht" style="width: 100%"></textarea> <input id="files" type="file" @change="fileSelected" multiple accept=".png, .jpg, .webp, jpeg, .gif"> <input type="button" class="sendButt" value="Verstuur" @click="submitReactie"> </form> <span v-if="!files || !files.length"></span> <ul v-else> <li v-for="files in files" :key="files.name">{{ files.name }}</li> </ul>

Gracias

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

0

Veo que estás usando VueJS. ¡Esto hace que algo así sea fácil!

Como lo haría es de la siguiente manera:

agregue lo siguiente a sus data() : isClicked: false

envuelva su código en un contenedor como este:

 <div v-if='isClicked'> <form action="#" id="Reactie_form"> <input id="Form_voornaam" type="text" placeholder="Voornaam" style="width: 50%"> <br> <input id="Form_achternaam" type="text" placeholder="Achternaam" style="width: 50%"><br> <input id="Form_email" type="email" placeholder="E-mail" style="width: 50%"> <textarea id="Form_bericht" style="width: 100%"></textarea> <input id="files" type="file" @change="fileSelected" multiple accept=".png, .jpg, .webp, jpeg, .gif"> <input type="button" class="sendButt" value="Verstuur" @click="submitReactie"> </form> <span v-if="!files || !files.length"></span> <ul v-else> <li v-for="files in files" :key="files.name">{{ files.name }}</li> </ul> </div>

y en lo siguiente a su botón: <button @click='isClicked = true'>

about 4 years ago · Juan Pablo Isaza Report

0

Envuelva su código y agregue el contenedor contenedor como una clase oculta. luego puede obtener el evento de clic y alternar el css por javascript.

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!