TABLE construction not understood

‘HTML, The Definitive Guide’ by Musciano & Kennedy, gives the following simple example of a table…
[php]

Kumquat versus a poked eye, by gender
Preference
Eating Kumquats Poke In The Eye
Gender Male 73% 27%
Female 16% 84%
[/php] It works perfectly, BUT I don't understand it. One question: Why is 'Preference' printed in the 2nd column and not the 1st? (I give up!) Thanks for some understanding

Envision the table like cells in a spreadsheet (excel etc). Since you want two open cells in the top left you need to actually print the html for those two cells, then you add two cells containing Preference… etc

Just try to change it and reload the page and see what happens with the table. It’s a great way of learning.

Thanks, JimL. A vizual analog is exactly what I needed. Been practicing the last couple of hours. Gradually getting the hang of it.

Appreciated,
usit

Sponsor our Newsletter | Privacy Policy | Terms of Service