Missing a Template for This Request Format and Variant

missing a template for this request format and variant

you need to create the available.html.erb file within the views/bubble/ directory. When the route takes you to that action, it also navigates you to that view, so if you put:

<h2>YEP!!!!</h2>

as the only line in that file, it should return that to you on the webpage.

In the future, you could use rails g scaffold bubbles and that will create a majority of the files (MVC) and routes for you.

ParksController#create is missing a template for this request format and variant. request.formats: [ text/html ] request.variant: []

You're not redirecting to another view after the create action. You're responding to html there, but not doing anything with it. Usually after a create, the user is redirected to the index view. I think if you passed a block to the html response and redirected, the error would resolve itself.

ie:

...
respond_to :html { redirect_to index_path }
...

Also, you have your end commented out for your if @park.save

is missing a template for request formats: text/html

This means you do not have a app/views/phrases_term(s)/new.html.erb file. I'm unsure if you've namespaced the files under 'phrases_term' or 'phrases_terms'.

Make one in the correct directory, populate it, and it will load.

How to fix PagesController#home is missing a template for request formats: text/html

The problem is resolved when I started the server using the windows command prompt rather than windows powershell

Error with Simple Action Controller

The error is self explanatory

ProfilesController#index is missing a template for this request format and variant. request.formats: ["text/html"]

This means you don't have file app/views/profiles/index.html.erb.

with Rspec destroy is missing a template for this request format and variant

If you're using the resources :chat route helper, then the destroy route by default doesn't respond to GET requests. If you run rails routes you'll see something like this

    chats GET    /chats(.:format)          chats#index
POST /chats(.:format) chats#create
new_chat GET /chats/new(.:format) chats#new
edit_chat GET /chats/:id/edit(.:format) chats#edit
chat GET /chats/:id(.:format) chats#show
PATCH /chats/:id(.:format) chats#update
PUT /chats/:id(.:format) chats#update
DELETE /chats/:id(.:format) chats#destroy

So, what you're actually requesting with get :destroy, params: {id: Chat.last.id} is the show action

try delete :destroy, params: {id: Chat.last.id} instead



Related Topics



Leave a reply



Submit