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

223
Views
Este atributo funciona pero el atributo id no funciona en jQuery

Usaré ajax para ingresar mensajes y agregaré ese mensaje, pero quiero desplazarme hacia abajo para chatear, pero el documento simple está listo: la función de desplazamiento hacia arriba no funciona

Aquí está el código de trabajo

 $(document).ready(function(event){ $('#chatboxouter').mouseenter(function (event) { event.preventDefault() $(this).scrollTop(400); }); });

pero no trabajar en

 $(document).ready(function(){ $('#chatboxouter').scrollTop(400); });

Aquí está el código CSS:

 #chatboxouter{ position: fixed;top: 80px;height: 80vh;width: 100%; overflow-y: scroll;background-color: navy; }

aquí está el código html

 <div class="mainouter" style=" position: fixed;top: 80px;height: calc(100vh - 160px);width: 100%; background-color: red;"> <div class="chatboxouter" id="chatboxouter"> <div class="allmessageview" style="background-color: yellow;"> Here Php input by ajax </div></div> </div>
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Si no te importa, puedes usar javascript como: -

 <script> document.querySelector(document).ready(function(){ document.querySelector('#chatboxouter').scrollTop(400); }); </script>
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!