Honest question.
Honest question.
I'm not getting what the problem is. Isn't this what ports are for? Or even just running the websites on different folders?
This is just one situation where I can see this come in really handy during development.
This is only necessary if you want users outside your domain to access your component. While you probably want to do so for MUC, you might not necessarily want to bother for your user directory or gateways. I've run many servers over the years and long since stopped creating a host/subdomain for each component.
As far as the XMPP protocol is concerned, the concept of sub-domains doesn't matter. It's useful for human users when configuring servers though.
Prosody for example allows running a multi-user chat service on example.com. And there's an undocumented feature which let's you have user@example.com be a user, and room@example.com be a chatroom.
In /etc/hosts:
1.2.3.4 site1.com site2.com
Then you have to edit /etc/hosts to try two more sites.
The idea that the user cannot access /etc/hosts on the iPhone is reason enough to jailbreak it. Denying access to /etc/hosts means the iPhone cannot connect to the any website that requires a hostname, even when the iPhone can connect to the internet, unless the iPhone can access some DNS server (which of course Apple probably wants to control). That is a ridiculous limitation. The internet nor the web requires DNS to work, but the iPhone requires DNS to access the web.[1]
1. assuming the website is using virtual hosts or otherwise requires a hostname
Some things are harder to do without a hostname - cookies, for instance, can be tricky.
Other than that, ports will do.