473,408 Members | 1,735 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

basefont

Ken
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
Jul 20 '05 #1
6 3949
On Sat, 02 Oct 2004 06:59:24 GMT, Ken wrote:
Is there a command to define a standard font for the entire page


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
Jul 20 '05 #2
Andrew Thompson <Se********@www.invalid> wrote:
body {
font-family: sans-serif, serif;
}
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?
It cascades down to other elements, that's part of what
the 'C' in CSS, means.


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/
Jul 20 '05 #3
Ken wrote:
What has replaced the basefont in HTML?
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.
Is there a command
Neither HTML nor CSS has commands. Neither is a programming language.
to define a standard font for the entire page
Set fonts in css. Here are some examples:

body { font-family: sans-serif;}

h1 {font-family: serif}

/* etc. */
so an Id does not have to be typed at each tag?


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/
Jul 20 '05 #4
Ken
"Brian" <us*****@julietremblay.com.invalid> wrote in message
news:2n*********************@bgtnsc04-news.ops.worldnet.att.net...
Ken wrote:
What has replaced the basefont in HTML?
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.
Is there a command


Neither HTML nor CSS has commands. Neither is a programming language.
to define a standard font for the entire page


Set fonts in css. Here are some examples:

body { font-family: sans-serif;}

h1 {font-family: serif}

/* etc. */
so an Id does not have to be typed at each tag?


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/


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

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
Jul 20 '05 #5
Ken wrote:
"Brian" wrote in message...

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

I am new to css. I use ids in JavaScript to control background
colors.

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

This is my first attempt at css.

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/
Jul 20 '05 #6
On Thu, 07 Oct 2004 20:43:07 GMT, Brian
<us*****@julietremblay.com.invalid> wrote:
and check
out a css tutorial.


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.
Jul 20 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: dave | last post by:
Hello, I'm trying to get php authentication working on a test apache2 server prior to implementing it site wide. I'm authenticating against the system password file, and i'm getting a parce error...
2
by: Alex Shi | last post by:
In php, is there a way obtain the width of a charactor of a certain font? Alex -- ================================================== Cell Phone Batteries at 30-50%+ off retail prices!...
0
by: Nick Truscott | last post by:
Is this possible? I have a form which asks the user to input the result of a soccer match. I want to then use a choice of three sets of queries (Home Win, Away Win, Draw) to update two...
0
by: Navin | last post by:
hi, i am using the following code to generate a xls file using the content type now when the user opnes the file at his pc it takes long time to open..if the no of records in file is large...
4
by: Richard Hollenbeck | last post by:
I'm trying to write some code that will convert any of the most popular standard date formats twice in to something like "dd Mmm yyyy" (i.e. 08 Jan 1908) and compare the first with the second and...
7
by: NeverLift | last post by:
I posted a very long message regarding my experiences with JavaScript, one reply was posted asking I post an example of the problem -- and both are gone! Is there a moderator that removes such...
2
by: futurepy | last post by:
By default color of the list marker, disc or circle or square, is black. Is there a way to change the color, for example, to red or blue? Thanks.
9
by: Dr John Stockton | last post by:
Assuming default set-ups and considering all reasonable browsers, whatever that may mean, what should an author expect that his readers in general will see (with visual browsers) for a page with...
13
by: Jukka K. Korpela | last post by:
Since there is no authoritative specification on how to map presentational HTML elements and attributes to CSS, and even no informal description (as far as I can see), I finally composed one:...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.