Skip to content

PHP获取该脚本文件名的几种方式区别

示例URL:
http://feizhaojun.com/sample/get-script-name/test-name.php?test-key=test-value

输出结果:
$_SERVER[‘ORIG_PATH_INFO’]:
$_SERVER[‘URL’]:
$_SERVER[‘SCRIPT_NAME’]:/sample/get-script-name/test-name.php
$_SERVER[‘SCRIPT_FILENAME’]:/home/wwwroot/feizhaojun.com/sample/get-script-name/test-name.php
$_SERVER[‘REQUEST_URI’]:/sample/get-script-name/test-name.php?test-key=test-value
$_SERVER[‘PATH_TRANSLATED’]:
$_SERVER[‘PHP_SELF’](PATH_TRANSLATED):/sample/get-script-name/test-name.php

领支付宝红包:打开支付宝搜索 726845401

领饿了么红包:0fυィ直文本 e:/$XGzEgR8$~.👉饿了么App👈【快來領外賣紅包,最高20元,人人都有哦~】

 

您的赞助将会鼓励作者技术文章创作以及支持本站运维。

发表评论

Your email is never published nor shared. Required fields are marked *


TOP