How to pass parameters with `include`?

前端 未结 6 1360
醉梦人生
醉梦人生 2021-02-15 16:50

I have a PHP script called customers.php that is passed a parameter via the URL, e.g.:

http://www.mysite,com/customers.php?employeeId=1

Inside my customers.php s

6条回答
  •  闹比i
    闹比i (楼主)
    2021-02-15 17:48

    You can use $GLOBALS to solve this issue as well.

     $tit = "Hello";
    
     $GLOBALS["docTitle"] =  $tit;
    
     include ("my.php");
    

提交回复
热议问题