How To Create Hyperlinks

Table of contents:

How To Create Hyperlinks
How To Create Hyperlinks

Video: How To Create Hyperlinks

Video: How To Create Hyperlinks
Video: How to Create External Hyperlinks in Microsoft Word 2024, December
Anonim

The main feature of the language of hypertext markup of documents - HTML is the ability not only to carry out the necessary markup of the document, but also to link together several documents that can be at any distance from each other. These capabilities greatly facilitate the task of navigating, both between separate documents and within one complex one. Basically, a link is the same tag with certain attributes.

How to create hyperlinks
How to create hyperlinks

Instructions

Step 1

In order to create the simplest html-pages, the most ordinary text editor "notepad" is enough. At the initial stages, you should study the basic rules for creating documents in the html language and remember at least the basic tags. If you immediately work with editors where auto-substitution is present, then the memorization process can be delayed. However, in order to work with the code more clearly, it is recommended to use text editors with text highlighting, such as "Notepad ++".

Step 2

Start with the simplest example. Create a folder for the test with any name you like and in it create two files with the.html extension - index.html and page.html. Further, in each of them, write down the basic "framework" underlying any html page:

Page title

*** the main page code is written here ***

Save changes to files.

Step 3

Open the “index.html” file for editing and write the following in the location for the source code:

Link to page pag

Here "a" is a tag for forming a hypertext link. The “href” attribute indicates the address to which the user will go by clicking on the created link. It can be either a page in the same folder as the main page, or any network address. If you specify the path to a file in the address, then you will get a link to download it, because when navigating through it, the browser will try to open the file, and for this, the file will need to be saved first.

Step 4

Explore also the additional tag attributes of a regular link to a document or file, you can also create a link to create a letter.

For example:

DarkHTML - link for sending mail

Step 5

The link can also cause the execution of certain commands in the javascript language.

Example:

new window link will open the document in a new window 300 * 200

Recommended: