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

113
Vistas
Added aditional part of url after search form

I found form for search button overhere but I need added in url aditional text after search form input. For example url is www.111.com/search/static/

We need to replase "search" from form text below & added /static/ part in url after

<form onsubmit="window.location = 'https://111.com/' + search.value; return false;">

<input id="search" placeholder="Search" type="search" name="search"></input>
<input type="submit" value="Send">
</form>

I need replase "search" for text inputed in form

For example we put in form "12345" our url must be https://111.com/12345/static

if we put 5678 it will be https://111.com/5678/static

thx

about 4 years ago · Juan Pablo Isaza
1 Respuestas
Responde la pregunta

0

(Answer edited after clarification from vasya vasya.)

If I got it right this time, you have a "template" URL like https://111.com/search/static/. And you want the term search to be replaced by the actual search string, like the example in your comment.

To do so, you would use:

<form onsubmit="window.location = 'https://111.com/' + document.getElementById('search').value + '/static'; return false;">

The getElementById accesses the input element via its id attribute and then the value function returns the text entered.

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