Sha256: 1ea8ed8f3b32e809e716773c114fb8795d140afb97dad8d26b3c5b6003b2c0e9
Contents?: true
Size: 985 Bytes
Versions: 1
Compression:
Stored size: 985 Bytes
Contents
<%=form_for @page,:url => admin_page_path(:id => @page.id),:html=>{:class=>"form-horizontal page_form",:target => "report" } do |f|%> <%=render :partial => "form",:locals => {:f => f}%> <div class="form-actions"> <%=f.submit "Save Page", :class=>"btn btn-primary btn-save" %> <%=f.submit "Preview", :class=>"btn btn-info btn-preview"%> or <%=link_to "cancel",admin_pages_path,:class => "btn"%> </div> <%end%> <br /> <script type="text/javascript"> $(document).ready(function() { $('input[type=submit].btn-preview').click(function(evt) { $(this).button('reset') $('#preview').val(1); var form = $('form.page_form')[0]; form.onsubmit = function() { window.open('about:blank','preview_window','width=500,height=400') }; form.target = 'preview_window'; }); $('input[type=submit].btn-save').click(function(evt) { $('#preview').val(0); var form = $('form.page_form')[0]; form.onsubmit = null; form.target = null; }); }); </script>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
tb_cms-1.1.0 | app/views/admin/pages/edit.html.erb |