Still trying to get the navigation control of a new site working the way I want.
I simplified my problem to this piece of code:
<!DOCTYPE html>
<html>
<head>
<title>Test</title>
<style>
span { display: inline-block; height: 50px; vertical-align: top; background-color: Yellow; }
span.block { background-color: Red; width: 15px; }
</style>
</head>
<body>
<span class="block"></span><span>A B C D</span>
<span class="block"></span><span>E F G H</span>
</body>
</html>
This code renders to:
However, the spans are generated from an XSLT in Umbraco. Even if the source states <span></span> it generates <span /> like this:
<span class="block" /><span>A B C D</span>
<span class="block" /><span>E F G H</span>
This code renders to:
Why is it doing this?
What's the difference between <span></span> and <span />?
PS: In the real thing the XSLT renders to a ul with menu items. The block span is there for layout purposes (background image); that's why it has dimensions but no content.