Raimon Fs wrote:
>
> respond_to do |format|
> format.iphone # action.iphone.erb
> format.html # index.html.erb
> format.xml { render :xml => @scanns }
It may require someone else to answer this properly however I think you
are getting confused about what will actually happen:
The iphone will always receive the html pages because the
webserver/rails app by default will look for html pages.
for example:
1) http://www.mysite.com/ #=> deafult format.html
2) http://www.mysite.com/index.xml #=> format.xml
3) http://www.mysite.com/index.iphone #=> format.iphone
Perhaps you could change default route to point to index.iphone when you
use your subdomain. You'd then need to ensure all your links used the
.iphone extension.
Unless there is someway to force the default format from html to
'iphone'? Wouldn't surprise me if it was possible, however, you'd need
to look it up...
Cheers
Luke
--
Posted via http://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---