Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

129
Visualizações
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 Respostas
Responde à pergunta

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 Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda