获取上一页面id

WBOY
Release: 2016-06-23 13:56:38
Original
1639 people have browsed it


获取上一页面的id,但是输出的结果为FALSE,
求请教


回复讨论(解决方案)

请问你上一个页面是否有传递post值,传递的url指向当前这个php文件么?

var_dump($_POST);
看看,希望回答对你有帮助。

我觉得很奇怪,页面居然有ID??

输出false
是你var_dump($result);查询无数据吧?


这是上一个页面的值

其他方面应该没有错误

你上一个页面输出的$resurt['id']是否有值,还有就是确定URL是否正确传递

你确定是$_POST[file_id];而不是$_POST[‘file_id’];

#5 截图中显示 file_id 是 url 变量
你用 $_POST['file_id'] 当然取不到值
要用 $_GET['file_id'] 才行

$field = $_GET['field'];

使用超连接的属于GET方式传输,使用$_GET来获取。

谢谢,我已经解决了

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!