- message_type = @page ? 'comment' : 'post' - if @topic.locked? %p.administrative This topic is closed. - else - if current_reader - if current_reader.activated? - formurl = @page ? page_posts_url(@page) : topic_posts_url(@topic) - @post ||= @topic.posts.build %div.reply#replyform %div.speaker %a{:href => reader_url(current_reader), :class => 'main'} = gravatar_for(current_reader, {:size => 40}, {:alt => current_reader.name, :class => 'gravatar', :width => '40', :height => '40'}) .post_wrapper .post_header %h2 = t('add_post', :message_type => message_type) %p.context = t('logged_in_as', :name => current_reader.name) = t('if_not_you') = link_to(t('log_out'), reader_logout_url) + '.' - form_for :post, :url => formurl, :html => {:id => 'reply_form', :multipart => true, :class => 'friendly inline'} do |f| = render :partial => 'posts/form', :object => f %p.buttons = f.submit t('post_post', :message_type => message_type) - else = render :partial => 'reader_activations/activation_required', :locals => {:purpose => t('to_add_post', :message_type => message_type)} - else = render :partial => 'reader_sessions/login_form', :locals => {:purpose => t('to_add_post', :message_type => message_type)}