Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

125
Vistas
Pictures need to stay side by side regardless of browser size

Our project is trying to compare two pictures. We are able to have the two pictures pop up, but they just move on top of each other if we change the size of the window. We want them to stay side by side and just change the size of the image if the window changes. I've also put an example of the line of code for our images.

var stimulus =
  '<img src=' +
  'img/' +
  artistArray2_b[3] +
  '/' +
  lastName_b[3] +
  1 +
  '.jpg' +
  ' style="max-width:100%;" />, <img src =' +
  'img/' +
  artistArray2_b[3] +
  '/' +
  lastName_b[3] +
  2 +
  '.jpg' +
  ' style="max-width:100%;" />';
about 4 years ago · Santiago Gelvez
1 Respuestas
Responde la pregunta

0

change the size of the image if the window changes.

This sounds like task for using CSS viewport related unit. In this case probably vw i.e. pertaining to width (100vw = full width), consider following simple example

<html>
<head></head>
<body>
<div style="background-color:#0000FF;height:100px;width:50vw"></div>
</body>
</html>

It does provide blue div with constant height of 100px and width half of viewport that is it will shrink or elongate depending on you changing size of your browser window.

about 4 years ago · Santiago Gelvez Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda