0
末我寫了這個試圖索引數據問題索引,無端接正則表達式符合文件
= form_tag blog_posts_path, method: :get do
%p
= text_field_tag :query, params[:query]
= submit_tag "Search", name: nil
,我得到這個錯誤,我真的不知道如何解決它:
/home/marina/project/app/views/blog_posts/index.haml:15: syntax error, unexpected ')'
));}\n<p></p>\n#{
^
/home/marina/project/app/views/blog_posts/index.haml:15: syntax error, unexpected '<'
));}\n<p></p>\n#{
^
/home/marina/project/app/views/blog_posts/index.haml:15: unterminated regexp meets end of fail
/home/marina/project/app/views/blog_posts/index.haml:15: syntax error, unexpected $end, expecting keyword_end
提取的源(左右線#15):
12: %br
13:
14: = form_tag blog_posts_path, method: :get do
15: %p
16: = text_field_tag :query, params[:query]
17: = submit_tag "Search", name: nil
18:
確定現在我有一個盒子可以搜索,但是每當我寫一個作品並點擊搜索按鈕時,沒有任何變化,我已經索引了數據我猜 – Marina 2012-04-08 13:05:15
marina @ ubuntu:〜$ cd項目 marina @ubuntu:〜/ project $ rake db:setup BlogPost的生成索引 – Marina 2012-04-08 13:06:19