I mean, this accomplishes getting the text on the same line with different weights, but it’s not semantic. If this is a header, use one tag and use a span with a class that styles the text within that span or use strong. If it’s just regular text, use a paragraph tag and do the same. In the examples given, you’re splitting up one piece of text amongst two separate tags to achieve a side effect of them being in separate tags, and that is a bad idea for a number of reasons.
Edit: Of course, if what you REALLY want is an h1 tag and an h2 tag on the same line, this is the way to go. But I’m just not thinking that’s the actual need here from the examples provided.
This reply has been reported for inappropriate content.
@criewel, you do realize this discussion ended six years ago, yes?
But in any case, GSutherland is right: this was a styling problem, not a semantic one. There are not two headings; only one heading with differently-styled words. They belong in the same heading element.
In fact, I’ll go as far as saying that <b> tags would be correct here (not <strong>), because there is absolutely no semantic purpose: the first few words aren’t more important. It’s purely stylistic, and <b> does just that while imposing no semantic meaning.