Fill in the blank

The protocol

What protocol should your web apps use?

Your answer:
Not graded. So why do it?

Lesson topics


What's a subdomain?

You have a domain, like But you want to have a bunch of websites on it. Can you do that?

Yes! Subdomains can help. A subdomain is an extended name, based on your domain name, that acts like a separate website.

Take the site you're looking at now. It's at That's a subdomain.

The domain is I had to pay for that. Go to, and you see the main website for the Skilling project.

This website is a subproject, that's part of Skilling. I made the subdomain webapps, and put the files for this website there. It's a separate website from the one at

I didn't have to pay for the subdomain. I can make as many subdomains as I want, without spending a cent. Woohoo!

More importantly, the sites don't interfere with each other. I can mess with the main site at (add files, delete files, whatevs), and this site won't be affected.

More, more, MORE!

There's another course website, on Excel VBA programming. That's at There's another course on web basics, at

So there are four separate sites:

  • the main project site
  • web basics course
  • a programming course
  • this course

(Actually, there are more than that.)

Subdomains have folders on your servers

Each subdomain has its own folder on your server. That's how the subdomains are kept separate.

Here are the folders for the subdomains above. The ~ is a Linux thing. It stands for my user account's root folder.

Subdomain Server folder ~/public_html ~/ ~/ ~/

The mapping from the domain ( to the folder ~/public_html was set up by the hosting company. I didn't change it. The subdomains, I created myself. I could have called the folders anything I wanted (e.g., anything-i-wanted), but I gave the folders the same names as their subdomains, to keep things easy for myself. Easy is good.


Wait. Can a dot be part of a folder's name?

Yes. In Windows, too. Give it a try. Create a new folder with a dot in its name.


OK... Hey! It worked!

Making subdomains

You can have subdomains on your domain, too. For example, you can have one for your final project, and another for your other exercises. Keeping everything separate means that your files won't collide with each other.

Let's do it.


If you forget how to make a subdomain, come back here for a reminder.

Click the Subdomains icon on your cPanel home page. You'll see:

Subdomain form

Type "final" in the Subdomain field. Hit tab. You'll see something like:

Creating a subdomain

The Document Root is the folder where the files for your subdomain will be kept. We'll work on that in the next lesson.

Now make another subdomain. Call it "exercises". Note the document root. It will be something like




Make a screen shot of your subdomains cPanel page, showing at least the subdomains final and exercises (or whatever you called them). It might look something like this:

Subdomains screen

I have about 40 subdomains (really!). Your list will be different.


  • A subdomain adds something to the front of a domain, like
  • Subdomains act as separate websites.
  • Create as many as you want, from cPanel.

Up next

Let's see how you mess with files on your server.