Old 27-05-2004, 11:24   #1 (permalink)
sleepingfish
css is for divs
 
sleepingfish's Avatar
 
Join Date: Feb 2003
Location: Norwich
Posts: 4,469
Tags

Considering making an interface for inserting text with basic formatting options (similar to the Post New Thread page here on DT) so that the user could apply <b> and <i> tags to text.

What I'm wondering is how this would work behind-the-scenes - when the code is actually created would it have <b> and <i> tags in it that have been restyled with css, or would it be better to have <span> tags with classes applied to the text?

I guess what I'm getting at is; is it ok to use <b> and <i> tags in XHTML? And wile I'm a-wondering, what about the <strong> tag?

Chairs
  Reply With Quote
Old 27-05-2004, 12:02   #2 (permalink)
smallbeer
I Ain't Losing Any Sleep™
 
Join Date: Apr 2003
Posts: 5,200
no point using a span when there's already bold and italic tags available. I always use <strong> and <em> these days. To be honest I can't remember whether <b> and <i> have been depreciated or have just gone out of favour with the pedantic...sorry...semantic crowd.

Depending on the users, you might want to only allow them to enter pseudo code like forum's use - [b], [i] for example and then use some sort of php string replace to change them into (x)html. you don't really want your users to be able to enter any (x)html they like do you. they might fancy some blinking text.
__________________
That's fuckin' ingenious, if I understand it correctly. It's a Swiss fuckin' watch.
  Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search


Contact Us - Web Design Forums - Archive - Top
Search Engine Optimization by vBSEO 3.0.0 RC8