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

79
Vistas
return text between rather than value

I am learning as i go here, apologize for something that should seem simple, but I can't figure it out. I have a <select> with multiple options, and am trying to build an order summary before check out. Everything is working, except the value is being returned for the selected option. IS there an easy solution that would allow the value to stay in place and just have the text of the option be returned on the order summary?

$(document).ready(function() {
  $("select#option2").change(function() {
    var selectedOption2 = $(this).children("option:selected").val();
    $('.mk-step-2 span').text(selectedOption2);
  });
});
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<select id="option2">
  <option value="" disabled selected hidden> Your Choice... </option>
  <option value="option-1">option one</option>
  <option value="option-2">option two</option>
</select>

about 4 years ago · Juan Pablo Isaza
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