Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

iOS

landon vago-hughes
landon vago-hughes
6,392 Points

Allowing anyone to enter their own userName and passWord

Watching the video Pasan enters his name as the userName and a some sort of String which has to be matched in the simulator or an error will appear. I was wondering how would I be able to implement some code which allows any userName and passWord to be entered. I would imagine there would have to be some form of database and then the code would have to check if there is such a userName and passWord in the database.

2 Answers

landon vago-hughes
landon vago-hughes
6,392 Points

Sorry my bad, it is the swift 2 course and login example for delegates I was just curious but I'm pretty sure I need to have a sign up view controller to add someone to a database as well as a log in if I wanted anyone to be able to log in

Caleb Kleveter
MOD
Caleb Kleveter
Treehouse Moderator 37,862 Points

For an app that has users, you will probably want to use an external database. There are two vary popular free services that have API's for them. Firebase by Google and Backendless.

I found Backendless to be easier to use and closer to the way Parse worked.