Archive for the ‘HTML’ Category

It is some time very tidious to align the radio buttons and corresponding labels with each other.

Here is the trick to do that. Say you have a wrapper div in which you have radio buttons and labels and id of the wrapper div is radioButtonsWrapper then add the following into your style sheet


.radioButtonsWrapper label
{
float:left;
margin-top:2px;
}

.radioButtonsWrapper input[type='radio']
{
float:left;
}

and for checkboxes


.radioButtonsWrapper label
{
float:left;
margin-top:2px;
}

.radioButtonsWrapper input[type='checkbox']
{
float:left;
}

Some time it is very difficult to find the insecure content on a page e.g we have page and it is on SSL but browser prompts the user that it contains some insecure content as well.

But how can we find that where is the insecure content on this page.

An easy way is to open this page in Google Chrome and see its console. It will show all the insecure content (or references to insecure content) on this page.

Brief History of HTML

Posted: June 16, 2011 in HTML

HTML was started in 1990’s, Its various versions were released up to HTML 4.01 which was compatible with all major browser.

After HTML4.01 its new version XHTML 1.0 was released.  XHTML 1.0 was just like HTML4.01 but uses XML syntax and rule to define elements. There was another version XHTML1.1 came after XHTML1.0. Then the new version that came after that is HTML5.

MIME Types

Posted: May 24, 2011 in ASP.NET, HTML
Tags:

MIME type or Content type is very important concept in HTML pages. Every time when browser requests some thing (HTML page, image, style sheet or JavaScript) from server. Server sends headers before sending the actual content. These headers contains the MIME type of the content which server is going to send so that browser can know how to interpret this content.

Like if browser request an HTML page then server will send its content type as text/html so that browser can handle it properly. Another example, if browser requests an Image which has extension .jpeg then server will send the header which contains content type=image/jpeg.

Some browsers ignore MIME type headers returned from server for the sake of backward compatibility. Because in browsers early age ( up to 1993) browsers did not entertain MIME types because MIME types did exist at that time.

Conclusion is that MIME types are very important concept in web pages and browsers understand and tackle every thing according to its MIME type.