Forum Moderators: not2easy
Even if there would be one, I wouldn't trust it 100%. You would have to worry about whether it covers all the browsers, if it is truly up to date, and that it doesn't mess things up.
It would be an impossible task to write such a program.
All I can say is that it's better to learn CSS and do the conversion yourself. I know that's not what you wanted to hear, but that's the truth...
I asked a similar question a while back and got no answers. Maybe we could start a list in another thread.
so pity.
but i guess, if it's able to do by hand, it should able to be done by a program, if some experts wanna do one. even two textbox with 1 button, running with JS in HTML, will be acceptable for use.
even only do the hack css for ie5.x box module for xhtml strict mode, will be of great help to many many ppl
many ppl learn css by heart. however, version compact problem will make them disappointed.
it's the same problem as js/html version compact problem.
Is there even a list of what:Topstyle (as already mentioned) has a safelist that includes only the following:
# could go in a base.css (ie is fairly harmless and/or universal)
background (color) (url)
color
font-style
font-family
font-size
font-weight
line-height (? never used it myself)
text-align
text-decoration
text-indent
I guess now we need to expand on that, because there must be some more tags that are very well supported.
Anyway, there are several other properties that could be added, such as:
overflow: hidden
overflow: visible
display (buggy on NN4)
padding (except for IE5.x's broken box model)
position: absolute (even though left/top/right/bottom is buggy on different browsers)
float (but "clear" is buggy)
I don't know .. the list is actually quite long .. depending on the element too :(
but i guess, if it's able to do by hand, it should able to be done by a program
I can do it by hand, almost in my sleep... But I wouldn't be able to write a program/script that would do it for you. See, it's not just the CSS properties themselves. You get different results depending on whether it's a single element, the type of element it is, and what kind of wrapper it has (DIV, P, SPAN... if any).
It's difficult enough to do it manually when you ahve the source code to look at. But to write a program that would do it for you, no matter the source code... I'd say it is impossible (and I rarely ever say that something is "impossible").