Нема описа
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145
  1. {include file="header.htm" /}
  2. <body class="bodystyle" style="overflow-y: scroll; cursor: default; -moz-user-select: inherit;">
  3. <div id="toolTipLayer" style="position: absolute; z-index: 9999; display: none; visibility: visible; left: 95px; top: 573px;"></div>
  4. <div id="append_parent"></div>
  5. <div id="ajaxwaitid"></div>
  6. <div class="page">
  7. {include file="bar.htm" /}
  8. <form class="form-horizontal" id="post_form" action="{:weapp_url('Makewaphtml/Makewaphtml/edit')}" method="post">
  9. <div class="ncap-form-default">
  10. <dl class="row">
  11. <dt class="tit">
  12. <label for="title"><em>*</em>网站名称</label>
  13. </dt>
  14. <dd class="opt">
  15. <input type="text" name="title" value="{$row.title|default=''}" id="title" class="input-txt">
  16. <span class="err"></span>
  17. <p class="notic"></p>
  18. </dd>
  19. </dl>
  20. <dl class="row">
  21. <dt class="tit">
  22. <label for="url"><em>*</em>网址URL</label>
  23. </dt>
  24. <dd class="opt">
  25. <input type="text" name="url" placeholder="http://" value="{$row.url|default=''}" id="url" class="input-txt">
  26. <span class="err"></span>
  27. <p class="notic"></p>
  28. </dd>
  29. </dl>
  30. <dl class="row">
  31. <dt class="tit">
  32. <label for="logo"><em>*</em>上传Logo</label>
  33. </dt>
  34. <dd class="opt">
  35. <div class="input-file-show div_logo_local" {neq name="$row.is_remote" value="0"}style="display: none;"{/neq}>
  36. <span class="show">
  37. <a id="img_a_local" target="_blank" class="nyroModal" rel="gal" href="{$row.logo_local|default='javascript:void(0);'}">
  38. <i id="img_i_local" class="fa fa-picture-o" {notempty name="$row.logo_local"}onmouseover="layer_tips=layer.tips('<img src={$row.logo_local|default=''} class=\'layer_tips_img\'>',this,{tips: [1, '#fff']});"{/notempty} onmouseout="layer.close(layer_tips);"></i>
  39. </a>
  40. </span>
  41. <span class="type-file-box">
  42. <input type="text" id="logo_local" name="logo_local" value="{$row.logo_local|default=''}" class="type-file-text" autocomplete="off">
  43. <input type="button" name="button" id="button1" value="选择上传..." class="type-file-button">
  44. <input class="type-file-file" onClick="GetUploadify(1,'','weapp','img_call_back','{:U('Uploadify/upload')}')" size="30" hidefocus="true" nc_type="change_site_logo"
  45. title="点击前方预览图可查看大图,点击按钮选择文件并提交表单后上传生效">
  46. </span>
  47. </div>
  48. <input type="text" id="logo_remote" name="logo_remote" value="{$row.logo_remote|default=''}" placeholder="http://" class="input-txt" {neq name="$row.is_remote" value="1"}style="display: none;"{/neq}>
  49. &nbsp;
  50. <label><input type="checkbox" name="is_remote" id="is_remote" value="1" {eq name="$row.is_remote" value="1"}checked="checked"{/eq} onClick="clickRemote(this, 'logo');">远程图片</label>
  51. <span class="err"></span>
  52. <p class="notic">建议尺寸 88 * 31 (像素) 的gif或jpg文件</p>
  53. </dd>
  54. </dl>
  55. <dl class="row">
  56. <dt class="tit">
  57. <label for="sort_order">排序</label>
  58. </dt>
  59. <dd class="opt">
  60. <input type="text" name="sort_order" value="{$row.sort_order|default='100'}" id="sort_order" class="input-txt">
  61. <span class="err"></span>
  62. <p class="notic">越小越靠前</p>
  63. </dd>
  64. </dl>
  65. <dl class="row">
  66. <dt class="tit">
  67. <label for="intro">网站备注</label>
  68. </dt>
  69. <dd class="opt">
  70. <textarea rows="5" cols="80" id="intro" name="intro" style="height:80px;" placeholder="备注一些站长联系方式、信息等内容">{$row.intro|default=''}</textarea>
  71. <p class="notic"></p>
  72. </dd>
  73. </dl>
  74. <dl class="row">
  75. <dt class="tit">
  76. <label>新窗口打开</label>
  77. </dt>
  78. <dd class="opt">
  79. <div class="onoff">
  80. <label for="target1" class="cb-enable {if condition='$row.target eq 1'}selected{/if}">是</label>
  81. <label for="target0" class="cb-disable {if condition='$row.target eq 0'}selected{/if}">否</label>
  82. <input id="target1" name="target" value="1" type="radio" {if condition="$row.target eq 1"} checked="checked"{/if}>
  83. <input id="target0" name="target" value="0" type="radio" {if condition="$row.target eq 0"} checked="checked"{/if}>
  84. </div>
  85. <p class="notic"></p>
  86. </dd>
  87. </dl>
  88. <div class="bot">
  89. <input type="hidden" name="id" value="{$row.id}">
  90. <a href="JavaScript:void(0);" onclick="checkForm();" class="ncap-btn-big ncap-btn-green" id="submitBtn">确认提交</a>
  91. </div>
  92. </div>
  93. </form>
  94. </div>
  95. <script type="text/javascript">
  96. // 判断输入框是否为空
  97. function checkForm(){
  98. if($('input[name=url]').val() == ''){
  99. showErrorMsg('网址URL不能为空!');
  100. $('input[name=url]').focus();
  101. return false;
  102. }
  103. if($('input[name=title]').val() == ''){
  104. showErrorMsg('网站名称不能为空!');
  105. $('input[name=title]').focus();
  106. return false;
  107. }
  108. if ($('input[name=typeid]:checked').val() == 2) {
  109. if ($('input[name=is_remote]').is(':checked')) {
  110. if($('input[name=logo_remote]').val() == ''){
  111. showErrorMsg('请上传网站Logo图片!');
  112. $('input[name=logo_remote]').focus();
  113. return false;
  114. }
  115. } else {
  116. if($('input[name=logo_local]').val() == ''){
  117. showErrorMsg('请上传网站Logo图片!');
  118. $('input[name=logo_local]').focus();
  119. return false;
  120. }
  121. }
  122. }
  123. layer_loading('正在处理');
  124. $('#post_form').submit();
  125. }
  126. function img_call_back(fileurl_tmp)
  127. {
  128. $("#logo_local").val(fileurl_tmp);
  129. $("#img_a").attr('href', fileurl_tmp);
  130. $("#img_i").attr('onmouseover', "layer_tips=layer.tips('<img src="+fileurl_tmp+" class=\\'layer_tips_img\\'>',this,{tips: [1, '#fff']});");
  131. }
  132. $(function(){
  133. $('input[name=typeid]').click(function(){
  134. var val = $(this).val();
  135. if (val == 2) {
  136. $('.typeid2').show();
  137. } else {
  138. $('.typeid2').hide();
  139. }
  140. });
  141. });
  142. </script>
  143. {include file="footer.htm" /}