We're sorry but this app doesn't work properly without JavaScript enabled. Please enable it to continue.

This lesson's interactive features are locked, please to keep using them

The Protocol

The "protocol" (also referred to as the "scheme") is the first component of a URL. It defines the rules by which the data being communicated is displayed, encoded or formatted.

Some examples of different URL protocols:

  • http
  • ftp
  • mailto
  • https

For example:

Not All Schemes Require a “//”

The "http" in a URL is always followed by ://. All URLs have the colon, but the // part is only included for schemes that have an authority component. As you can see above, the mailto scheme doesn't use an authority component, so it doesn't need the slashes.

Assignment

In the Jello menu, we show users the email addresses of their colleagues. We need that email to be a clickable hyperlink. When they click the hyperlink their default email client should open with a new message ready to send to the address they clicked on.

Complete the getMailtoLinkForEmail function. It should return a "mailto" URL for the given email.