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

303
Views
Iframe check for the response after submitting the form in React

I have been trying to embed Iframe in my react js project. The issue i am facing is that the source of Iframe is an external url which returns HTML form to me and then when i submit that form, they hit their own api to validate data and return HTML for success or failure.

So i need to access some specific classnames in order to know whether my response is successfull or not like

alert-success for success response
alert-failure for failed response

This is my code below for that

<iframe
              id="one"
              src={`https://xxxxxxxxx.com/Payments/xxxxxx?id=12232331&pais=pt&aseguradora=dg&nombre=CustomerName&apellidos=CustomerSurname&codPostal=CustomerPostalCode`}
              width="100%"
              height="300"
            ></iframe>

Now how can i access the classname in order to find response for that form, or is there any other workaround for this ?

tried var iframe = document.getElementsByTagName("iframe")[0];

but then I cannot access any classnames here or even after submitting the form (for alert-success or alert failure)

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!