Richard Herrera wrote:

> franky,
>
> You're right. If the example is used once, there really is no benefit  
> to using the script over just using markup. However, if you're  
> applying the corners to multiple elements, well, now you're talkin'.  
> (The script could easily be modified to work by class name, multiple  
> elements, etc...)
>
> # of lines of script, one element: 12
> # of lines of markup, one element: 4
>
> # of lines of script, 10 elements: 12
> # of lines of markup, 10 elements: 40
>
> As for no javascript = no corners, the corners are superfluous  
> anyway. It won't hurt the site's usability, which is a key factor in  
> unobtrusive javascript use.

Hi Richard,
You're right too. For "heavy cornering" pages [1] a javascript to 
implement the span's or div's can be easy for writing the code, and can 
save markup-lines.
On the other hand, if there are elements with slightly different 
corners/borders, the script has to be extended, while with the extra 
html-lines it's just the use of an other class to get (or easy change) 
the used images/borders. But also that is possible by script.

If we make a function of the amount of coding characters for the script 
and for the markup way in a special case (in relation to the download 
time of each), somewhere will be the break even point, and we can make 
the decision depending on what side of the graphic we are. :-)

- And indeed, the usability isn't hurt by disabling js.
So I think it's up to the developer's (or client's) taste what is 
wanted: a site which is "always the same looking, script or noscript" or 
not.

Oh, I almost forgot the alternative of serverside scripting. [2] If for 
instance php is possible, then in the html some php-includes can replace 
the repeating lines. Then the "javascipt disabled" problem isn't 
occurring, and the 40 markup lines only have to be 10 lines. Can be done 
by shtml too, I think.

Greetings & a good 2007!
francky

[1]
Or for adding corners to an existing page, without changing the html.

[2]
The download speed will be the same as the "complete html" way, but the 
html code of the page is cleaner.


______________________________________________________________________
css-discuss [EMAIL PROTECTED]
http://www.css-discuss.org/mailman/listinfo/css-d
IE7 information -- http://css-discuss.incutio.com/?page=IE7
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to