innerHTML

innerHTML is only simple for the CLIENT side of a web app From a client-side point of view, innerHTML is pretty simple to use. You just get an XHTML response from the server, and drop it into a web page with an element’s innerHTML property. function displayDetails() { if (request.readyState == 4) { if (request.status == 200) { detailDiv = document.getElementById(“description”); detailDiv.innerHTML = request.responseText; } } } The problem is that the server has to do a lot of extra work. Not only does the server have to get the...

read more

Horizontal HTML rules

Using a horizontal rule element (<hr />) helps you include solid straight lines (rules) on your page. The browser creates the rule based on the <hr /> element, so users don’t wait for a graphic to download.                                     A horizontal rule is a good option to ✓ Break a page into logical sections. ✓ Separate headers and footers from the rest of the page. Formatting When you include an <hr /> element on your page, as in the following XHTML, the browser replaces it...

read more

Formatting WebPages with (X)HTML

We will now describe the markup and document structures that make Web pages workable and attractive. We examine HTML document structure (including document headers and bodies) and show you how to put the pieces together correctly. After that, we talk about organizing text in blocks and...

read more

Getting to Know HTML and CSS

Web pages can accommodate many kinds of content, such as text, graphics, forms, audio and video files, and even interactive games. Browse the Web for only a moment, and you see a buffet of information and content displayed in many ways. Every Web site is different, but most have one thing in common: the Hypertext Markup Language (also known as HTML). You’ll also run into Extensible Hypertext Markup Language (XHTML) and Cascading Style Sheets (CSS) pretty regularly, too. Whatever information a Web page contains, every Web page is created...

read more