开发者

Ruby Status 302 - Dont know what that means?

开发者 https://www.devze.com 2023-04-11 10:43 出处:网络
When i run the xxx.rb using localhost:3000/xxx I initially - before adding the require-client gem got two input boxes for name and email. that was just a basic template where you can do the usual edit

When i run the xxx.rb using localhost:3000/xxx I initially - before adding the require-client gem got two input boxes for name and email. that was just a basic template where you can do the usual edit/update/delete etc. However once i write the require 'rest_client' and update the gem this is what i get. Im not even sure if this is an error or if its just a way of saying rest_client was found. If so how do i go to my applicaiton to get the two boxes or get the application back up and running. i have a few more code to write to get this functionality working. however is this an intermediate state or an error ?

RestClient::Found in xxxController#index

302 Found
Rails.root: /Users/user1/Desktop/rails_projects/xxx_app

Application Trace | Framework Trace | Full Trace
app/models/xxx.rb:8
app/controllers/开发者_开发知识库xxx_controller.rb:1
Request

Parameters:

None
Show session dump

Show env dump

Response

Headers:

None


This is not an error. You should look into Location header as described here: http://restpatterns.org/HTTP_Status_Codes/302_-_Found

Generally 2xx are OK good repsonses, 3xx are intermittent ones, could lead to good or bad later, 4xx are expected errors (like page not found) and 5xx are fatal server errors

I have some basic RESTful API responses outlined here (not a complete list) http://vova.org/2011/06/24/restful-http-response-codes/

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号