PHP variable passing

Source: Internet
Author: User
PHP variable pass for help?
Excuse me, I have set up a public file for saving information conn.php

$isLog = true;

I want to put $islog = False in a.php;

But I query $islog or true in b.php.


Excuse me, is it not understood?
------Solution--------------------
To achieve the effect you want, use the session to save it.
------Solution--------------------
$islog = True within the conn.php file;

You refer to conn.php in a.php, change the value to False but conn.php the value of the file itself does not change
The value obtained when you b.php re-referencing conn.php must still be true

To achieve your results, use get pass, with the session can be
------Solution--------------------
If you want to change the value of the loaded variable on the page, simply override the variable on the current page, paying attention to loading the page and overriding the variable order.
  • 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.