banner
Welcome to HTML.co.uk, the number one resource for all news, information, and happenings regarding HTML.

Updates: HTML.co.uk has just been relaunched. Subscribe to our RSS Feed to stay on top of HTML news and techniques.
Dec
2nd

URL Encoding for HTML using the ASCII Character Set

Author: Editor | Files under HTML Tutorials
Tags for this article: , ,

The URL encoding basically converts different characters into a certain format so that it can be safely transferred on the internet. URL is actually known as uniform resource locator and the web browsers request different pages form a web server by using a URL. The only way of sending the URL over the net is to use the ASCII character-set. Sometimes URLs contains certain characters which are outside the ASCII character set. In such cases the URL should be converted and this is what is done by URL encoding so that it is changed to a valid ASCII format.

Functions such as JavaScript, ASP and PHP can be used for URL encoding a string. There are a large number of ASCII characters which are represented in different ways and you will have to remember all these to become an expert in URL encoding. The ASCII character space is displayed through URL-encoding %20. By using %21 URL-encoding you can display an exclamation mark as well. On the other hand, the ASCII character % is denoted by %25 URL-encoding. The ASCII character + is denoted by %2B URL-encoding. Remembering all these characters and URL encoding is not easy but gradually you will be able to remember most of them or the most important of them.

Another very important ASCII characters are the numbers and these can also be denoted by various URL-encodes. ASCII characters such as 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9 is denoted by %30, %31, %32, %33, %34, %35, %36, %37, %38 and %39. Remembering these codes are quite easy because these are in sequence. Displaying all the English alphabets from A to Z is very important and these are displayed using URL-encoding %41 to %59 till Y and % 5A for Z.

There are various other ASCII characters that are described by various other URL-encoding. ASCII characters such as NUL, SOH and STX which are described as null character start of header and start of text is encoded through %00, %01 and %02. Some other ASCII character such as EOT, ENQ and ACK which are described as end of transmission, enquiry and acknowledge these are encoded as %04, %05 and %06. Various other ASCII characters such as BEL, BS, HT, LF and VT are described as bell (ring), backspace, horizontal tab, line feed and vertical tab are actually encoded through %07, %08, %09, %0A and %0B.

Various other ASCII characters includes DLE, DC1, DC2, DC3, DC4, NAK and SYN is described as data link escape, device control 1, device control 2, device control 3, device control 4, negative acknowledge and synchronize. The above mentioned characters are coded as %10, %11, %12, %13, %14, %15 and %16. All these characters can be easily found online and you could copy it from their as well. URL encoding is essential for HTML as it makes the entire job much easier. Any search engine will provide information on URL encoding and it is easily understandable as well.


Nov
22nd

Converting HTML Based Web Pages into XHTML: Our Quick Guide

Author: Editor | Files under HTML Tutorials
Tags for this article: , ,

Converting HTML based web pages into XML is not a big deal but you need to follow certain simple steps for doing it in the correct way. You should always convert the pages into some semantically meaningful and application specific mark up language. One of the semantically meaningful markup languages is the MathML which is also known as chemical mark up language. The W3C’s XHTML recommendation ahs provided a convenient list of differences between these two languages. There are a number of differences that should be considered while understanding how to convert HTML based web pages into XML. Some differences would even surprise HTML developers because these are so simple and unique.

It is already known that XML element names are case sensitive or in a hypothetical XML form of HTML. The difference can be explained with an example as <img> tag would actually represent a different element than <IMG> or <Img>. Hence the XHTML authors opted for all lower case element names which solved this confusion. On the other hand various other empty elements that are represented in HTML as <br>, <hr>, <img>, etc. must use some special XML the empty element tag form with a slash. Just putting a slash can solve this problem as <br> tag becomes <br/>. Then there are certain browsers that may not understand XML. Some of these browsers may choke on this empty form.

This problem can be easily solved as well as you can put proceed the slash with a space. Hence a tag becomes <br /> instead of the earlier <br/>. The above mentioned is one of the very rare and you can only blame the browser vendor. But now you can easily solve such problems by putting a space after the slash. But there is another very easy and time saving way to convert the existing HTML documents into the XHTML form. The easy way is to use Dave Raggett’s free HTML Tidy which is a very useful utility. This programme is available at the W3C website and is totally free to use as well. The utility Tidy can work on almost all platforms and a wide variety of command parameters which actually direct its processing.

A wide number of vendors and developers have actually incorporated or integrated Tidy into their own product that proves it utility. On some Windows based devices there is a very popular tool which is named as Chami.com’s free HTML kit. But then converting your HTML documents to XML application is a bit difficult. HTML element names don’t have an inherent meaning which is actually a hallmark of all XML applications as a normal person thinks of them. Converting them is not that easy as it has a lot of commands involved in it and you can easily find all of them online. Installing some application like Tidy is a better option because such programmes are very user friendly and will have minimum of hassle. It is very easy to install and you can easily download it online as well.


Nov
13th

Understanding XHTML: A Basic and Simple Guide

Author: Editor | Files under HTML Tutorials
Tags for this article: , ,

The XHTML stands for Extensible HyperText Mark-up Language. XHTML is considered as a stricter and a cleaner version of HTML. XHTML is in the family of the XML mark up language. Prior to HTML 5 it was defined as SGML or standard generalised mark up language but XHTML is actually an application of XML or we can say a very restrictive subset of the earlier SGML. The XHTML has become had became World Wide Web consortium. The XHTML is actually a reformulation of three HTML 4 document type. It is believed that XHTML is the next step in the evolution of the internet. Hence we can say that XHTML has amazing future and backward compatibility.

Some people believe that XHTML is not as useful as it is said to be but it proves to be one of the most reliable product in the future. XHTML is somewhere related to HTML and this can be proved by the following points:

  • In HTML there are some tags which always remain empty and do not have a closing tag either. On the other hand in XHTML each and every element must be closed.
  • The XTML has some similarity with HTML which permits omitting the end tags for various elements.
  • In HTML each and everything is case insensitive whereas in XML every element and attributes are case sensitive. Well XHTML requires all the elements to be in lower case.
  • Some versions of HTML do permit quotes to be omitted from the actual attribute values. Whereas in XHTML all the attribute values should be enclosed by quotes it can be single or double.
  • HTML does permit attribute minimisation options in which a Boolean attributes can actually have their value entirely omitted.
  • Certain required elements can be omitted in HTML in which they are added by a parser. Whereas in XHTML the DOM must be determined without even knowing what all elements are actually required hence these tags should be specified properly.

XHTML is actually identical to HTML 4.01 which makes it even more user friendly. All browsers in the world support XHTML which is the biggest benefit of it. As it is so compatible hence it is used by a number of content management systems all over the world. It is very easy and interesting to learn how to publish XHTML 1.0 type of documents in the HTML compatible manner. Such sought of HTML compatible media content is actually sent using the HTML media types. Mostly all web browsers support the XHTML media types but the Internet Explorer of Microsoft does not support it.

The Internet Explorer does not render the file but actually a dialogue box opens which invites the user to save the content. The very latest versions of Internet Explorer show this tendency. The XHTML is not used preferred by everyone but it will be in great use in the coming future. XHTML is still evolving and will be very effective in the coming future. Learning and understanding XHTML is very easy and you can easily get all the information on the internet.


Oct
30th

Character Entities in HTML and Other Advice

Author: Editor | Files under HTML Tutorials
Tags for this article: , , , , ,

Some characters are actually reserved in HTML which should be replaced with character entities. A number of signs such as greater than or less than cannot be used because the browser will treat them for mark up. If anyone all around the world wants to put these symbols then he or she must use character entities in the actual HTML source. These entities are fixed and you will have to put fixed characters. These entities are like symbols which are to be remembered whenever you are putting some signs online. You can easily find all the character entities online which make the job much easier.

At first you will face some difficulty but gradually you will get used to it and these are easy to remember as well. There is a disadvantage as well because all browsers may not support these entities but most of them do support. One of the most common and important entities in HTML is the non breaking space. HTML normally truncates spaces that you will put in the text and sometimes you really want to put spaces with a purpose. Even if you put 5 spaces in your text HTML will automatically remove 4 spaces out of them. In order to use spaces between text you will have to use &nbsp; character entity.

Following are some of the most commonly used character entities include &lt; which is used for less than sign. The &gt; is used for greater than sign and &cent; is used for a cent sign. Some other very important charter entities are &pound; which is used for a pound and &yen; yen. The description of copyright and registered trademark is very frequently used and for putting it you will use &copy; and &reg; character entities. Above mentioned are very important and remembering them will help you in many ways.

There is an entity number given to each of the entity characters which makes it even easier for you to remember it. Various other signs are important and are used very often but HTML may not support it as well. Some of the most important punctuation characters include a fraction slash which is presented through &frasl; entity and it is numbered as &#8260. Inverted exclamation mark is represented through &iexcl; and this entity is numbered as &#161. The trademark sign can only be represented through ™ which is numbered as &#8482;. Another very important character entity is for a thin space which can only be displayed through &thinsp;. It is numbered as &#8201; and is very commonly used as well.

On the other hand, if you are producing a website that includes mathematical symbols then you will have to use separate set of character entities. If you want to add a division sign inside the website then the character entity used is &divide; and it is numbered as &#247;. The degree sign is commonly used as well which is numbered as &#176; and the character entity is &deg;. Learning these character entities is very important in order to efficiently create a website.


Oct
28th

Defining Character Sets for HTML: Important for Different Languages and Alphabets

Author: Editor | Files under HTML Tutorials
Tags for this article: , , , ,

Character sets basically decide how bytes that represent your text of the HTML document are translated into readable characters. The Windows Internet Explorer basically interprets bytes into a document as per the applied text set translations. The browser should actually know what character to use in order to display the HTML page in the right way. The character set such as ASCII used to support some time ago as it does support numbers from 0-9. Many countries may use some characters which are not the part of ASCII hence they use a default character set that is ISO-8859-1.

There are different character sets for different countries as North America, Western Europe, Latin America, the Caribbean, Canada and Africa supports ISO-8859-1 character sets. On the other hand, countries from Eastern Europe support ISO-8859-2 and are described as Latin alphabet part 2. SE Europe, Esperanto and miscellaneous other countries in the same region support ISO-8859-3 character set which is known as Latin alphabet part 3. Character set ISO-8859-4 is supported in a number of Scandinavian countries and Baltic’s. The ISO-8859-5 character set is used where Cyrillic alphabet is used such as Bulgaria, Belarus, Russia and Macedonia. Various languages that use Arabic alphabets support ISO-8859-6 character set.

The Greek language and various mathematical symbols that are derived from it support ISO-8859-7 which is also described as Latin or Greek part 7. The Nordic language supports ISO-8859-10 which is also described as Latin 6 Lappish, Nordic and Eskimo. The Japanese and Korean language is supported by ISO-2022-JP-2 and ISO-2022-KR character sets. It is not as complex as it seems but all these details are very important to know in order to define character sets. All the characters sets which are explained above are very limited in size. Hence all of them are not compatible at multilingual environments.

There is a Unicode standard which actually covers all characters, symbols and punctuations that is used all around the world. This is a very interesting and helpful standard where you can process any sort of platform, language or program. The Unicode Standard is basically developed by the Unicode Consortium. The ultimate aim is to replace the already existing character sets. The Unicode Standard has recently become a success and it is implemented in Java, XML, CORBA 3.0, WML, ECMAScript (JavaScript). It is also supported in a number of operating systems and is also supported by all modern browsers.

A number of character sets implement the Unicode and UTF-8 and UTF-16 are the most commonly used encodings. In the UTF-8 a character set can be from 1 to 4 bytes. It can also represent any sort of character that is there in the Unicode. It is the most preferred encoding for e-mail and webpages. The UTF-16 is actually a variable length character. It is actually capable of encoding Unicode repertoire. It is used in a number of major operating systems such as Microsoft Windows 2000, XP, 2003, Vista, CE and Java and .NET byte code environment as well.


Oct
27th

How and why you should use META Tags

Author: Editor | Files under HTML Tutorials
Tags for this article: , , , ,

META tags are a very important element of HTML because these can help direct large amount traffic towards your website or you can also hide a certain page from being a search engine. These META tags should be decided intelligently so that your website can be easily searched within a search engine. We can say that META tags are basically used to specify keywords, description and a page’s title. These are of various types and each type has a very important role to play.

The META Description Tag

This is one of the most important META tag and is put for influencing the readers. It generally consists of 200 to 250 characters but only a small part is displayed on the screen. When you search for something on a search engine the first thing you get is a title but this title is provided with certain information and this small description is known as the description META Tag. You are only able to read a small portion of the article and for reading the entire article you will have to click on the title and open that particular webpage. The biggest benefit of creating a META Description Tag is that it provides some control on a number of crawlers. The simplest form of doing it is taking the first sentence of your body copy and using it as a META Description Tag.

The META Keywords Tag

Another very important META Tag is the META Keywords Tag. The META Keywords Tag provides extra text for a number of crawler based search engines. These Tags are normally ignored by most of the crawlers but it can still provide you that slight edge over others. The META Keywords Tag should be decided intelligently in order to get positive results. This can be explained by an example lets suppose you had some page that was all about “car rental” and you have mentioned the same word a few times in the actual page then you should take “car rental” as the META Keywords Tag. If you follow the above mentioned step then the META Keywords Tag will definitely boost the page. On the other hand if your page does not have the words “car rental” then keeping it as a META Keywords Tag is of no use. Hence we can say that this META Tag works in conjunction with the text that you have in the body copy. But there is no guarantee that all crawlers will support it but may be a few will which will help improve the ranking of that very page.

The META Robots Tag

The META Robots Tag is very important as well. This Tag helps you to specify that some particular page should not be indexed by any search engine. You can easily keep out the spiders by adding the text in between the head tags of the page which you don’t want to get indexed. The important thing is that this META Tag is supported by all crawlers and by using it you can easily block any page that you want.


Oct
5th

Using HTML Tag Attributes: How to Correctly Use Attributes and Tags in HTML

Author: Editor | Files under HTML Basics, HTML Tutorials
Tags for this article: , , , , ,

HTML tags are the basis for web page design. For more flexibility in designing HTML were defined attributes for HTML tags to change the behaviour of a specific HTML tags. There are many cases when designing a web page if you want to change the default behaviour of tags. For example, you could change the background colour of the entire page or a section of the page. You can change the alignment of some text or a unique style for the representation of a tag.

Here are some examples of HTML attributes

HTML tag is used to change the background colour or image for the whole body from a website. Understand that browser displays the contents of the body tag on the greater part of the site. By default, the background of browsers used when the tag <body Begegnung> is white. If you want a background colour other than white, use the bgcolour attribute. The following day will change the background colour of a Web page from the default white to gray <body bgcolour = “gray”>

If you want a picture, including the background to a web page, you can use the following code:
<body Background = / images / background.gif>
This example assumes that you have specified a folder on your Web server images, and in this case, there is an image called background.gif. In the case of an image in the background when the image is not large enough to fill the entire bottom of your Web site, the browser displays the image repeated vertically and horizontally to fill the background.

Link with anchor tag

The World Wide Web, the basic benefit depends on their ability to integrate documents and on the Internet so that users with a fast connection from one side to the other side. Linking documents to HTML via the anchor (<a>) tag. The anchor tag is not in itself sufficient to say, a link to the browser, too.

<a href = http://oursponsorssite.com> Visit our Sponsors </a>
This specific HTML code intimates the browser that the text “Please you should visit our sponsors” is the anchor text of a link. When the user clicks on the anchor text, it is referred to oursponsorswebsite.com URL.

Displaying an image using the image tag

HTML pages would be pretty boring without the use of images. The need to tell the browser to find where an image is a good example of how to use the HTML attributes. The images are included. Insufficient Similar to the anchor tag above example, the tag would be alone. The attribute image tag “src” is necessary to tell the browser where to display the image, as in the following example:

“/ <img src = images / logo.gif” width = “150″>

this block of code tells the browser to place an image in the document. The browser will be directed to the image file logo.gif from the images reach the top level folder for the document. You can also specify the width attribute defined in the day.


Oct
5th

Create a Web page using HTML: Covering the Basics and Bare Minimum

This article describes how to create a web page using HTML (Hypertext Markup Language). You can use the steps outlined here with a simple Web browser and Windows Notepad. However, make sure you register with HTML files. “HTML”. Notepad appends. “Txt” extension

The HTML files contain structures known as tags. Tags, text, particularly left and right hooks around like <html> or </ html>. Note: Normally, there is no space between a colon and the text. However, the rooms will be used in this article. In this way, the tags appear as text and not executed as code from a browser.

<html> mark the beginning of the code and HTML </ html> indicates the end. They can also add tags to add an additional structure. Generally, the “head” and then “body” are mentioned in the section between the tags. Thus, our single file can be written as <html> <head> </ head> <body> </ body> </ html>.

1. Add a title to the HTML file. In general, the HTML files containing a title (Note: This is not the same as the header. “Head will be presented below in step 3). Title defines the text in the “title bar” of the browser display when you make a specific page. Titles are placed in the “head” (that is, between the header and </ head>). For example, one could simply file contains the following titles: <title> this is the title </ title>

2. Add content to the site. In step 1, we set the text in the title bar of the browser window appears. However, to display text in the browser window itself, we need (this text in the body section of the file In other words, between <body> and </ body>) tag. This can be done with the paragraph tag, <p>. For example, for “HTML Web Design is an interesting area. The developer shall install a functional and useful website,” We have <p> HTML Web Design is an interesting area. The developer is required to install a site functional and useful web </ p> in the body section.

3. Add a header. Then we add header content of the paragraph. Text header is usually larger than paragraphs of text. Use the “real” size can be defined by CSS (Cascading Style Sheets). Although not covered here, will be CSS in the Learning mentioned HTML – Part 3 – Basic CSS formatting “section. A header can be added to the lineup <h1>. Thus we can write the following headings : <h1> HTML Web Design </ h1>

4. See code page. In general, sites on the Internet containing the constructs above (together) with a number of other encoding functions. To see the HTML used to generate a page, go for it and the View “> Select Source” or “View>” Source option menu. Using the menu, try <title> research <h1> <p> and tags on a page.

The above are the simple steps to create a webpage with the use of notepad and browser.