PDA

View Full Version : basic HTML formatting? (marquee, underline, center, etc)


momentsofyou
2006-01-03, 18:41
:confused: Hmmmmmm.

Can you people give me the basic codes for making marquee's and um, underline and....... how do I format font as in ways of....... centering it or tabbing it in.

chucker
2006-01-03, 18:46
Marquee?

:no:

rollercoaster375
2006-01-03, 19:56
Centering is not part of HTML. Nor are marquees, or underlining.

All of that is CSS (With the exception of marquees, which aren't anything).

Go read the spec (http://www.w3.org/TR/xhtml11/) before you ask for help.

pmazer
2006-01-03, 20:15
rollercoaster375: Not completely true.. they're not part of XHTML, but they are, in fact, part of HTML 4.0.

I'll try to answer your question as best as possible, but you're better off looking at http://www.w3schools.com/tags/default.asp if you have any more questions. If you're looking at making a website, though, I would suggest learning XHTML and CSS. Right now, I'm assuming that you want to do something like spice up a MySpace page or something.

Marquee (very browser specific): <marquee>Text here</marquee>

Center: <center>Text here</center>

There's no real way to tab in HTML. You can do it much better with XHTML and CSS: <p style="text-indent: 5px">Text here</p>

chucker
2006-01-03, 20:23
rollercoaster375: Not completely true.. they're not part of XHTML, but they are, in fact, part of HTML 4.0.

Deprecated and tolerated, but hardly accepted. Presentational HTML is bad.

PKIDelirium
2006-01-03, 20:30
XHTML/CSS is just too damn complex!

HTML 4 > *

pmazer
2006-01-03, 20:30
Deprecated and tolerated, but hardly accepted. Presentational HTML is bad.

I don't disagree with that, but more most people's uses, such as adding a little bit to a personal blog, presentational HTML is all they need.

chucker
2006-01-03, 20:41
I don't understand that notion. Purely semantic HTML is much easier to write. A separation of semantics (HTML), presentation (CSS) and behaviour (ECMAScript) helps everyone and involves little to no additional effort.

Brad
2006-01-03, 20:52
From our posting guidelines, that link at the top of every page here:
Be descriptive with the title of new threads. Do not start a thread with an ambiguous title like "Guess what..." or "Help!" and then use the text portion of the post to explain. Do not give threads misleading titles in an attempt to gain more views. Give your post a headline. This courtesy is especially appreciated in the more highly trafficked forums.

Renaming...

Brad
2006-01-03, 21:03
That said,

The marquee tag isn't even part of the HTML4 spec at all.
The center tag is deprecated in HTML4.
The u tag (for underlining) is deprecated in HTML4.
None of them are supported in XHTML.

Why? Presentation should be separate from content wherever possible. Separation makes the code more modular, updatable, and easier to read.

CSS+XHTML is no more "damn complex" (re: PKIDelirium) than the old HTML pages interleaved with the old, deprecated tags. If anything, it makes the raw code less complex because the styling isn't hard-coded into every single element in every document.

drewprops
2006-01-03, 21:12
when you've seen the light you've seen the light!
but props to pmazer for coming across with the code for our poor misguided HTML coder!

rollercoaster375
2006-01-03, 21:15
rollercoaster375: Not completely true.. they're not part of XHTML, but they are, in fact, part of HTML 4.0.
HTML 4.0 is depreciated. It's not meant to be used. Secondly, its replacement, HTML 4.01, has depreciated <center> (HTML 4.0 also had depreciated <center>... My wording makes it sound otherwise).

I'll try to answer your question as best as possible, but you're better off looking at http://www.w3schools.com/tags/default.asp if you have any more questions. If you're looking at making a website, though, I would suggest learning XHTML and CSS. Right now, I'm assuming that you want to do something like spice up a MySpace page or something.

Marquee (very browser specific): <marquee>Text here</marquee>

Center: <center>Text here</center>

There's no real way to tab in HTML. You can do it much better with XHTML and CSS: <p style="text-indent: 5px">Text here</p>
When you say "very browser specific" you make it sound like it's part of HTML that isn't supported. In thinking this, you're wrong. <marquee> is completely, and totally, absent from ALL W3 specs. Also, use of the style attribute should be avoided.

PKIDelerium: Uh... No. HTML is messy, poorly designed, and an overall bad spec. There's this concept within the web development community that HTML is a way to present content. That's not the case. (X)HTML is a means to define data, a means that has been optimized for use with modern Web Browsers.

Brad: XHTML 1.0 Transitional (If you want to call that XHTML) has <center>/style="align: *;". However, use of it is depreciated.

Brad
2006-01-03, 21:18
Brad: XHTML 1.0 Transitional (If you want to call that XHTML) has <center>/style="align: *;". However, use of it is depreciated.
Meh! Transitional is for babies! :p

(Yes, I'm fully aware that AN uses Transitional, but vB's templates are total crap, necessitating that.)

rollercoaster375
2006-01-03, 21:24
Meh! Transitional is for babies! :p

(Yes, I'm fully aware that AN uses Transitional, but vB's templates are total crap, necessitating that.)
I completely agree. Whenever possible, I use 1.1.

(I have the same issues with BB templates - IPB.)

pmazer
2006-01-03, 21:58
Haha, guys, I was just trying to answer his question. I NEVER use HTML 4.0 in my code, but if you were wanting to, say, center something in a personal blog, would you prefer to use <center> or <p style="text-align: center">? Requiring Livejournal users to learn XHTML and CSS is a little overkill.

When you say "very browser specific" you make it sound like it's part of HTML that isn't supported. In thinking this, you're wrong. <marquee> is completely, and totally, absent from ALL W3 specs. Also, use of the style attribute should be avoided.

No, by saying "very browser specific" I meant that it isn't in the W3 specs, so many browsers may not have it implemented.

By the way, momentsofyou, the XHTML/CSS way of centering text is:
<p style="text-align: center">Text here</p>

chucker
2006-01-03, 22:11
if you were wanting to, say, center something in a personal blog, would you prefer to use <center> or <p style="text-align: center">?

Neither. They're both bad markup.

Requiring Livejournal users to learn XHTML and CSS is a little overkill.

So use a LiveJournal template that already comes with a decent class that's centered.

By the way, momentsofyou, the XHTML/CSS way of centering text is:
<p style="text-align: center">Text here</p>

Arguably.

rollercoaster375
2006-01-03, 22:24
Haha, guys, I was just trying to answer his question. I NEVER use HTML 4.0 in my code, but if you were wanting to, say, center something in a personal blog, would you prefer to use <center> or <p style="text-align: center">? Requiring Livejournal users to learn XHTML and CSS is a little overkill.



No, by saying "very browser specific" I meant that it isn't in the W3 specs, so many browsers may not have it implemented.

By the way, momentsofyou, the XHTML/CSS way of centering text is:
<p style="text-align: center">Text here</p>
Livejournal doesn't expose end users to the XML for their RSS feeds... Why should they have the power to edit other markup?

I understood that you know that, but your wording made it sound acceptable. <marquee> should not be used under any circumstances, period.

That's not accurate, mainly because it's from the wrong perspective. The goal of your page's markup should not be to make sure that things can be displayed properly. Rather, the markup expressed on a page should identifiy what data a page has to offer, and tag it as such.

Secondly, the style attribute has been depreciated. better to use:
<!--XHTML Declaration... Blah blah blah, that's not important for my point-->
<head>
<!--...-->
<style type="text/css">
//Replace the class name with a more appropriate one.
.entry {
text-align: center;
}
</style>
</head>
<body>
<!--...-->
<p class="entry">
Content here...
</p>
</body>
</html>

pmazer
2006-01-03, 22:26
chucker: Try explaining to your average blog user that they need two files and learn two technologies in order to do something as simple as center text. They'll respond, "But all it takes is the push of a button in Word!"

To tell people that they shouldn't be able to format their web content without spending hours learning web technologies will alienate non-programmers who have a lot to add to the internet.

chucker
2006-01-03, 22:33
chucker: Try explaining to your average blog user that they need two files and learn two technologies in order to do something as simple as center text.

They don't. The CMS handles that.

They'll respond, "But all it takes is the push of a button in Word!"

That's their problem, not mine. ;)

To tell people that they shouldn't be able to format their web content without spending hours learning web technologies will alienate non-programmers who have a lot to add to the internet.

See above. There's no need for an average person to edit markup themselves.

drewprops
2006-01-03, 22:42
Well we know that Word is heading toward some form of extensible foundation and that users' experiences will be predominantly seamless, so there's an example of average users who won't touch markup, in a very visible product. There's not a handy CSS/XHTML WYSIWYG editor out there yet... is there?

But the XHTML/CSS example posted above is what derailed me from trying it for more than a year. CSS Zen Garden (http://www.csszengarden.com/) and Jon Hicks are the things that turned me and kajillions of other designers around.

But if somebody is bloody asking for MARQUEE then stand aside, hand them the dynamite and let them run out into the trenches!!

pmazer
2006-01-04, 00:46
There's not a handy CSS/XHTML WYSIWYG editor out there yet... is there?

Adobe GoLive tries to be, but as of yet no one has created a very good WYSIWYG editor, where you don't have to even think about the code, no matter the language.

staph
2006-01-04, 06:01
But if somebody is bloody asking for MARQUEE then stand aside, hand them the dynamite and let them run out into the trenches!!

Well, you could help them with all their web design needs by pointing them to this page (http://www.animationlibrary.com/a-l/?n=image.php3&image_id=1207) and this page (http://www.animationlibrary.com/a-l/?n=image.php3&image_id=929)

rollercoaster375
2006-01-04, 10:12
There's no such thing as a "good" WYSIWYG editor. GoLive/Dreamweaver/Frontpage can't tell what the purpose of the data you're typing is. They only concentrate on how it can be presented. Not a good plan.