Home  >  Article  >  Backend Development  >  Two methods to implement pop-up message prompt boxes using PHP_PHP Tutorial

Two methods to implement pop-up message prompt boxes using PHP_PHP Tutorial

WBOY
WBOYOriginal
2016-07-13 17:18:041949browse

Method 1:

Copy code The code is as follows:

echo "<script>alert('prompt content')< /script>";<br> </div> <br>Method 2: <br><div class="codetitle"> <span style="CURSOR: pointer" onclick="doCopy('code15882')"><u>Copy the code</u></span> The code is as follows:</div> <div class="codebody" id="code15882"> <br>echo '<script language="JavaScript">;alert("This is the location inside ";location.href="index.htm";</script>;';

. href="index.htm" indicates the page you will redirect to after clicking the OK button in the message box. Just remove it if you don't need to!

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/621683.htmlTechArticleMethod one: Copy the code as follows: echo "scriptalert('prompt content')/script"; Method two: Copy the code as follows: echo 'script language="JavaScript";alert("This is";location...
Statement:
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