How to create a poll on IOS? [closed] - ios

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
hi I’m new to IOS development i have developed only one application in iOS now i want to make a polling app in IOS i Google every where i did’t get a proper solution to make a polling app.
In my polling app i want get input poll form the user and i have to store in database and i have to calculate the value for the polling and i have to show the result how many people voted .
so please can any one suggest what is right way to make polling in IOS or is there any alternative way to make this.
thanks.

Assuming you want to store your results on a back end web server with a DB then you would first need to write some web services. I personally would suggest a combination of PHP and MySQL as they're both open source and relatively easy to get to grips with. I also recommend you use JSON as your data interchange format as it provides a human readable structure without the complexity of XML.
Once you have a functioning back end you would need to build an app with the appropriate data fields that you want in either one or multiple views. Personally I would put all of your questions into an array and then cycle through them changing the input controls if necessary. You can then add your answers to an NSMutableArray.
Once you have your complete answer set in your NSMutableArray you can serialise it to JSON and transmit it off to your web service.
There are many guides for getting started with JSON on iOS available, I would suggest you take a look at this one.

Your question is business specific (not to iOS, iPhone & objective C).
So I would suggest you to better try these APIs available in market.
support.polldaddy.com
Poll EveryWhere
TypeForm
Hope that helps.

Related

Best Database to use for iOS application [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
I am trying to develop an iOS app (Swift) that requires the use of database. The app will have three different users login and courses. I have 5 database tables that i will have in my app but I am not sure which database platform to use. (I have done research and some people recommend Core data and others say Realm)Thank you for your suggestions.
Depend upon your requirement you need to choose Realm, Sqlite and CoreData database.
For Reference check this link
https://rollout.io/blog/ios-databases-sqllite-core-data-realm/
Since you are just getting started, I would suggest you to try out CoreData and see if it works for your use case. It is object oriented, works well across all Apple platforms and is well integrated with Xcode. Although, please note that this only works for local data. However, if you need (or wish) to store the data on remote server then Firebase would be the way to go. Also this might be preferable if you later wish to do analytics based on the data stored.
Both of these work pretty well and aren't exactly comparable to each other coz they have different purpose. You just need to figure out what's your long term use case and plan it out. For more details check this: https://www.quora.com/How-does-Firebase-compare-to-Core-Data
You can use Firebase if you do not want to setup your own database. You can then assign 'roles' to the users logging in. Check out Firebase authentication documentation.
If you're doing it locally, Core Data is fine.
But if you're doing it remotely (over the Internet, in the cloud), then Firebase is OK.

How to connect to an online database from my iPhone app? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I want to make a very simple app that connects to a database and retrieves some questions and answers for a quiz.
What is the simplest way to do this? Is Parse the way to go, or is it possible to use a sqlite3 database, which is hosted online? I want to keep it as simple as possible.
you should NEVER connect your mobile apps directly to a database. you should create a rest api for that, a simple php for example that will be connected to the database and return the results to you.
For connecting data on a server to a mobile app you should use a API Rest, not a direct connection to a database.
You should denitively go for Parse. You would have to implemente nothing on server side and it has an SDK already implemented for iOS that helps you retrieving the information.
Also the free plan could fit you for quite time.
https://parse.com/docs/ios_guide#top/iOS
The easiest way would be to be create a Rest API in any of the server side language like PHP and access your online database. Having said that , this would mean you would require it to be hosted somewhere online.
The best option in case you don't want to spend on hosting on a server and writing a server side script to access the traditional database would be use to Parse which has options of saving the data in the offline mode in your app and then you can sync it with the database online.
About sqlite3 being hosted online , that won't be a suitable option . I suggest you go for Parse it is easy to learn .
Best a way for your task - Core Data
If user don't have access of network? How he takes questions and answers?
Just I too building that task.
Parse can use when we want save results test or something data user

Same code base in different apps [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
Here's my problem: Today my company has an app that communicates with a specific server, but we received demands to develop this same App for different servers, so a few things need to be changed in the App (like the URL to call and the logo).
I do not want to create a whole new application with 99% of the code the same in my Xcode just to do that, because it would be really difficult to develop new stuff.
I'm wondering if it's possible to maintain the same base code with just small changes to different applications.
Hope I made myself clear, thank you.
Just to answer my own question, I just found this guide:
https://itexico.com/blog/iOS-Mobile-Development-Using-Xcode-Targets-to-Reuse-the-Code
Different targets and preprocessor macros are just what I needed, pretty sweet!
For something like this, I'd suggest using easy-to-manipulate stuff like plists and so on to make a core app like a framework that would be able to read an XML for example, and parse its data into different fields of your Plist and apply the settings based on that data for every new app that you have.
So, you should have items like url and logo, etc. in your settings Plist, and getting to read them in the app rather than setting values manually inside the app. This way, you'll be able to drop different image files called logo.png for each app, or edit the value for url in your Plist, and the app will read the value from the Plist.
However keep in mind that Plists are good if you don't have a giant list of items, because they can be slow if you get a really big one, but they're so quick and handy for average number of items.
I hope this helps.

How to store data on the internet for an iOS App [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 9 years ago.
Improve this question
So I know this is a pretty simple question, but I've looked through all of my iOS textbook and can't seem to find out how people do this. I just want to store and edit an array on the internet. That is, let's say all of the data for my application is stored in an NSMutableArray. Ignoring the complications that occur with people editing the array at the same time, how would I allow multiple people to go into my app and then through that app access and edit the NSMutableArray for others to see?
There are a ton of options here, some of which were listed by #Zaph. The most common scenario to share data between a ton of random users is to setup your own server to run an API that you app will be able to communicate with. This is commonly referred to as the "Backend". The solutions here are vast, written in many different languages and sometimes even provided by third parties services. My advice is to pickup a simple, easy to learn server-side setup like Ruby-on-Rails, then deploy test app on Heroku as they provide free accounts to play with.
In addition to the options #coneybeare provided some others include DropBox, Parse and Azure.
Dropbox requires each user so setup an account.
Parse and Azure have rather easy APIs but you will be paying past the free tier.

How can I create a cloud backend to update my iOS app? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I have a news application that i am in the process of building, and of course news updates a lot, so I have to constantly update my stories, so I need a backend of some sort that will let me update my stories over the air without updating the actual app.
I found Parse.com and they have some awesome stuff, but with the way my app is built I don't think I can use them.
I will have to update UIImageviews, UItextviews, and the names of Buttons. With Parse I can only seem to find help regarding the PFQueryTableViewController, which I could use this, but that requires completely recoding and some redesigning of my app to fit into that.
So unless there's another way, I guess I will suck it up and get to work.
So is there a simpler way to do this, or maybe a better service that works more towards what I'm describing?
What you are asking basically is how to do network communication. It sounds like to me you can do what you want with just Parse. You just store the images and text and then call the information from the parse backend when you are loading. From there you can update the UITextViews, button names, and UIImageViews however you want dynamically (using the .text, setTitle, and .image properties and methods respectively). You could also use Amazon S3 for image storage... but the API is less well documented for that.
This is probably your best bet, unless you really want to delve in more deeply and learn how to use NSURLConnection or AFNetworking to communicate with a back-end that you build on a django, ruby, etc. server that you host yourself on a server.

Resources