警告错误修正

This commit is contained in:
thinkphp
2015-12-11 23:16:43 +08:00
parent 272a680bd7
commit 8e51b36c2f
2 changed files with 4 additions and 2 deletions

View File

@@ -105,8 +105,9 @@ class Url
// 解析URL和参数 域名
protected static function parseUrl($url, $vars, $domain)
{
$info = parse_url($url);
$url = !empty($info['path']) ? $info['path'] : ACTION_NAME;
$info = parse_url($url);
$url = !empty($info['path']) ? $info['path'] : ACTION_NAME;
$anchor = '';
if (isset($info['fragment'])) {
// 解析锚点
$anchor = $info['fragment'];