I want to to deliver different iTunes buy links to a user depending on where there Region Format is set (in general settings). Is there a way to detect that and then deliver a separate database to each users region?
Thanks for the help.
GS.
I want to to deliver different iTunes buy links to a user depending on where there Region Format is set (in general settings). Is there a way to detect that and then deliver a separate database to each users region?
Thanks for the help.
GS.
Assuming this is a web-based program, not Cocoa, the HTTP Accept-Language header appears to be all you've got to work with. Mobile Safari provides no information about Region Format, only Language.
This method, as well as a Region Format-based one, is flawed; more important is which iTunes Store the user has selected (the iTunes setting is transferred to the iPhone). This setting is independent of geographical location, Region Format and Language. You give the user a link to the wrong store, and it might well not work.
It shouldn't matter for free content, but I've had this problem myself with non-free content, as I often switch between the UK, US and German iTunes Stores (I prefer UK/US for podcasts, but can only buy from the German one).