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

237
Vistas
In CI3, How do you pass js edited textbox input value from view to controller?

I've been trying to pass textbox input value

<input type="text" class="form-control" name="XField" id="XField" placeholder="X">

that was edited via javascript like document.getElementById("XField").value = '1' to the controller by calling $this->input->post('XField') or even using $_POST, but it wont return anything. it's like $this->input->post('XField') will only get the user inputted value, not the manually edited value via js because all my other textbox input value that was inputted by user got properly extracted by $this->input->post('XField') or $_POST. I also already tried using $('#XField').val(1) but still wont get me anything.

So, How do i get the manually defined/edited value of input textbox from the view to the controller?or how do i manually define/edit the textbox value as if it was coming from the user(if my assumption is true that input post wont catch manually edited value)?

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