= form_for(@page_localization, :url => url, :html => {:class => "auto_save"}) do |f| = gb_error_messages_for(@page_localization) .span5 .tabbable .versions.page_content_form - if Gluttonberg.localized? && Gluttonberg::Locale.all.length > 1 .btn-group %a{ :class => "btn dropdown-toggle" , "data-toggle" => "dropdown", :href => "#"} Editing #{@page_localization.locale.name} Content %span.caret %ul.dropdown-menu - for locale in Gluttonberg::Locale.all - localization = Gluttonberg::PageLocalization.where(:page_id => @page.id , :locale_id => locale.id).first %li= link_to("Edit #{locale.name} Content", edit_admin_page_page_localization_path( :page_id => @page.id, :id => localization.id), :class => "") - unless @page_localization.contents.blank? = version_listing(@page_localization.versions , (@version.blank? ? @page_localization.version : @version )) %ul.nav.nav-tabs %li.active %a{:href => "#content", "data-toggle" => "tab" } Content %li %a{:href => "#seo", "data-toggle" => "tab" } SEO .tab-content .tab-pane.active#content .pad %p = f.label :name = f.text_field(:name, :id => "page_title", :class => "span5") %p #page_slug_holder %span.domain #{current_domain}#{@page_localization.path_without_self_slug} #page_slug %span{:donotedit => true} = @page_localization.slug || @page.slug - if f.object.slug.blank? - f.object.slug = @page.slug = f.text_field(:slug, :id => 'page_hidden_slug') .edit.btn.btn-mini Edit URL = link_to("View Page", @page.current_localization.public_path, :class => "btn btn-mini", :target => "_blank") = link_to("Preview", "Javascript:;", :class => "btn btn-mini preview-page", :target => "_blank", "data-url" => "#{@page.current_localization.public_path}?preview=true") .clear %p = f.label :navigation_label = f.text_field(:navigation_label, :class => "span5") - if @page_localization.contents.length >= 1 - for content in @page_localization.contents - unless @version.blank? || !content.versioned? - content.revert_to(@version) = content_editor(content) - else %p.no_content This page does not have any content areas. .tab-pane#seo .pad %p = f.label :seo_title, "Page Title" = f.text_field :seo_title , :class => "span4 " %p = f.label :seo_keywords , "Keywords" = f.text_area :seo_keywords , :class => "span4 " , :rows => 3 %p = f.label :seo_description , "Description" = f.text_area :seo_description , :class => "span4 " , :rows => 3 %p = f.label :fb_icon_id , "Facebook Icon" = f.asset_browser :fb_icon_id , :class => "" , :filter => "image" .span4 %legend Page Settings %p = f.fields_for :page , @page do |page_form| = render :partial => "/gluttonberg/admin/content/pages/page_settings" , :locals => {:f => page_form} = submit_and_publish_controls(page_form, @page, can?(:publish , Gluttonberg::Page), false)