Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

davecuse

macrumors 6502
Original poster
Feb 20, 2004
419
0
NYC
I'm working on a web app, trying to test it out on my iphone. This app uses subdomains as account keys, so I need to be able to access my MacBook via both

test1.localhost.dev:3000
test2.localhost.dev:3000

In OSX I simply add the following lines to my "hosts" file;

127.0.0.1 test1.localhost.dev test2.localhost.dev

The problem I'm having is that when you hit the app using the MacBook's IP address the app blows up because it doesn't recognize the domain, and there's no subdomain.

How do I update the hosts file on my iPhone?
 
Short of jailbreaking the phone I don't believe there is any way to edit your hosts file.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.