edit.html 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. <include file="public@header"/>
  2. </head>
  3. <body>
  4. <div class="wrap">
  5. <ul class="nav nav-tabs">
  6. <li><a href="{:url('link/index')}">{:lang('ADMIN_LINK_INDEX')}</a></li>
  7. <li><a href="{:url('link/add')}">{:lang('ADMIN_LINK_ADD')}</a></li>
  8. <li class="active"><a>编辑友情链接</a></li>
  9. </ul>
  10. <form method="post" class="form-horizontal js-ajax-form margin-top-20" action="{:url('link/editPost')}">
  11. <div class="form-group">
  12. <label for="input-link_name" class="col-sm-2 control-label">名称<span class="form-required">*</span></label>
  13. <div class="col-md-6 col-sm-10">
  14. <input type="text" class="form-control" id="input-link_name" name="name" value="{$link.name}">
  15. </div>
  16. </div>
  17. <div class="form-group">
  18. <label for="input-link_url" class="col-sm-2 control-label">链接地址<span class="form-required">*</span></label>
  19. <div class="col-md-6 col-sm-10">
  20. <input type="text" class="form-control" id="input-link_url" name="url" value="{$link.url}">
  21. </div>
  22. </div>
  23. <div class="form-group">
  24. <label for="input-link_image" class="col-sm-2 control-label">图标</label>
  25. <div class="col-md-6 col-sm-10">
  26. <input type="text" class="form-control" id="input-link_image" name="image" value="{$link.image}">
  27. <a href="javascript:uploadOneImage('图片上传','#input-link_image');">上传图片</a>
  28. </div>
  29. </div>
  30. <div class="form-group">
  31. <label for="input-target" class="col-sm-2 control-label">打开方式</label>
  32. <div class="col-md-6 col-sm-10">
  33. <select class="form-control" name="target" id="input-target">
  34. <foreach name="targets" item="vo">
  35. <php>$link_target_selected=$link['target']==$key?"selected='selected'":"";</php>
  36. <option value="{$key}" {$link_target_selected}>{$vo}</option>
  37. </foreach>
  38. </select>
  39. </div>
  40. </div>
  41. <div class="form-group">
  42. <label for="input-link_description" class="col-sm-2 control-label">描述</label>
  43. <div class="col-md-6 col-sm-10">
  44. <textarea class="form-control" name="description"
  45. id="input-link_description">{$link.description}</textarea>
  46. </div>
  47. </div>
  48. <div class="form-group">
  49. <div class="col-sm-offset-2 col-sm-10">
  50. <input type="hidden" name="id" value="{$link.id}">
  51. <button type="submit" class="btn btn-primary js-ajax-submit">{:lang('SAVE')}</button>
  52. <a class="btn btn-default" href="{:url('link/index')}">{:lang('BACK')}</a>
  53. </div>
  54. </div>
  55. </form>
  56. </div>
  57. <script src="__STATIC__/js/admin.js"></script>
  58. </body>
  59. </html>