Add pictures
Next, we're going to add the picture below to your web page:
- Using your mouse, right-click (or command-click if you're on a Mac) on the picture and choose to Save Picture As. (As with HTML file names, don't use spaces or special characters in the name.) Make sure you save the picture in the same folder as your mypage.html file.
- With mypage.html open in your text editor, add an image tag for the picture that you just saved. The value of the src attribute will be the name you gave the picture file when you saved it just now. For example, if you saved the file with the name "elephants.jpg", the tag should look like this: <img src="elephants.jpg">
- Save mypage.html
- Return to the browser window that has mypage.html open in it.
- Click on your browser's Refresh button.* Your web page should now look something like what appears in the HTML Playground.

Your web page now has a picture in it! You can add other pictures to your page in the same way by looking around the web, saving the image, and then adding an image tag for each of them.
*FYI: Whenever you make changes to your HTML code and want to see how it will display in the browser, first save the changes in your text editor and then click on your browser's Refresh button to update the file.
|