控制器:
class SearchController < ApplicationController
def index
end
end
路线.rb
get "search/index"
从rake routes
search_index GET /search/index(.:format) search#index
当我尝试访问时,http://localhost:3000/search
出现 404 页面错误...
控制器:
class SearchController < ApplicationController
def index
end
end
路线.rb
get "search/index"
从rake routes
search_index GET /search/index(.:format) search#index
当我尝试访问时,http://localhost:3000/search
出现 404 页面错误...