A detailed explanation of PHP pop-up dialog box skills. Many programmers use the 1. PHP pop-up dialog box? PHPechoscriptlanguageJavaScriptalert (hello); script ;? Or? PHPprintscriptlanguageJavaScriptalert (hello); many programmers use
1. PHP pop-up dialog box
- <? PHP
- Echo"<ScriptLanguage =
"JavaScript">Alert
("Hello ");</Script>";
- ?>
Or
- <? PHP
- Print"<ScriptLanguage =
"JavaScript">Alert
("Hello ");</Script>";
- ?>
2. if you need a PHP pop-up dialog box and then return to the original page, you can write it like this.
- <? PHP
- Echo "<script language =
"JavaScript"> rn ";
- Echo "alert (" Hello "); rn ";
- Echo "history. back (); rn ";
- Echo "</script> ";
- Exit;
- ?>
Or
- <? PHP
- Print "<script language =
"JavaScript"> rn ";
- Print "alert (" Hello "); rn ";
- Print "history. back (); rn ";
- Print "</script> ";
- Exit;
- ?>
3. if the PHP pop-up dialog box is required, replace the original page with a new page (replace the current history). The original page can be written in this way.
- <? PHP
- Echo "<script language =
"JavaScript"> rn ";
- Echo "alert (" Hello "); rn ";
- Echo "location. replace
("Http://www.asm32.net /");
Rn "; // modify the website by yourself
- Echo "</script> ";
- Exit;
- ?>
Or
- <? PHP
- Print "<script language =
"JavaScript"> rn ";
- Print "alert (" Hello "); rn ";
- Print "location. replace
("Http://www.asm32.net /");
Rn "; // modify the website by yourself
- Print "</script> ";
- Exit;
- ?>
When 1. PHP pop-up dialog box? PHP echo script language = JavaScript alert (hello);/script ;? Or? PHP print script language = JavaScript alert (hello );/...