Edit or Updating record Problem |
[eluser]sheru[/eluser]
Dear All, I am learning the codeignter. I am stuck on validation run. When I edit a record it validates false and do nothing. Code: if ($this->validation->run() == FALSE){ <--- as this becomes false and runs the code here and as it did not execute else part so id did not update record. Thank you for helping me. Sheru
[eluser]tonanbarbarian[/eluser]
you will need to include the validation rules you have setup and the view file so we can see the form fields that are created
[eluser]boldyellow[/eluser]
Sometimes it's easier to troubleshoot a problem if you simplify the form. Start with just two or three fields, validate the inputs and see what's not working.
[eluser]sheru[/eluser]
Dear tonanbarbarian and boldyellow, I am sorry I became unable to post immediately, By the way, Thank you both for your valuable post and taking some time to help me. I admire you both. Many thanks. I really don't know what caused it but as I played on set_rules, it took me on success part of $this->validation->run() but did not update the record but as I set the record id as hidden way, it really updated the record as well. By the way, I am having problem in populating selected database value in dynamic drop-downs. I have used two tables for this drop-down values, one is children table where I store organization_id, but actually having name from partnerorg table which has prgid and partnername fields. Your help and pointer needed. Sheru
[eluser]Pensacola1989[/eluser]
[quote author="boldyellow" date="1287989782"]Sometimes it's easier to troubleshoot a problem if you simplify the form. ?? Start with just two or three fields, validate the inputs and see what's not working.[/quote] |
Welcome Guest, Not a member yet? Register Sign In |