One of the most basic elements of the HTML document is the frame. A frame is basically a device which allows you to open two or more pages in the same window. Mostly the frame concept is used in cases where you wish to split the window. As is the case with many websites, the left hand side is like a navigation strip, a separate page which is a tabulated list of the topics with the relevant links, while the right hand side shows the content related to those topics.
Reading this you might be misled into believing that there are two pages in the window but there are in fact three pages. One tends to forget there is one page which is holding both the pages. This page is called the ‘container’ page, which contains both the pages. All we need to do is open this page and both the other pages automatically open in this page. The format of this page is similar to any other pages.
The HTML frames concept is generally regarded as quite complicated and very hard for new users to grasp. There is an on-going debate among the champions and critics of frames. The critics feel that frames are associated with a few problems, which is why they wish new users to avoid them.
One popular opinion is that they interfere with the basic concept of the web. The web is ideally supposed to be a group of pages, each page with a separate URL and these pages are simply interlinked. On the other hand, frames allow number of pages to have the same URL and when one bookmarks any of these pages, they end up with the URL of the container page.
A second problem with the frameset pages is that they are not browser friendly. Although not a problem now but a bunch of earlier browsers could not access the framed pages. Even now, when such pages are opened on devices other than computers, like palmtops or phones, they do not allow the browser to resize them which makes page viewing cumbersome. Similar to the resizing issue is the printing problem. Browsers find it hard to print such pages and the prints are never satisfactory. There is also the general overall feel that such pages are hard to code especially be novice coders.
Arguably the biggest problem with frames is that they are not search engine friendly. Even search engines like Google do not go through the content of the internal pages and only read the content of the container page.
The champions of frames on the other hand feel the benefits they create are worth a few hassles and they mostly cite the example of inline frames. Inline frames are special frames which circumvent most of the aforementioned problems. Inline frames are also called floating frames. The basic difference between these and the conventional frames is that these pages open in your container page like images or tables would. The coding for these is also quite easy and they present no obvious problems.
URLs (Uniform Resource Locators) are the addresses of all the links and resources which are globally hosted on the World Wide Web. A web page address like http://www.yahoo.com is a URL. It takes you to the home page of yahoo. Whenever you click on a link on a web page, it takes you to another web page. Technically speaking it redirects you to a new URL. Therefore we can say that every hyperlink is associated with a URL. Generally what we type in the address bar is like yahoo.com and then the Yahoo website opens in our web browser. It does not show any errors because the DNS resolves yahoo.com in its full format automatically. Actually yahoo.com is not the complete URL. A complete URL consists of different sections each indicating important information about the web page.
Let us take a comprehensive example of a URL such as
http://www.3seas.com/html/introduction.htm.
This URL has different sub sections which are described below:
- Scheme: It defines the type of protocol which has been used in a particular URL. For eg; the http is the scheme which defines the type of internet service used.
- Host: It defines the domain host. The default host for http is www
- Domain: It defines the domain name which has been registered online. 3seas.com is the domain name.
- Port: It defines the port number on which the http service is running. It is not displayed in the URL.
- The default port number for http is 80. However, this port number can be changed by the IIS administrator.
- Path: It shows the complete path of the directory located at the web server.
- File Name: It tells the name of the document whose contents are being displayed on the screen. In our example, introduction.htm is the file name.
Thus, technically we can split a complete URL as:
scheme://host.domain:port/path/filename
The domain part of the URL can also be split into logical parts. In http;//3seas.com/html/introduction.htm, The 3seas.com is the domain name out of which 3seas defines a unique entity on world wide web (also known as 1st Level domain). The .com represents the top level domain. This is used to describe the type of website. There are predefined standards which indicate the top level domains and their corresponding meanings. Some of the popular ones are:
COM It shows that the web page is intended for commercial business
2) .ORG It represents a non commercial community website
3) .NET This is used by ISPs (Internet Service Providers)
4) .MIL It is used by Military of United states only.
5) .GOV Used only by government agencies
Apart from the top level domain and 1st level domain, a domain name can also have various sub domains arranged in a hierarchy. All of them are separated by a period ‘.’ The left most represents the lowest level in domain hierarchy and the rightmost represents the top level domain. A typical example of domain name hierarchy is:
www.india.asia.nokia.com
Where india represents the lowest level in the domain hierarchy and .com represents the top level domain.
In HTML coding the URLs to a link are defined with the help of <a> tag. For eg:
<a href=””http://www.yahoo.com””>Click Here</a></p>
According to the above example you will be redirected to yahoo.com if you click on Click Here text on the web page. Although you will not find any difference whether you type the URL in upper case or lower case because the DNS server resolves that automatically, but it should be noted that the URLs are always case sensitive.