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

369
Views
JQuery. I have to access an element in html by using this keyword in a click event, but for some reason it does not work

My problem is that this key word does not give me the html element. I'm using it in a click event.

enter image description here

It simply does no react when i click and thats all, no errors no nothing.

JS Code:

$(document).ready(function () {

    $('.question-toggle-button').click(() => {
        $(this).addClass("question-active");
    });
});

Also the HTML:

                    <div class="question">
                        <div class="question-top-row">
                            <div class="question-top-left">
                                <div class="question-number">
                                    01
                                </div>
                            </div>
                            <div class="question-top-center">
                                <div class="question-question">
                                    Что делает сервис?
                                </div>
                            </div>
                            <div class="question-top-right">
                                <div class="question-toggle-button">
                                    <img src="./img/cross.png" alt="">
                                </div>
                            </div>
                        </div>
                        <div class="question-bottom-row">
                            <div class="question-answer">
                                Lorem ipsum dolor sit, amet consectetur adipisicing elit. Tenetur totam iste ab repellat, vero ea ut soluta dolor quas ullam asperiores aliquam dicta commodi dolorem esse quis sunt dolore quo!
                            </div>
                        </div>
                    </div>
about 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!