hotcityadd.php 2.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: xiaofeng
  5. * Date: 2018/3/6
  6. * Time: 下午5:49
  7. */
  8. use backend\assets\AppAsset;
  9. AppAsset::addScript($this, Yii::$app->request->baseUrl . "/js/mini/hotcity.js");
  10. ?>
  11. <style>
  12. .layui_box {
  13. width: 80%;
  14. margin: 0 auto;
  15. margin-top: 25px;
  16. }
  17. .layui-code, .layui-upload-list {
  18. margin-top: 0;
  19. }
  20. hr {
  21. width: 100%;
  22. margin: 0 auto;
  23. }
  24. .mt {
  25. text-align: center;
  26. margin-top: 15px;
  27. }
  28. .The_house {
  29. background: #FBFBFB;
  30. color: #333;
  31. }
  32. .The_house:hover {
  33. border: 1px solid #a9a9a9;
  34. color: #333;
  35. }
  36. .xm_xcxqTc_button {
  37. margin-top: -20px;
  38. }
  39. </style>
  40. <!--[2]数组中填写不需要显示div的type-->
  41. <form class="layui-form layui-form-pane">
  42. <div class="layui_box">
  43. <div class="layui-form-item">
  44. <label class="layui-form-label">区域:</label>
  45. <div class="layui-input-inline" style="width:64%">
  46. <input type="text" name="title" placeholder="请输入区域名称" class="layui-input">
  47. </div>
  48. </div>
  49. <div class="layui-form-item">
  50. <label class="layui-form-label">地址:</label>
  51. <div class="layui-input-inline" style="width:64%">
  52. <input type="text" name="url" placeholder="请输入跳转地址" autocomplete="off" class="layui-input">
  53. </div>
  54. </div>
  55. <div class="layui-form-item xm_pr">
  56. <div class="layui-inline">
  57. <label class="layui-form-label"><span style="color:red">*</span>图片:</label>
  58. <div class="layui-inline">
  59. <div class="layui-upload">
  60. <div class="layui-upload-list lay_p_relative"> <!--低级添加 lay_p_relative-->
  61. <img class="layui-upload-img layui_magnify" name="img" src="" id="breviary_img"
  62. style="width:280px;height:90px;margin-left:10px;border:1px solid #ccc;">
  63. <p id="demoText"></p>
  64. </div>
  65. </div>
  66. </div>
  67. </div>
  68. <button type="button" class="layui-btn layui-btn-primary xm_xcxqTc_button" id="test1">选择图片</button>
  69. </div>
  70. <div class="layui-form-item mt">
  71. <input type="hidden" name="type" value="<?php echo $type ?>">
  72. <button class="layui-btn" lay-submit="" lay-filter="adds">提交</button>
  73. </div>
  74. </div>
  75. </form>