HTML (HyperText Markup Language) is the predominant markup language used for creating web pages. In modern web pages, HTML is used to markup the contents of the website, while CSS and Javascript are used to define the styles and behaviors respectively.

learn more… | top users | synonyms (1)

44
votes
16answers
2k views

HTML validation: is it worth it?

What are the advantages and disadvantages (if any) of making sure that all pages validate compared to having non-valid HTML that however works on all major browsers? Also, is having valid HTML after ...
40
votes
7answers
7k views

Why should we use tags like p, span, hx tags when we can use CSS instead?

Why should we use tags like p, span, hx tags when we can use CSS instead? Is it important from an SEO point of view?
40
votes
13answers
4k views

How can I see what my web site looks like in various browsers?

How can I see what my web site looks like in various browsers? Short of actually having every different browser version installed, is there any tool or service that can provide a preview?
33
votes
5answers
3k views

Why aren't we supposed to use <table> in a design?

What are some clear and logical reasons for why we shouldn't be designing websites with tables? Where are the benefits, what has been driving this idea in the industry? When is it okay to use a table? ...
25
votes
3answers
8k views

Is the title attribute (not tag) important to SEO?

The title attribute is an HTML standard element available across most tags. e.g. <li><a title="Widgets listed by household function" href="/widgets/by-function.html">by ...
23
votes
7answers
632 views

When designing a website, how do you usually start?

In the past I've done some HTML, CSS and PHP coding, but I've only ever worked on things that were already "finished" and I've never started a website from scratch. However, I recently purchased a ...
21
votes
10answers
1k views

What is new in HTML5/CSS3?

I've seen this site and this site, but that's a lot to digest. What are the main things about HTML5 that make it different/better than regular old (X)HTML/CSS?
20
votes
10answers
1k views

What's the importance of the “title” tag?

Talking with some other people recently, it came up an interesting topic. The core question at hand is: What's the real importance and weight of the <title> tag in a web site? For ...
19
votes
10answers
9k views

SEO regarding using multiple <h1> tag?

Is is true <h1> tag should not have more than 1 on every page for SEO? Every pages on the header, it includes and <h1> tag. Website Name which show an image from logo class, like this: ...
19
votes
11answers
9k views

Are HTML tables bad for SEO?

A lot of designers discourage the use of tables but I have a layout where I'll use more div structure to achieve something made simple with a table.. Are tables bad for search engines? edit: I will ...
18
votes
5answers
464 views

What documentation exists for HTML, CSS, and JavaScript?

PHP users have the PHP.net docs Ruby users have Ruby-Doc.org Python users have docs.python.org jQuery users have docs.jquery.com All are considered go-to references when working within those ...
17
votes
6answers
2k views

How do I add a favicon to my website?

What markup is the modern standard for adding a favicon to my site? What is the standard image format and size?
17
votes
2answers
365 views

Which meta tags are not worth the effort?

After reading this question about meta keywords, I've been wondering : of all meta tags, which ones are really worth the effort ? I know that the description is used in google search results, and the ...
16
votes
2answers
683 views

To <p> or not to <p>?

I recently had a debate with a colleague who claimed that a <div> tag should be used over a <p> tag when formatting paragraphs. The case against the use of <p> is that it produces ...
16
votes
5answers
6k views

How can I validate HTML offline?

When I'm developing a website locally sometimes I want to check if the html is valid but I haven't been able to find a good tool. I want it partial as a sanity check when I'm troubleshooting layout ...
16
votes
5answers
53k views

Should I escape the Apostrophe ( ' ) character with its HTML entity (&#39;)?

What characters should be escaped with their HTML entities. For example, & is escaped with &amp;. Should ' be escaped with &#39;?
15
votes
6answers
2k views

Form label position for best usability

I'm creating a form that will ask a visitor for their firstname, middle initial, and lastname. I want the those text fields to be all inline, but where should I place the labels? On the left, top, or ...
15
votes
7answers
1k views

HTML and “quirks” vs. “standards compliance” modes: Explain, and tell us why we should care?

What is the difference between "quirks" mode and "standards compliance" mode, when building HTML web pages? How to tell when operating in one mode, vs. the other? Why should people – i.e. ...
14
votes
11answers
2k views

Common optimizations to reduce HTML or XHTML page size?

What are some common optimizations performed to reduce HTML or XHTML page size? Some that come to mind are: removing comments, removing extraneous whitespace, moving repetitive inline styles to a ...
14
votes
4answers
6k views

Should my Title tag be the same as my H1 tag?

I have read that I should make the contents of my <title> and <h1> tags the same. Is that the case or is does Google look at the content of those 2 tags separately?
13
votes
4answers
510 views

Should Site Title be Before or After Page Title?

Apologies if this is a dupe. I tried searching, but didn't find anything specifically addressing this concern. When creating a large(ish) site, page titles usually reference both the site name and ...
13
votes
1answer
1k views

Can I instruct the browser not to look for a favicon?

I have a website that doesn't have/need a favicon. Is there a way to instruct the browser not to waste a request looking for /favicon.ico ? I don't mean filtering logs, but something client-side, ...
12
votes
8answers
3k views

Is inline JavaScript good or bad?

I've currently switched from WordPress to Yii framework and an external developer is rebuilding my site. One thing I notice is that each time he invokes AJAX / jQuery the Yii way, it embeds inserts ...
12
votes
1answer
116 views

Why don't large popular sites such as SO use keyword and description meta headers?

Why don't Stack Overflow, Wikipedia or MSDN etc. include keyword and description meta tags in their page headers? For example Google indexes the first paragraph as a brief description. Is this a ...
12
votes
4answers
3k views

Preventing robots from crawling specific part of a page

As a webmaster in charge of a tiny site that has a forum, I regularly receive complains from users that both the internal search engine and that external searches (like when using Google) are totally ...
11
votes
3answers
15k views

What is the difference between <span> and <div> tags?

I am curious, the span tag seems to work the same as a div.
11
votes
3answers
20k views

301 Redirect HTML Pages

In a web debugger, the html of a 301 redirect page shows up as: <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"> <html><head> <title>301 Moved Permanently</title> ...
11
votes
1answer
571 views

How to make a printer-friendly version of a webpage?

What solutions or techniques exist for offering users a printer-friendly versions of a webpage?
11
votes
8answers
3k views

CSS style viewer/tester

Is there a site out there that has a bunch of typical html for seeing what the css looks like once applied? I mean, something full of table, a, div, span, p, whatever. You go there, paste in your ...
11
votes
1answer
2k views

Is this inline-block trick involving 'font-size: 0' dangerous for SEO?

A while back, I answered this question on Stack Overflow: http://stackoverflow.com/questions/5078239/how-to-remove-the-space-between-inline-block-elements The problem is that elements with display: ...
10
votes
8answers
2k views

Can anyone recommend a good HTML 5 book?

Specifically about canvas. I have been looking around for a few good one.
10
votes
5answers
451 views

What happened to HTML table tags?

I started to code HTML in 1998, and in that time I used a lot table tags, playing with tr and td, I learned many things analyzing the source code of many portals on the internet with notepad and ...
10
votes
2answers
354 views

Communicating image size, best practice

If you are developing a html document strictly using current best practice of keeping styling out of the markup how do you best communicate image sizing? Past best practice wants image height and ...
10
votes
5answers
869 views

What's the point of placing self links on a webpage?

I often see links on webpages that link to the page itself. For example on forums, blogs and even here the topic title is a link and points to the page itself. What's the point of doing this?
10
votes
1answer
8k views

Keep Iphone browser from turning numbers into links

I'm writing a very simple page that is supposed to be viewed on mobile devices. While viewing it in the iphone simulator I noticed that the iphone browser automatically turns any number string into a ...
10
votes
4answers
10k views

How do you save/export changes made in Firebug?

Using Firebug to edit CSS, how do I save/export changes made to the CSS? TOOLS: Firefox, Firebug MAJOR UPDATE: If you know of a way to lock the forward/back/refresh on a FireFox tab, please let me ...
10
votes
2answers
468 views

meaning of HTML “<a rel=douche” rel Attribute?

I have met the following HTML code: <a rel="douche" href="...">blah</a> And I am wondering what is the effect of the "douche" attribute.
10
votes
2answers
454 views

Using &amp; instead of &?

I'm noticing that browsers correctly parse "&" when they encounter them. So is there any reason i should be using & in HTML text on my site?
10
votes
6answers
3k views

What's the best way to show a message for only IE 6 and IE 7?

What's the best way to show a text message for only IE 6 and IE 7 ? Should I add a html tag to my webpages and normally hide it with css for all browsers except the above mentioned ? And when I use ...
10
votes
2answers
475 views

Is <a href=“#”>link</a> a broken link?

When using empty URL fragment links, to send a user to the top of the page (e.g. <a href="#">return to top</a>), are these links considered broken or invalid? One of my tools is returning ...
10
votes
2answers
3k views

Is content inside a <noscript> tag indexed by search indexes?

Is content inside a <noscript> (HTML4, HTML5) tag indexed by search engines? (Inspired by this question)
10
votes
1answer
923 views

Order of HTML meta tags

A SEO company suggested we change the order of our HTML meta tags so that <title> and <meta name="description"> are the first two. They say this is to ensure search engines can utilize ...
10
votes
3answers
8k views

http-equiv=content-language alternative - the way of specifying document language

Lots of web sites uses following meta tag to specify the default language of the document: <meta http-equiv="content-language" content="es-ES"> When I go to W3C site and read about HTML ...
10
votes
3answers
708 views

Why use HTML entities instead of just putting Unicode characters in HTML?

Let's say I want to put a non-bland character in an HTML file; for instance, '→'. Is there any reason why I should enter it as '&rarr;' instead of just putting '→' in the HTML file? Assume my HTML ...
10
votes
2answers
195 views

Automated Website Testing/Sanity/Quality

I am thinking about building a tool that starts from the root of a webpage and traverses the entire website gathering a list of resources such as CSS/HTML/Javascript files and then runs CSS/Javascript ...
10
votes
2answers
1k views

Proper usage of <title>, <header>, <h1> and <h2> in a HTML5 website?

I have been studying this subject for several days and have found many conflicting suggestions with regards to search indexing. I am working on a project which has a lot of different pages ranging ...
9
votes
3answers
2k views

Can I use <link> tags in the body of an HTML document?

Can I use <link> tags in the body of an HTML page? I tried to find the answer to this question, but found contradictory information. When adding Schema.org microdata markup to an HTML page, I ...
8
votes
4answers
1k views

Will enclosing an <h1> element inside a <p> element affect SEO?

Is it okay (SEO-wise) to construct the following line as such: <p>These are the best <h1> Cheap Widgets </h1> ever. </p> Wondering if this looks too unnatural for search ...
8
votes
3answers
317 views

What font technique is being used here?

While I was attending this event (http://worldtour.fogcreek.com/) I noticed this page had custom fonts for the Address part in the top left corner (i.e "Fog Creek Software 55 Broadway Fl 55....") When ...
8
votes
4answers
704 views

What is the purpose of leading slash in HTML URLs?

I have noticed that some blogs posts have links using a value starting with / in the href. For example: <a href="/somedir/somepage.html">My Page</a> Does the leading / mean the path is ...