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

192
Views
JavaScript no funciona en Thymeleaf y Spring Boot

JavaScript no funciona en Thymeleaf. En Spring Boot Thymeleaf, lo primero que puede hacer es abrir modal.

pero segundo, tercero... las cosas no pueden abrir modal.

cada cosa tiene un className. pero solo lo primero puede abrir modal.

Creo que JavaScript solo funciona en lo primero y no funciona en otras cosas.

 <tr th:each="board, i : ${boards}"> <th scope="row" th:text="${i.count}">1</th> <td> <p id="show" th:text="${board.title}">Title</p> <div class="modal"> .... </modal> </td> <td th:text="${board.writer}">이재윤</td> <td th:text="${board.createDate}">2022-02-01</td></p> </tr>

js

 function show() { document.querySelector(".background").className = "background show"; } function close() { document.querySelector(".background").className = "background"; } document.querySelector("#show").addEventListener("click", show); document.querySelector("#close").addEventListener("click", close);
about 4 years ago · Juan Pablo Isaza
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!