How to install TNG on your Mac using MAMP

From TNG_Wiki
Jump to navigation Jump to search

Note - This tutorial assumes that you have followed the guide on how to install MAMP on your Mac and are comfortable with finding the MAMP application and htdocs folder. This tutorial does not use or discuss the MAMP PRO application.

1. If you haven't purchased TNG, you will need to buy it from the TNG website. You will then be sent instructions on how to access the downloads page. Download the latest version of TNG and make sure that you download TNG Full Version...

Download TNG


Note - Depending on how your Mac and web browser are set up, the location that this file downloads to on your Mac may differ. Unless you have specifically made a change to your browser settings, it will likely download to your Downloads folder. Your browser may also be set to automatically unzip the downloaded file.

2. If the zipped file has download to your Mac and has not been automatically unzipped, double-click on it to extract TNG as one complete folder...

TNG files

3. Go into your Applications folder and open the MAMP folder...

MAMP folder in Applications folder

4. There are two items of interest in the folder. The first is the MAMP application and the second is the folder htdocs. Think of htdocs as the web server folder...all the websites you create will need to sit inside this folder. Open the htdocs folder...

htdocs and MAMP application


5. In the htdocs folder, delete the index.php file. It is simply a test file that is no longer needed.

6. Move the unzipped TNG folder into the htdocs folder. Give it a more meaningful name, but make sure that you also don't include spaces in the name. In this example the folder has been renamed my-tng-site

Technically, you could have just moved all the files from the unzipped TNG download straight into htdocs without the need for a folder within it. But this assumes that TNG is the only website that you are ever going to use MAMP for. It also means that you can't run multiple versions of TNG on the same Mac. Therefore it is good practice to keep each website that you place in htdocs in their own separate folder.

htdocs folder with index.php and my-tng-site folder

7. Go back to the MAMP folder and double-click the MAMP application to start it running. We're now going to do a little trick to help you access your TNG website quickly in the future. With MAMP running, go up to the MAMP menu and select Preferences...

MAMP preferences

8. In the section My favorite link enter the name that you gave the TNG folder that is sitting in htdocs and click OK...

Enter folder name as favorite link and click OK]

9. Start the web server running by clicking Start...

Click WebStart in the MAMP app

10. If the WebStart page hasn't launched your web browser, click the WebStart button to launch the WebStart page...

Click WebStart in the MAMP app

11. The WebStart page should have now launched your web browser. Scroll down the page...

WebStart page loaded

12. Click on MySQL further down the page and take note of the Username and Password details for accessing the MySQL server that is now running...

MySQL username and password

13. Before you start working through the TNG installation process, you need to create a MySQL database to use. Go back up to the Tools menu on the WebStart page and click on phpMyAdmin...

Tools menu and phpMyAdmin

14. A new tab or page should load in your browser, showing you phpMyAdmin. Click New...

New option in phpMyAdmin

15. Give the database that you are creating a meaningful name (with no spaces). In this example the database has been called tng-database. Don't change any other settings and click Create.

Name your database and click Create

A new (but empty) database should now be listed in the left-hand column of phpMyAdmin. It's OK to now close the phpMyAdmin web page and go back to the main WebStart page.

The database should be listed

16. Remember that trick in Step 8 where you entered a favourite link? That means that you now have a quick way to access your local TNG website and begin installing TNG. Just click on the link on the WebStart page that says My Favorite Link...

Click My Favorite Link in the WebStart page

IMPORTANT - You need to make sure that you are beginning the TNG installation process from within the web server. Take a look at the web address for the Read Me page that you should now be seeing. It should include the words "localhost" or "127.0.01".

localhost loading the Read Me file

If you are seeing a web address that looks like the image below, then you are not viewing the Read Me file via the webserver and the TNG installation will fail.

Read Me file loaded in the browser

The TNG installation guide should have now loaded. This tutorial is not intended to go through the details of how to install TNG, as they are contained within the install guide itself...

TNG installation instructions

17. Make sure you Set permissions...

Set permissions

18. It's good practice (even with a local install) to Rename two folders. It's particularly important to do this now in case you want to move your local TNG site to a web hosting company in the future.

Rename two folders

19. Choose your language and character set and click Save...

Choose your language and character set

20. Now you need to Establish a connection to your database. Do you remember the MySQL Username and Password that you noted earlier? And the name of the database that you created earlier using phpMyAdmin? This is where it all comes together. You should leave the Host Name as it is, enter the Database Name, Database Username and Database Password. You can leave the other items empty and click Save and Verify.

Establish a connection to a database

21. Save and Create your Database Collation setting...

Database collation - Save and Create

22. Then create your admin user. Enter a Username, Password, Your real name and Your email, before clicking Create User...

Click Create User button

23. Create a "tree" by entering a Tree ID and Tree Name before clicking Create Tree...

Click Create Tree button

24. Select a template (or theme) by choosing a Template Number and clicking Select Template...

Click Select Template button

25. It is important to read the Final Notes and in particular, the section titled Files to Delete. There are three files that you should now delete in the TNG folder (that is sitting htdocs) for greater security. Once you have done that, you can now click on Admin menu...

Read Final Notes for the files to delete

And the admin page of your shiny newly installed TNG website should load!

26. If you want to see the main page of your new website, click on Public Home at the top of the admin area...

TNG Admin panel

And there is the homepage of your locally installed and running, TNG website!

TNG site loaded in MAMP

Back to MAMP | Next - How to download a copy of your website to your Mac and run it locally using MAMP