在 zen-cart 中找不到原始页面
我有一个脚本,在每个页面的末尾记录我的 zen-cart 网站上的页面访问。最近,我注意到 page_not_found 页面有很多点击。我试图追溯这些步骤来找出访问者想要访问的页面,但运气不佳。有没有办法使用 PHP 获取最初请求的页面和 $_GET 变量,以触发 zen-cart 中的 page_not_found ?我尝试使用 $_SERVER 变量中的变量,但它们为 $_SERVER['SCRIPT_FILENAME'] 返回 index.php,为 URI 返回 $_SERVER['QUERY_STRING'] 的 main_page=page_not_found 。例如,zen-cart 设置的 $_SERVER 是否有一些替代变量包含原始参数?
I have a script that logs page visits on my zen-cart site at the end of every page. Lately, I have been noticing a lot of hits to the page_not_found page. I am trying to retrace the steps to figure out what page(s) the visitors are trying to go to, but with minimal luck. Is there someway to get the page and $_GET variables that were originally requested that triggered the page_not_found in zen-cart using PHP? I tried using the variables in the $_SERVER variable, but they return index.php for $_SERVER['SCRIPT_FILENAME'], and main_page=page_not_found for the $_SERVER['QUERY_STRING'] for the URI. For instance, is there some alternate variable to $_SERVER that zen-cart sets that contains the original parameters?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
它被覆盖在includes/init_includes/init_sanitize.php第125行中,
您可以保存该值并在稍后的日志记录中引用它。
It's overwritten in includes/init_includes/init_sanitize.php line 125
You could save this value off and refer to it later in your logging.