|
|
|
|
|
by talmand
4962 days ago
|
|
Sure, an application that inserts into HTML can handle what you speak of, but that doesn't address my questions about the statement of CSS being unsuitable for the task of styles. Sorry, but inline styling is still CSS. I know that CSS standing for "cascading style sheets" may cause confusion but all styling for an HTML document is done with CSS. Even the default styles a browser uses on an otherwise "unstyled" document is based on CSS. You can insert styles directly into an HTML element with Javascript and you are still using CSS. But if you start using such an application to insert your CSS directly into HTML then I'm willing to bet you are due for a headache in the future. There are several reasons why inserting CSS inline is a bad idea. First, you are seriously duplicating your code since you have no class structure to work with. Second, you've just given up pseudo classes. Third, good luck maintaining that code, especially if you eventually stop using the program that created this code in the first place. I fail to see how that's easier. "all otherwise unstyled text boxes have a grey background" - those "unstyled" text boxes are now "styled", you seem to be repeating the statement that prompted my response in that somehow CSS is not the answer but then you provide an example that uses CSS. |
|
Matter of definitions. I'm advocating styling one's page inline and/or via javascript, without using external stylesheets. (Well, I'd really advocate styling using attributes a la html3, but it's too late for that now). Call that what you will.
>First, you are seriously duplicating your code since you have no class structure to work with. Second, you've just given up pseudo classes. Third, good luck maintaining that code, especially if you eventually stop using the program that created this code in the first place. I fail to see how that's easier.
I already have a class structure, because my HTML is being generated by a program. The actual HTML is like an assembly language, not meant for manual reading or editing.
Yes, I've given up pseudo classes. I don't think I'll miss them.