|
1 | 1 | <% @nav = @blog.category %>
|
2 | 2 | <% @title = @blog.title %>
|
3 |
| -<% @description = @blog.cached_tag_list + ' ' + @blog.content.truncate(200).gsub(/(\r|\n)/, ' ') %> |
| 3 | +<% @description = @blog.cached_tag_list.to_s + ' ' + @blog.content.truncate(200).gsub(/(\r|\n)/, ' ') %> |
4 | 4 |
|
5 | 5 | <% content_for :stylesheets do %>
|
6 | 6 | <%= stylesheet_link_tag '/skins/default/github' %>
|
|
17 | 17 | <%= link_to @blog.title, blog_url(@blog) %>
|
18 | 18 | <%= link_to '', blog_url(@blog, mime_type = :md), :class => 'markdown', :title => 'Markdown格式原文' %>
|
19 | 19 | <% if account_admin? %>
|
20 |
| - <%= link_to '', url(:admin, :blog, :id => @blog.id), :method => :delete, :confirm => 'Are you delete', :class => 'del', :title => '删除' %> |
| 20 | + <%= link_to '', url(:admin, :blog, :id => @blog.id), :method => :delete, :confirm => '要删除文章吗?', :class => 'del', :title => '删除' %> |
21 | 21 | <%= link_to '', url(:admin, :edit_blog, :id => @blog.id), :class => 'edit', :title => '编辑' %>
|
22 | 22 | <% end %>
|
23 | 23 | </div>
|
|
29 | 29 | <div class="text">
|
30 | 30 | <%= @blog.md_content.html_safe %>
|
31 | 31 | </div>
|
32 |
| - <div class="info clearfix"> |
| 32 | + <div class="info clearfix"> |
33 | 33 | <div class="fr">
|
34 |
| - <span class="author"><%= @blog.account.name %></span> |
| 34 | + <span class="author"><%= @blog.account.name %></span> |
35 | 35 | <span class="time"><%= time_ago_in_words(@blog.created_at) %>发表</span>
|
36 | 36 | <span class="edit"><%= time_ago_in_words(@blog.content_updated_at) %>更新</span>
|
37 | 37 | <span class="views" title="浏览次数"><%= @blog.view_count %></span>
|
|
57 | 57 | <div class="relative">
|
58 | 58 | <div style="text-align:right;">[<a href="http://wowubuntu.com/markdown/" target="_blank">评论可以使用Markdown格式</a>]</div>
|
59 | 59 | <% form_for BlogComment.new, url(:blog, :create_comment, :id => @blog.id), :remote => true do |f| %>
|
60 |
| - <%= f.text_area :content, :class => 'comment' %> |
61 |
| - <div id="comment-error-info"></div> |
62 |
| - <%= f.submit '', :class => 'comment_btn' %> |
| 60 | + <%= f.text_area :content, :class => 'comment' %> |
| 61 | + <div id="comment-error-info"></div> |
| 62 | + <%= f.submit '', :class => 'comment_btn' %> |
63 | 63 | <% end %>
|
64 | 64 | <div class="box" style="<%= "display:none;" if account_login? %>">
|
65 |
| - <button class="close" onclick=""></button> |
| 65 | + <button class="close"></button> |
66 | 66 | <p>我想知道与谁交流思想,请用微博登录留言。</p>
|
67 | 67 | <button class="sina_btn"></button>
|
68 | 68 | </div><!-- box -->
|
|
95 | 95 | $('button.sina_btn').click(function(){
|
96 | 96 | var width=Math.round((window.screen.width-800)/2);
|
97 | 97 | var height=Math.round((window.screen.height-600)/2);
|
98 |
| - window.open('<%= url(:weibo_login) %>/?quick_login=1', 'weibo_third_part_authentication', 'height=300px, width=400px, top='+height+',left='+width+', scrollbars=no, resizable=no, status=no, resizable=no, menubar=no') |
| 98 | + window.open('<%= url(:weibo_login) %>/?quick_login=1', 'weibo_third_part_authentication', 'height=300px, width=400px, top='+height+',left='+width+', scrollbars=no, resizable=no, status=no, resizable=no, menubar=no'); |
99 | 99 | });
|
100 | 100 |
|
101 | 101 | // validate empty comment
|
|
0 commit comments