<%=error_messages_for(f.object)%>
<%= f.label :title, :required=>true,:style =>"display:none;" %> <%= f.text_field :title, :class => "full-width",:placeholder=>"Enter title here" %>
<%=f.select :content_format,Spud::Core.renderers.collect { |k,v| [v[:description] || k, k]}, {:include_blank => false}, :class => "pull-right", "data-formatter" => "spud_post_content"%>
<%= f.text_area :content,:style => "width:100%;", :class => 'spud-formatted-editor full-width', "data-format" => f.object.content_format %>
<% if Spud::Blog.config.has_custom_fields %>
Custom Fields <%= render :partial => '/spud/admin/posts/custom_fields', :locals => {:f => f} %>
<% end %>
Advanced

Meta Data

<%= f.label :published_at, 'Publish Date' %> <%= f.text_field :published_at,:value => f.object.published_at.strftime("%Y-%m-%d %H:%M") , :class => 'spud_form_date_picker' %> <%= f.time_select :published_at, :ignore_date => true,:ampm => true%>
<% if @current_user.super_admin %>
<%= f.label :spud_user_id, 'Author' %> <%= f.select :spud_user_id,options_for_select(SpudUser.order(:first_name,:last_name,:login).all.collect{|user| [user.full_name,user.id]},f.object.spud_user_id)%>
<% else %> <%= f.hidden_field :spud_user_id %> <% end %> <% if Spud::Core.config.multisite_mode_enabled %>
<%= f.label :sites, 'Websites to Publish' %>
<%= spud_post_site_check_box_tag(Spud::Core.default_site_config, @post) %> <%= spud_post_site_label_tag(Spud::Core.default_site_config) %> <% Spud::Core.config.multisite_config.each do |site| %> <%= spud_post_site_check_box_tag(site, @post) %> <%= spud_post_site_label_tag(site) %> <% end %>
<% end %>
<%= f.label :visible %>
<%= f.radio_button :visible, true %> <%= f.radio_button :visible, false %>
<% unless @post.is_news %>
<%= f.label :comments_enabled,"Comments Enabled" %>
<%= f.radio_button :comments_enabled, true %> <%= f.radio_button :comments_enabled, false %>
<% end %>
<%= f.label :meta_keywords, 'Keywords' %> <%= f.text_field :meta_keywords %> A Comma seperated list of keywords for search engines. Keep it short (no more than 10 keywords)
<%= f.label :meta_description, 'Description' %> <%= f.text_area :meta_description %> A short description of the article. This is what appears on a search engines search result page.

Categories

<%= link_to 'Add Category', new_spud_admin_post_category_path, :class => 'btn btn-mini spud_post_add_category' %>
<%= f.hidden_field :is_news %>
<%=f.submit "Save Post", :class=>"btn btn-primary form-btn","data-loading-text"=>"Saving..."%> or <%=link_to "cancel",request.referer, :class => "btn"%>