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

384
Views
Js o jquery: abra una url con agente de usuario móvil

Necesito abrir una URL con un agente de usuario móvil... similar a la configuración del elemento de inspección del iPhone y la recarga para obtener el efecto. No importa si es una ventana abierta o un iframe, acepto todas las ideas.

Intenté configurar el agente de usuario y luego volver a cargar una ventana.abrir... pero no. Intenté obtener el html, configurar el agente de usuario, reemplazar html en window.open pero algo no se muestra como "natural".

En cuanto a ahora, estoy aquí:

 let generatedSource = new XMLSerializer().serializeToString(document); let previewWindow = window.open("about:blank", "previewMobileFrame", "width=400,height=800,resizable=0"); setUserAgent(previewWindow, 'Mozilla/5.0 (iPhone; CPU iPhone OS 12_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/69.0.3497.105 Mobile/15E148 Safari/605.1'); previewWindow.document.write(generatedSource);

O estoy en abrir mi url, cambiar el agente de usuario, volver a cargar la ventana.

Pero hay algunos SSI que obviamente no se vuelven a renderizar... y creo que setUserAgent realmente no funciona.

Breve historia: ¿cómo puedo emular "inspeccionar elemento y configurar para iphone" de Chrome y recargar en js o jquery? ingrese la descripción de la imagen aquí

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!