expertmode.htm 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. <% if not self.embedded then %>
  2. <form method="post" enctype="multipart/form-data" action="<%=REQUEST_URI%>">
  3. <div>
  4. <script type="text/javascript" src="<%=resource%>/cbi.js"></script>
  5. <input type="hidden" name="cbi.submit" value="1" />
  6. </div>
  7. <% end %>
  8. <div class="cbi-map" id="cbi-<%=self.config%>">
  9. <% if self.title and #self.title > 0 then %><h2><a id="content" name="content"><%=self.title%></a></h2><% end %>
  10. <%- if self.message then %>
  11. <p class="message success"><%=self.message%></p>
  12. <%- end %>
  13. <%- if self.errmessage then %>
  14. <p class="message error"><%=self.errmessage%></p>
  15. <%- end %>
  16. <% if self.description and #self.description > 0 then %><div class="cbi-map-descr"><%=self.description%></div><% end %>
  17. <% self:render_children() %>
  18. </div>
  19. <% if not self.embedded then %>
  20. <div class="cbi-page-actions">
  21. <%-
  22. if type(self.hidden) == "table" then
  23. for k, v in pairs(self.hidden) do
  24. -%>
  25. <input type="hidden" id="<%=k%>" name="<%=k%>" value="<%=pcdata(v)%>" />
  26. <%-
  27. end
  28. end
  29. %>
  30. <% if redirect then %>
  31. <div style="float:left">
  32. <input class="cbi-button cbi-button-link" type="button" value="<%:Back to Overview%>" onclick="location.href='<%=pcdata(redirect)%>'" />
  33. </div>
  34. <% end %>
  35. <%- if self.flow and self.flow.skip then %>
  36. <input class="cbi-button cbi-button-skip" type="submit" name="cbi.skip" value="<%:Skip%>" />
  37. <% end %>
  38. <%- if self.submit ~= false then %>
  39. <input class="cbi-button cbi-button-save" type="submit" name="cbi.apply" value="
  40. <%- if not self.submit then -%><%-:Submit-%><%-else-%><%=self.submit%><%end-%>
  41. " />
  42. <% end %>
  43. <%- if self.reset ~= false then %>
  44. <input class="cbi-button cbi-button-reset" type="reset" value="
  45. <%- if not self.reset then -%><%-:Reset-%><%-else-%><%=self.reset%><%end-%>
  46. " />
  47. <% end %>
  48. <%- if self.cancel ~= false and self.on_cancel then %>
  49. <input class="cbi-button cbi-button-reset" type="submit" name="cbi.cancel" value="
  50. <%- if not self.cancel then -%><%-:Cancel-%><%-else-%><%=self.cancel%><%end-%>
  51. " />
  52. <% end %>
  53. <script type="text/javascript">cbi_d_update();</script>
  54. </div>
  55. </form>
  56. <% end %>