Open this file in Xcode and keep reading this guide, you'll have to perform some edits in this file in order to get your template ready to run:
Replace this string with the new name you want to give to this app:
let APP_NAME = "Eventik"
Parse Server Keys
As explained in the Quick Start
section of this guide, you must replace the strings of the 2 variables below with your own
that you will get from the back4app website after creating your own Parse App:
let PARSE_APP_ID = "K7SCPO9S6zywk3DMoEskABkJCOOWNkwx6Lfew2hy"
let PARSE_CLIENT_KEY = "kC36ZLG7UWs31cPpLUN3M8RkS6K6BK544MFYm3hD"
Replace the string of the variable below with your own Interstitial Unit ID
- you have to create such Unit ID on apps.admob.com
, just follow the instructions on the AdMob's website in case you don't know how to generate a Unit ID:
let ADMOB_INTERSTITIAL_UNIT_ID = "ca-app-pub-3940256099942544/1033173712"
You also have to replace the string into
with your own App ID:
You can get both App ID
and Unit ID
strings from your AdMob Unit page, after creating it:
Sometimes Apple reviewers reject apps because of Ads, the reason why is not clear yet, but a new submission on the App Store will fix the problem and get your app approved - just in case you'll get a rejection because of IDFA issue.
Anyway, after clicking the Submit For Review button on the App Store Connect page of your application, you’ll get something that looks like the picture below. Mark the options shown below and everything should go smoothly on the next review you'll get of your app:
You can edit the
values of the following variables as you wish, change the numbers before
. The main color of the app and some UI will be affected by your change:
let MAIN_COLOR = UIColor(red: 247/255, green: 104/255, blue: 48/255, alpha: 1.0)
let LIGHT_GRAY = UIColor(red: 243/255, green: 243/255, blue: 243/255, alpha: 1.0)
PLEASE NOTE that NOT all Views in the app will change accordingly to the new RGB values you've set in the above variable, you will still need to adjust some colors in some Controllers in the Storyboard.
This App uses some custom fonts, and such fonts are stored into the OpenSans
In case you want to add a new font, you have to first drag your
font file into the left-side panel in Xcode and click the Finish button in the popup that will show up:
Then select the Label, Button, TextFiled or textView you want to change font to, click the
icon on the right-side Attributes
inspector panel and select the font you want in the dropdown list:
Support email address
You must replace the following string with a valid email adress where you want people to contact you in case of questions, support or account deletion requests - accordingly to EU GDPR
let SUPPORT_EMAIL_ADDRESS = "[email protected]"
Default Location Range for Events
When the app searches for events in a specific city or location, the range of distance around that area is set in the variable below:
let EVENTS_LOCATION_RANGE_KM:Double = 100
You can edit such value as you wish - it's in Km.
Admin email address and URL to mail.php file
The following variable must be changed into your own email address, or at least the one you want to get emails about new/edited events:
let ADMIN_EMAIL_ADDRESS = "[email protected]"
The variable below, instead, is the one you must edit in order for the app to call the mail.php included in the package and send you email about new/edited events:
let MAIL_PHP_FILE_URL = "http://yourwebsite.com/"
So, let's pretend your website has this URL:
. You must first upload the
file into your own server via Filezilla
FTP app - or another FTP software - and keep note of the location you have uploaded it.
If you uploaded the file into the root of your server, then the variable above should look like this:
let MAIL_PHP_FILE_URL = "http://yourwebsite.com/" <-- "http://yourwebsite.com/" is the URL of your website
and must be changed into your real URL - the slash (/) symbol must be placed at the end of the URL
Otherwise, if you uploaded
into a specific folder in your server, then you must append the name of that folder to the URL, like this example:
let MAIL_PHP_FILE_URL = "http://yourwebsite.com/your_folder_name"
Your web server must have PHP 5.4 or higher enabled, otherwise emails won't be sent from your server to your address.
List of popular Cities and their GPS coordinates
The following array contains a list of popular cities that the app loads when you perform a search for locations. You can edit them as you wish since they are just strings, just make sure to use the same format for even new cities:
var popularCitiesArray = [
"New York_New York_40.7143528_-74.0059731",
// ADD CITIES HERE (OR EDIT THE ONES ABOVE)
Let's pretend you want to add Philadelphia
as new city, you should add the following string as last item of that array:
The underscores symbols
_ are important for the app to split data and work fine, so don't miss the
_ symbols and be careful while inserting them in between the City name, its State and its GPS Latitude and Longitude coordinates!
List of Categories
The following array contains a list of Categories. You can edit them as you wish or even add new items to the array, the app will call them automatically:
let eventsCategories = [
"Food & Drink",
// ADDITIONAL CATEGORIES HERE...
Unless you are familiar with iOS programming, you should leave the code of this section as it is since it includes useful functions to show alerts and perform other things in the app.
Parse Dashboard Classes and column names
This section is a list of strings that the app calls to perform queries to the Parse Server database - aka Parse Dashboard - and it contains a few useful custom global variables and functions.
Do not edit those variables and instances unless you're an experienced iOS developer, otherwise the app will not work properly.