Skip to main content

The Page Header! HEAD Element!

Next in our list comes the 'head' element which is the child of  the 'html' element.
The head element is a container for all the information about the document. Elements inside <head></head> can include scripts, instruct the browser where to find style sheets, provide meta information, and much more.


The following tags can be added to the head section which will be discussed in detail later:

1.<title>
2.<base>
3.<link>
4.<meta>...
5.<script>
6.<style>.
etc.


 
Now as we can see the title element is actually a part of head element. The head element is also similar to the html element pertaining to an opening and closing tag like <head></head>. Therefore, the previous code can be modified as:

Test code:(Use this code to see if title bar displays the title)
 


<html>
<head>
<title>
My page still has a title within head tag
</title>
</head>
<html>


Note: Always save the <html> element containing file with the extension .html or .htm for it to work. For images please refer to the previous post Webpage has a title.

Comments

Popular posts from this blog

How to program pyramids using loops - 2

In this video tutorial, two of the more patterns have been discussed that relates to the similar pattern problems. What's different about these are that they also include spaces before the stars as a part of the pattern to be printed. Having this extra sub pattern to track spaces  in the desired pattern requires an extra loop to track and control it . For a brief review, We discussed that these patterns if observed carefully are just representation of tables i.e. a combination of rows and columns . And few of the cells in that table are populated with some data according to a logically programmed algorithm with represents a pattern. In these cases, the red triangles shows us the spaces represented by "sp" and therefore unlike the previous pattern these need to be managed by the loop as they occur before the stars in the pattern. So, taking the same approach of rows and columns managing loops, we will have an outer loop that tracks the rows which will start at 0...

Hello World in PHP!

PHP is one of the most powerful languages of the web. PHP is an application server as well as a programming language that has the capability to do loads of stuff like generate dynamic HTML, connect to databases, apply programming logic to the website code, server side scripting, form handling etc. It is one of the most widely used scripting languages. In order to get it running, you will need to have a basic setup preconfigured which we'll cover later in the course. Just to give you all a head's up, we will start with the trivial "HELLO WORLD" program. Test Code : ( Use this code to display Hello World! in the console ) <?php echo "Hello, World!"; ?> NOTE:  Don't worry about anything else you see on the screen just focus on the code and rest will be discussed later in the tutorials. Save the file as " H ello.php " in the DOCUMENT ROOT of your web-server; for XAMPP users like me its the HTDOCS folder in the installat...

Hello world in Java!

Java is one of the most commonly used programming languages in the world today. Most of the work you can ever think in the world of programming can be done using Java Programming. Java is used to program everything from small devices to heavy machines. Everything from your Smartphone to your ATM card is somehow supported by Java behind the scenes. In order to learn Java which you might have also heard as of the most popular Object oriented Programming language of the modern times, we must start with the trivial "HELLO WORLD" program. Test Code : ( Use this code to display Hello World! in the console ) public class Hello {     public static void main ( String args[] ) {         System.out.println( "Hello, World!" );     } } NOTE:  Don't worry about anything else you see on the screen just focus on the code and rest will be discussed later in the tutorials. Save the file as " H ello.java " ,  the .java exte...