Chrome browser under Isset ($_post[' submit ') does not return ture

Source: Internet
Author: User
Can be successful under IE, but not under Chrome, is it a bug in the browser itself?


Reply to discussion (solution)

Paste code to.
Chrome is the most respected standard, only to say that your code is not in line with the standards of the place

Chrome Right-"review element-" NETWORK. View the information.

if (Isset ($_post[' submit1 ')) {
echo "You like the following languages:
";
foreach ($_post[' lang ') as $lang) {
$lang =htmlentities ($lang);
echo "$lang
";
}
}

There's no problem with the code, how did you test it? What version of Chrome.

18.0.1025.151 Direct Chrome View

Did you order the submission?

Let's see if you have post ' submit1 ' ...

Well, IE9 was right, and I was wondering if Chrome can't return a form by $_post the data type of the Submit

Did you order the submission?

There is.

Let's see if you have post ' submit1 ' ...

How come there's a law? Where do you judge it from?

There is.

Reference to the 7 floor of the reply:

Let's see if you have post ' submit1 ' ...

IE9 is able to print out the post-submit form content, which I pass through post, and then get the $_post

How come there's a law? Where do you judge it from?

Reference to the 9 floor of the reply:

There is.

Reference to the 7 floor of the reply:

Let's see if you have post ' submit1 ' ...

$_post[' submit1 ' can get to submit1 this string

You go to GG browser and see if you have GG developer tools.

$_post[' submit1 ' can get to submit1 this string

Note Cache

Chrome is problematic, but use the value of the Submit button as much as possible. In addition, if you use JavaScript form.submit (), IE does not submit. It is recommended to use hidden variables.

Direct print $_post See if there's any

Direct print $_post See if there's any
+1
You first look at your $_post array if there are values, if the array is empty, then your decision must be wrong, because there is no such array element exists. And to avoid recurring submissions, it's better to submit your form with JavaScript.

I also encountered the same problem, through IE with POST to submit arrays no problem, but Chrome does not, with Print_r ($_post) do not see the committed array variables.

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.