[eluser]Tim Brownlaw[/eluser]
[quote author="maddtechwf" date="1397941841"]...
This is the code I have written in my model but it doesn't seem to be working when it comes to the vehicle_to_user db.
[/quote]
Instead of one of us just giving you the answer, let's see if we can help you find it yourself!
The real question is "I don't understand what is going on here...."
So let's see if we can remedy that!
Ok so what you need to do is go from the end and work your way back to the the start!
You've generated a checkbox(s) on your Form! This is where you are wanting to get the information from and this is the bit that's "not happening!" or getting into your DB.
Time to do some "looking"!
So the first thing to check is - what is the HTML being generated for the checkbox!
Is it correct? Is it what you are expecting?
What is the Name of the Checkbox?
What do you see in your posted information when you
1. Check No Checkboxes
2. Check One Checkbox
3. Check ALL Checkboxes
How do you see what it's returning?
The simple way is to do a var_dump($_POST) - the good ole fashioned way and see exactly what is coming back from your form... That is if you are using method="post" in your form!
I'll leave it there for now and see what you discover!
Cheers
Tim