erok Posted August 11, 2015 Share Posted August 11, 2015 Hi all, i have php code working with INTERNET EXPLORER fine - able to insert, update, delete checkbox values. brief sections of code ; $bea=$dow['bea']; $dow1 = explode(",", $dow['len']); if(in_array(5,$dow1)) $che5="checked"; else $che5=""; if(in_array(10,$dow1)) $che10="checked"; else $che10=""; <input type="text" name="bea" value="<?php echo $bea ; ?>" /> .. <input type="checkbox" name="len[]" size="9" maxlength="20" value="5" <?php echo $che5 ; ?> /> <input type="checkbox" name="len[]" size="9" maxlength="20" value="10" <?php echo $che10 ; ?> /> same code with GOOGLE CHROME unable to retrieve checkbox values able to upload checkbox values. I tried ...$che5="checked=checked"; $che5="checked='checked'"; $che5='checked' ; not helping. Anybody who has experience wih this kind of problem? directing , pointing kindly appreciated erok Link to comment Share on other sites More sharing options...
Ingolme Posted August 11, 2015 Share Posted August 11, 2015 Have you checked the source code to verify that the checked attribute is actually being applied? Link to comment Share on other sites More sharing options...
erok Posted August 11, 2015 Author Share Posted August 11, 2015 Thanks for reply i just did it i see this <input type="checkbox" name="len[]" size="9" maxlength="20" value="10" checked /> // checked attribute is actually being applied with chrome Link to comment Share on other sites More sharing options...
erok Posted August 11, 2015 Author Share Posted August 11, 2015 Hi. I tested with FIREFOX it is working fine - able to insert, update, delete checkbox values. same code with OPERA unable to retrieve checkbox values able to upload and update checkbox values. regards Link to comment Share on other sites More sharing options...
Ingolme Posted August 11, 2015 Share Posted August 11, 2015 Is there any Javascript on your page that's manipulating the checkboxes? Also, when testing the page, don't refresh it, go to the address bar and press Enter to reload the page. When you refresh the page, some browsers keep the values that the inputs had, so if a checkbox was unchecked it will remain unchecked. Link to comment Share on other sites More sharing options...
erok Posted August 11, 2015 Author Share Posted August 11, 2015 There is a little javascript. But unrelated, different part of the code. just to say good evening etc. Page suppose to retrieve information related to user. If, in previous visit user checked e.g. trans or short or long. That information suppose to appear at user personal page when he/she logged in. If user needs to make changes, he/she should be able make changes and keep the other informations unchanged as previous visit. Problem as i said before, CHROME and OPERA unable to retrive data from phpmyadmin. Actually when i use var_dump i see the variable values in there, Chrome unable hold onto it. Chrome unable to process it. INTERNET EXPLORER and FIREFOX able to. Link to comment Share on other sites More sharing options...
justsomeguy Posted August 11, 2015 Share Posted August 11, 2015 Browsers do not retrieve data from MySQL, the browser is not the problem. The problem is the PHP code you're using to generate the HTML that the browser renders. What code are you using now? If you're producing output that is going to look like what you wrote in post 3 then that's all you need to do (for checkboxes, anyway). Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now