HTML vs Coders Logic| User | Message | |
Posted : Tuesday, 29 May 2012, 11:11 | Permalink | Mark Here |
spinal

 
|
Proper coding and html/css don’t seem to work the same way the simplest things seem wrong to me.
-----

3DS - 1762-2660-3218 |
 | |
| Posted : Tuesday, 29 May 2012, 11:11 | Permalink | Mark Here |
9572AD

 
|
html/css is "markup". Mental dilemma solved. Also, a lot of it is very wrong. I gave up in the early days of html4, and it doesn't look to be any better today.
----- All the raw, animal magnetism of a rutabaga. |
 | |
| Posted : Tuesday, 29 May 2012, 11:15 | Permalink | Mark Here |
JL235

 
WW Entries : 7
|
-hugs HTML-
The different sections make a lot of sense to me. When I used to use Java, it was always a pain, due to how much stuff I had to code to make a simple GUI.
----- PlayMyCode.com - build and play in your browser, Blog, Twitter. |
 | |
| Posted : Tuesday, 29 May 2012, 11:41 | Permalink | Mark Here |
HoboBen

 
WW Entries : 9
|
Outside of the more advanced CSS tricks, I've found that 99% of problems can be solved by
* never using em units
* never put width & padding or height & padding into the same CSS rule.
That at least gets things looking the same in different browsers
-----
github |
 | |
| Posted : Tuesday, 29 May 2012, 13:03 | Permalink | Mark Here |
JL235

 
WW Entries : 7
|
Hoboben never put width & padding or height & padding into the same CSS rule.
I presume because it gets added on? You can change that behaviour using 'box-sizing', which is much more natural.
The code to do this is:
-->
There is also a '-webkit' version, but Chrome and Safari support the non-webkit prefix, so it's just not needed. It is however still needed for FF.
Border-box is also what IE was doing when it famously get got border sizes wrong, although it wasn't actually standardized for all elements at the time, so it was neither right or wrong. Personally, I think IE got it right, padding should erode inward by default, as this is how most designers think about a layout.
----- PlayMyCode.com - build and play in your browser, Blog, Twitter. |
 | |
|
|