Forum: Ruby on Rails URL rewrite to force 'www' and '.html'

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
adeel (Guest)
on 2009-01-18 04:28
(Received via mailing list)
For SEO, I need to force the URL to contain ‘www’ so my app always
appears in the browser as www.example.com and not ‘example.com’. I
also need the filename (ex. index.html) to appear completely, and not
be hidden.

Can someone give us some pointers on how to set this up? I understand
the first case involves .htaccess but I’m nervous about modifying that
without good guidance.

Thanks.
Fernando P. (Guest)
on 2009-01-18 15:10
adeel wrote:
> For SEO, I need to force the URL to contain �www� so my app always
> appears in the browser as www.example.com and not �example.com�.
For this you have to set a rewrite rule in Nginx or Apache. There is
plenty doc on the net.

I never heard that appending .html to URL will improve SE ranking.

--
Video tutorials for distance learners in french: http://www.digiprof.fr
This topic is locked and can not be replied to.