Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development > iPhone SDK Development - Advanced Discussion

Reply
 
LinkBack Thread Tools Display Modes
Old 09-06-2010, 05:32 AM   #1 (permalink)
Registered Member
 
jimmy's Avatar
 
Join Date: Aug 2010
Posts: 52
jimmy is on a distinguished road
Default Iphone and Mysql

is it possible to connect an Iphone Application with a Mysql database inorder to Authenticate a login? thanks ...
jimmy is offline   Reply With Quote
Old 09-06-2010, 09:26 AM   #2 (permalink)
Nuisance Developer
 
Join Date: Jul 2009
Location: Italy
Posts: 4,691
dany_dev is on a distinguished road
Default

Quote:
Originally Posted by jimmy View Post
is it possible to connect an Iphone Application with a Mysql database inorder to Authenticate a login? thanks ...
why not use php to handle the connection and give values though xml in post?.


objective-c--->php---->mysql
__________________
dany_dev is offline   Reply With Quote
Old 11-22-2010, 02:27 PM   #3 (permalink)
Registered Member
 
Join Date: Sep 2009
Posts: 48
encryption is on a distinguished road
Wink Anything is possible, couple of options

Quote:
Originally Posted by jimmy View Post
is it possible to connect an Iphone Application with a Mysql database inorder to Authenticate a login? thanks ...
The short answer is yes. Although there is no connectMySQL method in the SDK, you could use network sockects to write a method that does just that. I doubt you want to go to that trouble though! Please send me the code if you do write it

You might think about using iPhone's NSURLConnection class to connect to a web server that authenticates for you. You would need to develop something on the server side to handle the authentication process. What language you choose is just personal choice. I wrote this into an app I developed and I used Perl on the server side. I have seen it done in PHP, ASP, etc so use whatever language you prefer on the server side.

Hope this helps!

NP
encryption is offline   Reply With Quote
Old 11-23-2010, 02:05 PM   #4 (permalink)
57Digital Ltd, Mobile Dev
iPhone Dev SDK Supporter
 
iPhoneConnection's Avatar
 
Join Date: Apr 2010
Location: Sheffield
Posts: 144
iPhoneConnection is on a distinguished road
Default

Allowing your app to execute remote queries is asking for a whole bunch of trouble; SQL Injection being just one of them.

The neatest way would be to expose the behaviour with a set of web services. It also makes it easier to control your DB queries rather than worrying about app updates for bugs, etc.

If you want to use a SOAP web service, I'd recommend wsdl2objc. If you decide to use Rest, you'll need to do the POST/GET operations yourself.
iPhoneConnection is offline   Reply With Quote
Old 12-01-2010, 02:48 PM   #5 (permalink)
Registered Member
 
Join Date: Jul 2010
Location: Texas
Posts: 40
ronbowalker is on a distinguished road
Default

Here is a good tutorial that I used and found very good.

Kiksy, iPhone Login App using PHP MySQL Tutorial
ronbowalker is offline   Reply With Quote
Reply

Bookmarks

Tags
database, mysql, sql

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 382
15 members and 367 guests
AragornSG, ChrisYates, coolman, davejas69, givensur, hussain1982, iAppDeveloper, jbro, Kryckter, locombiano89, Mah6447, Meoz, stanny, Tomsky, WeaselPig
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,646
Threads: 94,111
Posts: 402,862
Top Poster: BrianSlick (7,990)
Welcome to our newest member, locombiano89
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 05:45 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0