PHP pop-up dialog box to implement redirection sample code

怪我咯
Release: 2017-07-11 16:15:47
Original
1354 people have browsed it

First explain, the relationship between page jump and page redirection?

Page redirection must have page jump, page jump does not necessarily have page redirection, that is to say, page redirection is really included in page jump, and page redirection is not sufficient for page jump. Necessary conditions.

Below we introduce several methods to obtain the redirect url:

1 Use js to implement

The code is as follows:

if(!$this->userInfo){ $alert_msg = "激活链接错误"; echo""; //redirect(base_url()); die; }
Copy after login

2 php The code to implement

is as follows:

if(!$this->userInfo){ $alert_msg = "激活链接错误"; echo"";//这种方式没有弹窗效果 why? 加上exit 会有弹窗,后续也会重定向; redirect(base_url()); die; }
Copy after login

The above is the detailed content of PHP pop-up dialog box to implement redirection sample code. For more information, please follow other related articles on the PHP Chinese website!

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
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!