Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

235
Views
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
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!