Forum: Ruby on Rails Re: How do you get link_to to work correctly when using subd

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
Sean M. (Guest)
on 2006-01-18 22:16
(Received via mailing list)

>        options[:host] = host.join '.'
>      end
>      return super(options, *params)
>    end

Thank you very much, though this breaks when using WEBrick (or Lighty
on a port other than 80) so I added the following after options[:host]
= host.join '.'

      options[:host] = [ options[:host], @request.port ].join ':'
unless @request.port == 80

It looks ugly, but it works.

This topic is locked and can not be replied to.