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

184
Views
Oyente de eventos HTML5 + discord.js

Lo que quiero:

Estoy tratando de hacer que cuando se agregue o elimine un miembro del personal en mi discordia, se actualizará en el sitio web que tengo. Intenté hacer esto con node.js, pero luego no puedo usar los atributos del documento, etc. Básicamente, me pregunto si esto es posible.

Código JS:

 const headBoardOfDirectors = document.querySelector('#hbod-role'); const boardOfDirectors = document.querySelector('#bod-role'); const headAdmin = document.querySelector('#ha-role'); const seniorAdmin = document.querySelector('#sa-role'); const admin = document.querySelector('#a-role'); const headModerator = document.querySelector('#hm-role'); const moderator = document.querySelector('#m-role'); const trialModerator = document.querySelector('#tm-role'); // Below is just an example of what I am talking about. staff = [ bunch of staff roles here ] if (some member role add or remove event) { if (role added or removed is staff) { if (role name is Head Board of Directors) { headBoardOfDirectors.innerHTML = `${headBoardOfDirectors.innerHTML}\n${member name}` } } }

Código HTML:

 <div id="staff"> <table> <tr> <th class="main"></th> <th class="main">Staff</th> <th class="main"></th> </tr> <tr> <th></th> <th>Founder</th> <th></th> </tr> <tr> <td></td> <td>killrebeest#1001</td> <td></td> </tr> <tr> <th></th> <th>Owner</th> <th></th> </tr> <tr> <td></td> <td>fluffy#9459</td> <td></td> </tr> <tr> <th></th> <th>Head of Board of Directors</th> <th></th> </tr> <tr> <td></td> <td id="hbod-role"></td> <td></td> </tr> <tr> <th></th> <th>Board of Directors</th> <th></th> </tr> <tr id="bod-role"> </tr> <tr> <th></th> <th>Head Administration</th> <th></th> </tr> <tr id="ha-role"> </tr> <tr> <th></th> <th>Senior Administration</th> <th></th> </tr> <tr id="sa-role"> </tr> <tr> <tr> <th></th> <th>Administration</th> <th></th> </tr> <tr id="a-role"> </tr> <tr> <th></th> <th>Head Moderation</th> <th></th> </tr> <tr id="hm-role"> </tr> <tr> <th></th> <th>Moderation</th> <th></th> </tr> <tr id="m-role"> </tr> <tr> <th></th> <th>Trial Moderation</th> <th></th> </tr> <tr id="tm-role"> </tr> </table> </div>

Resumen:

Básicamente, principalmente quiero saber si esto es posible, lo que creo que definitivamente debería ser. Si es posible, cómo se puede hacer, o hay alguna referencia con la que pueda responder para ayudarme a resolver este problema.

Gracias,
matarrebeest

over 4 years ago · Santiago Trujillo
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!