Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member
Now in order to have content for our tooltip we're going to need to add some content into the HTML so that we can actually pull this out of jQuery later. So what we're going to do is let's scroll up in our HTML file. Let's find the hyperlink that's not inside of the aside, but still inside of the article. It's the one down here that says text-based tooltip. We have an anchor link outside of here with an href. Inside of this anchor tag we want to add some additional attributes. Let's first start by typing class and the class we want to set for this going to be tooltip.
Next property, we're going to set in HTML5 data property. So we're going to data dash and then we're going to make up in attribute name here, tip dash type equals, two quotes, and then let's say "text" inside of that. Then one more attribute. Data dash, tip dash, source equals two quotes, and inside of here we're going to the actual text that's going to show up as the tooltip "This is the tip text." So now we have these three additional attributes inside of here.
Get unlimited access to all courses for just $25/month.Become a member