Check your version

This video covers a topic in Drupal 7 which may or may not be the version you're using. We're keeping this tutorial online as a courtesy to users of Drupal 7, but we consider it archived.

Alternate resources: 

Installing MAMP web server

Video loading...

  • 0:06
    [Installing MAMP web server with Addison Berry]
  • 0:12
    In this video, we're going to be looking at how you can
  • 0:15
    install a local web server on your Mac machine,
  • 0:19
    using something called MAMP, which is Mac, Apache, MySQL and PHP.
  • 0:26
    And we're going to-- you can find MAMP at
  • 0:31
    Don't go to
  • 0:32
    It's just a domain holder.
  • 0:35
    Once you get to, you're going to see there are two products
  • 0:39
    that they have available, MAMP and MAMP Pro.
  • 0:42
    We're just going to use the free MAMP.
  • 0:43
    We don't need the Pro for our needs.
  • 0:46
    And this is going to go ahead and put
  • 0:48
    the entire AMP stack on our Mac.
  • 0:51
    You'll notice that the name of it has Pro in it,
  • 0:54
    but it's all the same thing.
  • 0:56
    So I'm just going to download this to my desktop,
  • 0:59
    which will take a couple of minutes.
  • 1:02
    And then I can actually get through the installation process.
  • 1:06
    So, now that it's downloaded, I'll just unzip it.
  • 1:09
    I'll open that zip file.
  • 1:10
    I can do that to my browser because I'm using Chrome here.
  • 1:12
    But you just want to unzip wherever you downloaded it.
  • 1:15
    I downloaded mine to my desktop.
  • 1:17
    So I can see the zip file I downloaded
  • 1:19
    and then the package that got unzipped.
  • 1:22
    And I'll walk through this.
  • 1:23
    It's a standard sort of installer on Mac.
  • 1:26
    It has an installer.
  • 1:27
    It's not a drag and drop into your applications folder,
  • 1:30
    like most Mac applications are.
  • 1:32
    So you have to kind of walk through the installer.
  • 1:36
    Classic kind of stuff.
  • 1:38
    Back in the day, MAMP used to be just a drag
  • 1:40
    and drop into your applications folder.
  • 1:44
    But they've changed that in this latest version.
  • 1:47
    So it was something new for me.
  • 1:49
    But it just takes a few minutes.
  • 1:50
    It installs the stuff and puts everything in place.
  • 1:54
    And then it adds MAMP to your applications folder.
  • 1:58
    Now as we scroll down here, you are going
  • 2:00
    to see that we actually have two folders that got added.
  • 2:02
    There's the plain MAMP and then there's MAMP Pro.
  • 2:05
    And I don't want MAMP Pro, so I'm going to ignore it.
  • 2:07
    You can delete it.
  • 2:09
    But I want to just look at the plain MAMP.
  • 2:11
    And that is the actual web server.
  • 2:14
    In this folder in addition to the web server,
  • 2:16
    there's also this application which helps
  • 2:18
    us sort of control our servers what they're doing.
  • 2:21
    So when you launch it, it'll start the servers automatically for you.
  • 2:25
    And then we have these other buttons here
  • 2:26
    to help us sort of set things up and control it.
  • 2:30
    The first thing I want to do is open the start page
  • 2:33
    and get a little oriented.
  • 2:35
    The start page, this main page, is really great because it actually
  • 2:38
    shows you your MySQL user, which is really
  • 2:41
    good information to know right at the beginning.
  • 2:44
    We also have our PHP info.
  • 2:47
    phpMyAdmin is built in, so you could start dealing with your databases
  • 2:49
    right away.
  • 2:51
    So this is just a good handy thing to have around.
  • 2:54
    And you'll notice that is located at the main URL we're working from
  • 2:58
    is local host colon 88 88 rather than just the plain local host.
  • 3:05
    So let's go look at our preferences.
  • 3:06
    And we'll come back to talking about that 88 88 in a minute.
  • 3:11
    You can choose which version of PHP want, 5.2 or 5.3.
  • 3:15
    There are some applications that work on 5.2 and don't work on 3.
  • 3:19
    You can change that.
  • 3:20
    You could switch it in the middle.
  • 3:22
    I also like to always have a cache.
  • 3:24
    I prefer APC.
  • 3:26
    You can pick the cache that you want.
  • 3:28
    Again, we have-- these are just sort of handy things in terms of when
  • 3:31
    you want the server to start or stop.
  • 3:33
    If you don't want it to start when you launch the application,
  • 3:36
    you can change that here.
  • 3:37
    And in the ports tab is where we find that 88 88.
  • 3:41
    And basically MAMP is setting itself up
  • 3:43
    on a port different than local host, because it doesn't want to conflict
  • 3:47
    with the built in Mac web server, if you're using that.
  • 3:51
    So it's setting itself up sort of in a different location.
  • 3:54
    But, if you are using MAMP is your main web server on your local host,
  • 3:58
    you can just set it to default stuff.
  • 4:00
    And then that eliminates having to type in the colon 88 88 stuff.
  • 4:04
    So I always do that.
  • 4:06
    We also have the document root, which you can see is in the MAMP
  • 4:09
    folder, in a folder called HT Docs.
  • 4:12
    But you don't have to use that if you don't want to.
  • 4:16
    So if I'm in MAMP here, you can see this HT Docs folder.
  • 4:20
    And that's where I would put all of my website files.
  • 4:24
    That's where the actual web server's serving from.
  • 4:28
    But I can change that and go pick something else.
  • 4:32
    This is where I have my sites, is in my sites
  • 4:34
    folder, that comes as a default place on a Mac.
  • 4:39
    So if I go in and just browse for it and select it, now when I do it,
  • 4:44
    it's going to restart the servers to take my changes into effect.
  • 4:49
    And once that happens, I can use my Mac sites folder
  • 4:54
    as my document root for my web server.
  • 4:57
    And just use that rather than having to drill into MAMP to use it
  • 5:00
    all the time.
  • 5:01
    It's your preference.
  • 5:02
    You can do how you like.
  • 5:04
    Another thing you may or may not want to do
  • 5:06
    is have MAMP start when you start your computer.
  • 5:09
    So I'm just going into my Mac preferences
  • 5:12
    and under my account in the login items,
  • 5:16
    I can add MAMP, the MAMP application,
  • 5:20
    to fire up when I login to my computer or start it up
  • 5:24
    in the morning.
  • 5:26
    So I can go in here and actually select the application
  • 5:28
    and then add that to the list.
  • 5:30
    And if I have when the application launches that it starts
  • 5:34
    my actual servers, then whenever I boot up my computer
  • 5:37
    it would just start my MAMP server.
  • 5:39
  • 5:40
    So now we have it installed.
  • 5:41
    We've done our settings.
  • 5:42
    We've got things kind of set up the way we want.
  • 5:44
    And now, let's actually use it.
  • 5:46
    So I'm going to open up my text editor here,
  • 5:50
    and I'm just going to create a very simple file just to show you
  • 5:54
    that the web server is actually working and where those files go.
  • 5:58
    So just put in some plain text here.
  • 6:01
    And I'm going to bother with HTML tags or anything.
  • 6:04
    And what I need to do is save that as index.html
  • 6:09
    like the main page on my server.
  • 6:12
    So I'll do this as index.html.
  • 6:15
    And I'm going to save that into my web root, which is my sites
  • 6:18
    folder because I changed it to that.
  • 6:20
    Otherwise you'd have to do it in MAMP HT Docs.
  • 6:24
    So let me go to MAMP here and start up my MAMP server,
  • 6:29
    make sure that's running.
  • 6:30
    So the servers are running.
  • 6:31
    I'll quit out of that.
  • 6:36
    Now let's just go to local host.
  • 6:38
    And it works.
  • 6:40
    So because I changed the- I removed that 88 88
  • 6:43
    by changing the port settings.
  • 6:46
    So this is my simple text file.
  • 6:48
    And when I go to local host, it's there.
  • 6:50
    And that's great.
  • 6:50
    So I can start building a website there.
  • 6:54
    Another nicer way, especially when doing locals,
  • 6:56
    you tend to have more than one thing you want to do.
  • 6:58
    So if I just make a folder for my site,
  • 7:01
    and instead of taking over the entire web server
  • 7:03
    by making an index file, I can just put folders in here.
  • 7:08
    And then each of these can be their own website that I'm running.
  • 7:12
    So I could be developing and working on multiple websites
  • 7:15
    at the same time.
  • 7:16
    And I just go here and I have an index
  • 7:17
    of all the sites that I could play with.
  • 7:19
    So that's MAMP in a nutshell.
  • 7:22
    It's got the entire AMP stack along with phpMyAdmin and lots
  • 7:26
    of good tools for just quickly getting
  • 7:28
    up and running to do some local development.
  • 7:30
    So I'll see you next time.

Installing MAMP Web Server


This video shows you how to download and do the initial setup of MAMP, which is Apache, MySQL and PHP for Macintosh. It shows some basic configuration tweaks to change the port from 8888 to the default of 80 so that you can just visit the localhost in the browser and get your Drupal installation to appear. It also provides a general orientation to MAMP, and some other initial configuration setting changes.

Next up: MAMP Server Configuration

Additional resources: 

More information on Development Environments