Ehr... assuming that the layman does not grab why it is clearly incorrect would you please elaborate? Is it because the next URI has the IP address instead of "localhost", like http://127.0.0.1:3000/blah instead of http://localhost:3000/blah?
 
Cheers,
 
   Flavio.

On Tue, Jan 18, 2011 at 6:48 PM, Peter Gordon <peter@pg-consultants.com> wrote:
I am trying to use dancer in standalone mode and testing it locally.
I am using Ubuntu with Dancer 1.3000_02

In the screen dump I am seeing the HTTP_HOST variable set as:

HTTP_HOST  => 'localhost, 127.0.0.1:3000',

It is used in Dancer/Request.pm and is used to build the next url, which
clearly is incorrect.

sub base {
   my $self = shift;

   my @env_names = qw(
     SERVER_NAME HTTP_HOST SERVER_PORT SCRIPT_NAME psgi.url_scheme
   );

   my ($server, $host, $port, $path, $scheme) =
@{$self->{env}}{@env_names};
   $host =~ s!.*,\s+!! ; #pmg
   $scheme ||= $self->{'env'}{'PSGI.URL_SCHEME'};    # Windows

Peter

_______________________________________________
Dancer-users mailing list
Dancer-users@perldancer.org
http://www.backup-manager.org/cgi-bin/listinfo/dancer-users