PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
that's because unchecked checkboxes are not posted at all.
If checked they are transmitted as name=On$_POST['name']='On'
You might test this e.g. with isset($_POST['name']) && $_POST['name']=='On'
You also need to be careful if you are building an array of them. When you build the html use checkbox[0], checkbox[1]... instead of checkbox[], checkbox[]. If you don't do this then the rows in your array will not match up because PHP only builds the array with the 'on' values.
ok, so the problem can be solved by testing if the variable exist with isset()? Then I can make the script print the variable if it exist, and not print it if doesn't?
By the way, is there any connection with checkboxes and global variables? On my local webserver I have global turned off. But on my webhotel they are turned on. On the webhotell this error doesn't accour at all.
The reason why the error message doesn't appear when you run your script on your host's server is not to do with register_globals but to do with the level of error reporting being used.