:怎么限定来自某页的提交

WBOY
Release: 2016-06-13 13:10:31
Original
793 people have browsed it

求救:如何限定来自某页的提交?
我想实现这么个功能,

目的页面判断 来源页面 的 ajax 提交,

并且判断是否是来自限定的一个来源页面,比如 log_in.php,

如果不是,那么就跳转到/目录下

怎么做?

------解决方案--------------------

HTML code
$.ajax({
url: your-url, 
dataType: "html",
type: 'POST', 
data: 'something=1',
success: function(data){
...
}
});
<br><font color="#e78608">------解决方案--------------------</font><br>
$_SERVER['HTTP_REFERER'] <div class="clear">
                 
              
              
        
            </div>
Copy after login
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