A bit about

Hello, everyone! All you can see below is just my bank of information. Some material I've found in the fathomless net, some I've learned myself. Don't think all of the information here is right or actual, but may be it could be of use for you :) All feedback is welcome, especially constructive ones :)

Thursday, June 25, 2009

Syntax highlight for HTML

VIM can create an HTML file with highlighted syntax for browsers.

To do this:
- open you file in Vim
- ensure that syntax is highlighted
- type command ":runtime! syntax/2html.vim"

You'll obtain file with the same name, but with ".html" extension with highlighted syntax.

Thursday, June 4, 2009

HTML: 1-pixel table border without CSS

I had to create a table with 1-pixel black border without CSS because I generated markup for an e-mail and most of Mail clients break all CSS when you push "Reply".

I tried border="1", but it didn't work because the border was in relief. Then I tried style but it didn't work too, because it left only outer border without any lines between cells. Making a border for each cell also didn't work because border between 2 cells was 2-pixel length.

Finally, I found a solution:
<TABLE cellSpacing="1" cellPadding="0" border="0" bgcolor="#000000">
<TR bgcolor="FFFFFF">
...


The idea is 1-pixel spacing between white cells and black background of the table that looks like border. You just set bgcolor of the table to color of your border you want to see and then set bgcolor of all rows to the color of outer background (so they seem to be transparent).