Monday, January 23, 2006

Ruby on Rails variables domain

To get the value of domain names, put the following in .rhtml file

<%= request.domain(2) %>


or render_text request.domain(); in *_controller.rb file

If no argument is supplied, tld_length will default to 1.

0 Comments:

Post a Comment

<< Home

eXTReMe Tracker