【发布时间】:2014-06-02 17:45:42
【问题描述】:
我正在使用 joomla 2.5。我正在尝试在 Joomla 组件自定义中读取 URL 变量或完整 URL。
我可以读取如下 URL:
http://xyz/index.php?option=com_xyz&format=raw&tmpl=component&lang=en
但我想阅读浏览器上的网址(带别名):
http://xyz/en/feedback?ID=123456&Email=abc@hotmail.com
feedback 是 Joomla 别名。我正在使用另一个 PHP 脚本中的变量重定向该 URL。
如果我尝试:
$_SERVER['HTTP_REFERER']; // not working in IE.
$_SERVER['QUERY_STRING'] //return com_xyz&format=raw&tmpl=component&lang=en
JRequest::getVar('Email'); // return NULL but works if try getVar('lang');
有没有其他解决方案或更好的方法?
【问题讨论】:
-
@felipsmartins 没有找到更多信息,你能解释一下吗。试过但同样的结果没有得到变量值。
-
@felipsmartins :- 没有意义,它们都是不同的问题。
-
你想做什么,因为你的问题不清楚。
-
想用别名和变量读取 URl
标签: php url joomla joomla2.5 http-referer