I think your best shot is ussing HTTP protocol for it.
You need two things:
- Server Side HTTP enabled application that will connect to database. You can use PHP, ASP.NET, Java Servlets and JSP, Ruby on Rails, Python Django or any other web technology.
- Your iPhone client that will use HTTP request to send information to your server
So you will send requests from your iPhone APP such as:
https://www.yourappserver.com/Login?user=uname&pass=pass
And you will receive that request in your Application Server and process it accordingly.
You can to something similar for registering.