index.php 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: chenkuan
  5. * Date: 2017/12/15
  6. * Time: 上午11:13
  7. */
  8. use yii\helpers\Url;
  9. ?>
  10. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  11. <html xmlns="http://www.w3.org/1999/xhtml">
  12. <head>
  13. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  14. <title>BIT System 后台管理平台</title>
  15. <?php include(Yii::getAlias("@cp_module_views")."/common/css_js_main.php") ?>
  16. <script language="javascript">
  17. $(document).ready(function() {
  18. function jump(count) {
  19. window.setTimeout(function(){
  20. count--;
  21. if(count > 0) {
  22. $('#num').html(count);
  23. jump(count);
  24. } else {
  25. <?php if($redirectUrl) { ?>
  26. window.location.href = "<?= $redirectUrl ?>"
  27. <?php } else { ?>
  28. window.history.back();
  29. <?php } ?>
  30. }
  31. }, 1000);
  32. }
  33. jump(5);
  34. });
  35. </script>
  36. </head>
  37. <body id="main">
  38. <div class="main-nav"> <span class="fn-left">错误!</span> <span class="fn-right"><a href="javascript:javascript:history.go(-1);"><i class="icon-chevron-left"></i>返回</a></span>
  39. <div class="fn-clear"></div>
  40. </div>
  41. <div class="main-content">
  42. <div class="form-or-table">
  43. <div class="success-error well">
  44. <p></p>
  45. <div class="alert alert-error"> <i class="icon-remove"></i>
  46. <?= isset($tip) ? $tip : '您的操作失败!' ?>
  47. </div>
  48. <p> 5秒后自动跳转,当前还剩<span id="num">5</span>秒。<a class="btn btn-primary fn-right" href="javascript:redirectUrl();" onclick="javascript:redirectUrl();">确定</a></p>
  49. <p class="fn-clear"></p>
  50. </div>
  51. </div>
  52. </div>
  53. </body>
  54. <script type="text/javascript">
  55. function redirectUrl() {
  56. <?php if($redirectUrl) { ?>
  57. window.location.href = "<?= $redirectUrl ?>"
  58. <?php } else { ?>
  59. window.history.back();
  60. <?php } ?>
  61. }
  62. </script>
  63. </html>