| View previous topic :: View next topic |
| Author |
Message |
bsmith Graphics Guru


Joined: 19 Jun 2007 Posts: 675 Location: Arkansas, USA
|
Posted: Mon Feb 04, 2008 3:49 pm Post subject: The proper way to bold text |
|
|
There has been much discussion about bolding text and the best way to do it.
Here is my opinion: Use CSS
(CSS = cascading style sheets)
Here are your options:
1. Old way:
| Code: |
| <div><b>text to bold</b></div> |
2. Better way:
| Code: |
| <div><strong>text to bold</strong></div> |
3. CSS way:
| Code: |
| <div class="heavy">text to bold</div> |
In your style sheet add:
| Code: |
| .heavy {font-weight:bold} |
The examples above have <div> tags around them only to be able to compare the CSS way with the others.
You can actually combine the strong tag and css to create the best way of all. It would look like #2 above but your stylesheet would include this:
| Code: |
| strong {font-weight:bold} |
This seems pointless because the strong tag actually bolds the text already... however with this, you can now add color, font-size, etc... and all strong tags will automaticly do what you want them to do, no matter how the browser normally handles the strong attribute.
So what is wrong with the others?
Good question. The "powers that be" in the web design world have decided that we (web designers) need to take formatting and attributes out of the core code and format those things elsewhere.
"Bold" as a word, is a visual effect. Thus needs to be removed from use.
"Strong" is an action you do when talking. You can invoke a stronger tone... you cannot technically invoke a bolder tone.
Yes, this is very picky. But the line has to drawn somewhere. And with advancements in standards comes changes like these.
But here is the problem with calling "strong" alone... Not all browsers have to treat "strong" as they did bold. Many browsers may start adding a slightly larger font-size or other effect to make the affected phrase stand out.
When you add css to the mix you get to still have final control of the outcome. _________________ FYI: If you are planning on spaming this form don't bother.
Your posts will be removed and your username banned... |
|
| Back to top |
|
 |
TigerBot Tiger Member

Joined: 19 Jun 2007
|
Posted: Mon Feb 04, 2008 3:49 pm Post subject: Sponsored Advertisement |
|
|
_________________ TigerBot
|
|
| Back to top |
|
 |
maryjones Tiger Member

Joined: 04 Dec 2007 Posts: 57
|
Posted: Tue Mar 04, 2008 3:36 pm Post subject: |
|
|
What is a style sheet?  _________________ mary jones
business directory |
|
| Back to top |
|
 |
bsmith Graphics Guru


Joined: 19 Jun 2007 Posts: 675 Location: Arkansas, USA
|
|
| Back to top |
|
 |
maryjones Tiger Member

Joined: 04 Dec 2007 Posts: 57
|
Posted: Wed Mar 05, 2008 10:05 pm Post subject: |
|
|
Thank you Brian, I have added those to my favorites!!  _________________ mary jones
business directory |
|
| Back to top |
|
 |
|