Google Groups Home
Help | Sign in
Bad response with r_c (xml instead of html)
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  3 messages - Collapse all
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Bence Nagy  
View profile
 More options May 13, 7:47 am
From: Bence Nagy <bence.n...@gmail.com>
Date: Tue, 13 May 2008 04:47:53 -0700 (PDT)
Local: Tues, May 13 2008 7:47 am
Subject: Bad response with r_c (xml instead of html)
I get XML output calling 'http://localhost:3000/people' with Internet
Explorer 7 (IE6 and Firefox works fine) by the following code (git
version of r_c):

  index do
    before do
      @people = current_user.has_role?('admin') ?
Person.all.sort_by(&:name) : current_user.people.sort_by(&:name)
    end
    wants.html do
      redirect_to new_person_path if @people.empty?
    end
  end

The command 'formats = :html' after 'index do' solves the problem (I
am using haml with '!!! Strict' header). Without r_c the code works
too.

Greetings, Bence


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
James Golick  
View profile
 More options May 13, 7:51 am
From: James Golick <jamesgol...@gmail.com>
Date: Tue, 13 May 2008 07:51:42 -0400
Local: Tues, May 13 2008 7:51 am
Subject: Re: Bad response with r_c (xml instead of html)
Which branch are you on?

Sent from my iPhone

On May 13, 2008, at 7:47 AM, Bence Nagy <bence.n...@gmail.com> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Bence Nagy  
View profile
 More options May 13, 1:32 pm
From: Bence Nagy <bence.n...@gmail.com>
Date: Tue, 13 May 2008 10:32:10 -0700 (PDT)
Local: Tues, May 13 2008 1:32 pm
Subject: Re: Bad response with r_c (xml instead of html)

> Which branch are you on?

It was the automatic_route_discovery branch.

Greetings, Bence


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2008 Google