Category: Web Building

No table padding on IE for PC

A small difference in the way IE and other browsers interpret table attributes:

Browsers other than IE will show padding if it is applied to the table tag.

table {
padding:6px;
}

IE does not recognize table padding, and will show contained elements as flush with the edges of the table.

For example:

This is the way Safari 2.0 renders the code below. Note the 6 pixel white padding area between the edge of the table and the edge of the tr.

Continue reading

Firefox more sensitive to malformed comment tags

Firefox is much stricter in parsing comment tags than Safari or IE.
Comments should have 2 hyphens after the exclamation point, no more, no less, and there should be no hyphens within the body of the comment.

So:
<!--
is OK, but
<!----
is not, particularly in Firefox.

Example 1 shows a table surrounded by a properly formed comment tag.
Example 2 shows the same table surrounded by a tag with too many hyphens – the table and all code between comment tags disappears – in Firefox.

Continue reading

Make other extensions besides “.shtml” process for Server Side includes

The default extensions which IIS reads for Server Side Includes are .shtm, .shtml and .stm.

Suppose you want server-side includes to be processed in .htm files also? For example you may have file with the .htm extension which has been on the web for some time and has numerous links pointing at it. You could replace it with a file with one of the allowed extensions, and put a redirect in its place, pointing to the new file. Or, if you have access to the IIS server settings, you could add the .htm extension to the list of files processed for SSI.

Click on thumbnail images to see larger version.

  1. Open IIS Manager and right-click the Default Web Site. Select Properties from the popup menu. The Properties dialog appears.

  2. Select the Home Directory Tab and click Configuration under the Application Settings area.

Continue reading

Make a directory on a server part of another server’s domain

Sometimes it is necessary to have files or an application on one IIS web server (Server B) appear as if they were in the same domain as another server (Server A). For example, you may want

http://serverB.com/content

to be accessible via the URL

http://serverA.com/content 

This is useful in cases where you need to avoid cross-doman scripting issues, or simply want to make everything appear to be hosted under one umbrella domain name.

On an IIS server, this can be accomplished by creating a virtual directory on Server A which points to a directory on Server B.

Continue reading