Help | Site Map
Connecting Tech Pros Worldwide
 
 
LinkBack Thread Tools
  #1  
Old July 21st, 2005, 12:54 AM
Ken
Guest
 
Posts: n/a
Default basefont

What has replaced the basefont in HTML?

Is there a command to define a standard font for the entire page so an Id
does not have to be typed at each tag?

Thanks.

Ken


  #2  
Old July 21st, 2005, 12:54 AM
Andrew Thompson
Guest
 
Posts: n/a
Default Re: basefont

On Sat, 02 Oct 2004 06:59:24 GMT, Ken wrote:
[color=blue]
> Is there a command to define a standard font for the entire page[/color]

body {
font-family: sans-serif, serif;
}

It cascades down to other elements, that's part of what
the 'C' in CSS, means.

--
Andrew Thompson
http://www.PhySci.org/codes/ Web & IT Help
http://www.PhySci.org/ Open-source software suite
http://www.1point1C.org/ Science & Technology
http://www.lensescapes.com/ Images that escape the mundane
  #3  
Old July 21st, 2005, 12:54 AM
Jukka K. Korpela
Guest
 
Posts: n/a
Default Re: basefont

Andrew Thompson <SeeMySites@www.invalid> wrote:
[color=blue]
> body {
> font-family: sans-serif, serif;
> }[/color]

That would be an interesting rule. So you would specify the generic serif
font for those browsers that incorrectly fail to recognize the sans-serif
keyword?
[color=blue]
> It cascades down to other elements, that's part of what
> the 'C' in CSS, means.[/color]

No, it doesn't, and the C in "CSS" is almost always misunderstood
seriously.

A rule like
body { font-family: Arial, Helvetica, sans-serif; }
(to take a sensible example) affects directly only "loose" text (i.e.,
text inside <body> but not inside any inner element), which by the way is
not allowed in HTML 4.01 Strict. It _may_ indirectly affect other text
too, via inheritance, but only if _no_ other style sheet being applied
sets font-family for them. For example, it does not affect form fields on
most (or any?) browsers, since the fields have font-family set in the
browser's default style sheet.

The basefont tag, on the other hand, has no direct counterpart in CSS,
since it has no reasonable _definition_ in HTML and the implementations
vary. The question really is: what do you _want_, as an author?

--
Yucca, http://www.cs.tut.fi/~jkorpela/
  #4  
Old July 21st, 2005, 12:55 AM
Brian
Guest
 
Posts: n/a
Default Re: basefont

Ken wrote:[color=blue]
> What has replaced the basefont in HTML?[/color]

In HTML, nothing. Basefont -- indeed, any font -- has no place in HTML.

There is a replacement for fonts in web authoring; it's called cascading
stylesheets, or css.
[color=blue]
> Is there a command[/color]

Neither HTML nor CSS has commands. Neither is a programming language.
[color=blue]
> to define a standard font for the entire page[/color]

Set fonts in css. Here are some examples:

body { font-family: sans-serif;}

h1 {font-family: serif}

/* etc. */
[color=blue]
> so an Id does not have to be typed at each tag?[/color]

If you know about id attributes and fonts, then you already know about
css, don't you?

--
Brian (remove "invalid" to email me)
http://www.tsmchughs.com/
  #5  
Old July 21st, 2005, 12:57 AM
Ken
Guest
 
Posts: n/a
Default Re: basefont

"Brian" <usenet3@julietremblay.com.invalid> wrote in message
news:2nE7d.657079$Gx4.559788@bgtnsc04-news.ops.worldnet.att.net...[color=blue]
> Ken wrote:[color=green]
> > What has replaced the basefont in HTML?[/color]
>
> In HTML, nothing. Basefont -- indeed, any font -- has no place in HTML.
>
> There is a replacement for fonts in web authoring; it's called cascading
> stylesheets, or css.
>[color=green]
> > Is there a command[/color]
>
> Neither HTML nor CSS has commands. Neither is a programming language.
>[color=green]
> > to define a standard font for the entire page[/color]
>
> Set fonts in css. Here are some examples:
>
> body { font-family: sans-serif;}
>
> h1 {font-family: serif}
>
> /* etc. */
>[color=green]
> > so an Id does not have to be typed at each tag?[/color]
>
> If you know about id attributes and fonts, then you already know about
> css, don't you?
>
> --
> Brian (remove "invalid" to email me)
> http://www.tsmchughs.com/[/color]

[color=blue]
> If you know about id attributes and fonts, then you already know about
> css, don't you?[/color]
Brian,
I am new to css. I use ids in JavaScript to control background colors.

This is my first attempt at css.

Thanks for the suggestions.

Ken


  #6  
Old July 21st, 2005, 12:57 AM
Brian
Guest
 
Posts: n/a
Default Re: basefont

Ken wrote:[color=blue]
> "Brian" wrote in message...
>
>[color=green]
>> If you know about id attributes and fonts, then you already know
>> about css, don't you?[/color]
>
>
> I am new to css. I use ids in JavaScript to control background
> colors.[/color]


Ah, I hadn't considered the js angle of ids.

[color=blue]
> This is my first attempt at css.[/color]


The responses you got will hopefully give you some idea of what's
possible. You might want to consult the faq for this group, and check
out a css tutorial.

Good luck.

--
Brian (remove "invalid" to email me)
http://www.tsmchughs.com/
  #7  
Old July 21st, 2005, 12:57 AM
Neal
Guest
 
Posts: n/a
Default Re: basefont

On Thu, 07 Oct 2004 20:43:07 GMT, Brian
<usenet3@julietremblay.com.invalid> wrote:
[color=blue]
> and check
> out a css tutorial.[/color]

My two favorites:

1) http://www.w3schools.com/css/default.asp - not bad, a good starting
point. Lots of ads and cookies, pain in the ass, and a little cluttered
visually.

2) http://www.htmldog.com - ignore the XHTML claptrap, CSS works fine with
HTML 4.01 and you're better off without XHTML for now in my opinion - it's
otherwise a good exposition of CSS design, and is itself well designed.
 

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles