473,748 Members | 8,779 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Problem with new HTML / CSS sheet

I'm moving an old page to a new host, and trying to modernize it at the
same time. There are two little problems that are driving me nuts.

1. Validation of www.marzolian.com/index.html says:

Line 33, column 5: element "NOTE" undefined
<note>Last revised: May 29, 2005</note>
"You have used the element named above in your document, but the
document type you are using does not define an element of that name."

The error is with "note" What did I do wrong?

2. The last line is supposed to have the "note" style, defined in the
style sheet (marzolian.css) . What's odd, that definition includes a
font size. If I change this size in the style sheet, it is reflected
onscreen; in other words, despite the error, Firefox at least is reading
the font size. However, the center part of this definition is not
getting applied.

I suspect that the two problems have the same fix. What is it?

3. This isn't a problem, but a preference: Rather than fix the font
size for "note" I would rather just make it <small>. How can I do that
in a CSS file?

Thanks.
--
Steven M

HOUSTON - First in Oil, First in Space,
Last in the National League Central Division
Jul 24 '05 #1
7 1778
Els
Steven (remove wax and invalid for reply) wrote:
1. Validation of www.marzolian.com/index.html says:

Line 33, column 5: element "NOTE" undefined
<note>Last revised: May 29, 2005</note>
"You have used the element named above in your document, but the
document type you are using does not define an element of that name."

The error is with "note" What did I do wrong?
You used it. There is no element 'note' in HTML.
in other words, despite the error, Firefox at least is reading
the font size. However, the center part of this definition is not
getting applied.

I suspect that the two problems have the same fix. What is it?
"note" isn't a valid HTML element, but Firefox applies styles to
anything, valid or not.
Maybe Firefox takes the unknown element as inline by default, which
means margins are not applied.
3. This isn't a problem, but a preference: Rather than fix the font
size for "note" I would rather just make it <small>. How can I do that
in a CSS file?


Use font-size:small; ?

--
Els http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -
Jul 24 '05 #2
Gazing into my crystal ball I observed "Steven (remove wax and invalid for
reply)" <un****@hal-pc.orgwax.inval id> writing in news:42995fd9$0 $64582
$a*******@news. hal-pc.org:
I'm moving an old page to a new host, and trying to modernize it at the
same time. There are two little problems that are driving me nuts.

1. Validation of www.marzolian.com/index.html says:

Line 33, column 5: element "NOTE" undefined
<note>Last revised: May 29, 2005</note>
"You have used the element named above in your document, but the
document type you are using does not define an element of that name."

The error is with "note" What did I do wrong?
There is no element named "note". Period. You cannot just make up
elements to your liking.

2. The last line is supposed to have the "note" style, defined in the
style sheet (marzolian.css) . What's odd, that definition includes a
font size. If I change this size in the style sheet, it is reflected
onscreen; in other words, despite the error, Firefox at least is reading
the font size. However, the center part of this definition is not
getting applied.

I suspect that the two problems have the same fix. What is it?
You are applying centering to an element that does not exist. Block
elements can have their contents centered. Inline elements, since they are
not block, cannot. The browser does not know whether the "note" element is
block or inline, so it does not center it at all.

3. This isn't a problem, but a preference: Rather than fix the font
size for "note" I would rather just make it <small>. How can I do that
in a CSS file?
Use a percentage, like 80%, which will make the font size 80% of the users
chosen font size. The font size you are using now is way too small.

Thanks.


What you really want is:
<div class="note">La st revised May 29, 2005</div>

And in your CSS:
..note {font-size:80%; text-align:center;}
--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
Jul 24 '05 #3
Els
Steven (remove wax and invalid for reply) wrote:
1. Validation of www.marzolian.com/index.html says:

Line 33, column 5: element "NOTE" undefined
<note>Last revised: May 29, 2005</note>
"You have used the element named above in your document, but the
document type you are using does not define an element of that name."

The error is with "note" What did I do wrong?
You used it. There is no element 'note' in HTML.
in other words, despite the error, Firefox at least is reading
the font size. However, the center part of this definition is not
getting applied.

I suspect that the two problems have the same fix. What is it?
"note" isn't a valid HTML element, but Firefox applies styles to
anything, valid or not.
Maybe Firefox takes the unknown element as inline by default, which
means margins are not applied.
3. This isn't a problem, but a preference: Rather than fix the font
size for "note" I would rather just make it <small>. How can I do that
in a CSS file?


Use font-size:small; ?

--
Els http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -
Jul 24 '05 #4
Gazing into my crystal ball I observed "Steven (remove wax and invalid for
reply)" <un****@hal-pc.orgwax.inval id> writing in news:42995fd9$0 $64582
$a*******@news. hal-pc.org:
I'm moving an old page to a new host, and trying to modernize it at the
same time. There are two little problems that are driving me nuts.

1. Validation of www.marzolian.com/index.html says:

Line 33, column 5: element "NOTE" undefined
<note>Last revised: May 29, 2005</note>
"You have used the element named above in your document, but the
document type you are using does not define an element of that name."

The error is with "note" What did I do wrong?
There is no element named "note". Period. You cannot just make up
elements to your liking.

2. The last line is supposed to have the "note" style, defined in the
style sheet (marzolian.css) . What's odd, that definition includes a
font size. If I change this size in the style sheet, it is reflected
onscreen; in other words, despite the error, Firefox at least is reading
the font size. However, the center part of this definition is not
getting applied.

I suspect that the two problems have the same fix. What is it?
You are applying centering to an element that does not exist. Block
elements can have their contents centered. Inline elements, since they are
not block, cannot. The browser does not know whether the "note" element is
block or inline, so it does not center it at all.

3. This isn't a problem, but a preference: Rather than fix the font
size for "note" I would rather just make it <small>. How can I do that
in a CSS file?
Use a percentage, like 80%, which will make the font size 80% of the users
chosen font size. The font size you are using now is way too small.

Thanks.


What you really want is:
<div class="note">La st revised May 29, 2005</div>

And in your CSS:
..note {font-size:80%; text-align:center;}
--
Adrienne Boswell
http://www.cavalcade-of-coding.info
Please respond to the group so others can share
Jul 24 '05 #5
Adrienne wrote:
Gazing into my crystal ball I observed "Steven (remove wax and invalid for
reply)" <un****@hal-pc.orgwax.inval id> writing in news:42995fd9$0 $64582
$a*******@news. hal-pc.org:

I'm moving an old page to a new host, and trying to modernize it at the
same time. There are two little problems that are driving me nuts.

1. Validation of www.marzolian.com/index.html says:

Line 33, column 5: element "NOTE" undefined
<note>Last revised: May 29, 2005</note>
"You have used the element named above in your document, but the
document type you are using does not define an element of that name."

The error is with "note" What did I do wrong?

There is no element named "note". Period. You cannot just make up
elements to your liking.

2. The last line is supposed to have the "note" style, defined in the
style sheet (marzolian.css) . What's odd, that definition includes a
font size. If I change this size in the style sheet, it is reflected
onscreen; in other words, despite the error, Firefox at least is reading
the font size. However, the center part of this definition is not
getting applied.

I suspect that the two problems have the same fix. What is it?

You are applying centering to an element that does not exist. Block
elements can have their contents centered. Inline elements, since they are
not block, cannot. The browser does not know whether the "note" element is
block or inline, so it does not center it at all.

3. This isn't a problem, but a preference: Rather than fix the font
size for "note" I would rather just make it <small>. How can I do that
in a CSS file?

Use a percentage, like 80%, which will make the font size 80% of the users
chosen font size. The font size you are using now is way too small.

Thanks.

What you really want is:
<div class="note">La st revised May 29, 2005</div>

And in your CSS:
.note {font-size:80%; text-align:center;}

Thanks very much, all fixed now.

What threw me, I think, is that "style" means something different in
programs such as Microsoft Word. There I can create entirely new styles
such as "Note" or "myHeading1 " and apply them throughout a document, or
export them to new documents. A Word style can be based on, or inherit,
attributes from existing styles. The system has advantages that are
similar to those of using CSS.

The problem was, the online reference material on CSS and styles that I
have been reading doesn't make it clear that you can't make up your own
styles that way.

Thanks again. I have been learning a lot from this group for the past
few weeks.

--
Steven

HOUSTON - First in Oil, First in Space,
Last in the National League Central Division
Jul 24 '05 #6
Adrienne wrote:
Gazing into my crystal ball I observed "Steven (remove wax and invalid for
reply)" <un****@hal-pc.orgwax.inval id> writing in news:42995fd9$0 $64582
$a*******@news. hal-pc.org:

I'm moving an old page to a new host, and trying to modernize it at the
same time. There are two little problems that are driving me nuts.

1. Validation of www.marzolian.com/index.html says:

Line 33, column 5: element "NOTE" undefined
<note>Last revised: May 29, 2005</note>
"You have used the element named above in your document, but the
document type you are using does not define an element of that name."

The error is with "note" What did I do wrong?

There is no element named "note". Period. You cannot just make up
elements to your liking.

2. The last line is supposed to have the "note" style, defined in the
style sheet (marzolian.css) . What's odd, that definition includes a
font size. If I change this size in the style sheet, it is reflected
onscreen; in other words, despite the error, Firefox at least is reading
the font size. However, the center part of this definition is not
getting applied.

I suspect that the two problems have the same fix. What is it?

You are applying centering to an element that does not exist. Block
elements can have their contents centered. Inline elements, since they are
not block, cannot. The browser does not know whether the "note" element is
block or inline, so it does not center it at all.

3. This isn't a problem, but a preference: Rather than fix the font
size for "note" I would rather just make it <small>. How can I do that
in a CSS file?

Use a percentage, like 80%, which will make the font size 80% of the users
chosen font size. The font size you are using now is way too small.

Thanks.

What you really want is:
<div class="note">La st revised May 29, 2005</div>

And in your CSS:
.note {font-size:80%; text-align:center;}

Thanks very much, all fixed now.

What threw me, I think, is that "style" means something different in
programs such as Microsoft Word. There I can create entirely new styles
such as "Note" or "myHeading1 " and apply them throughout a document, or
export them to new documents. A Word style can be based on, or inherit,
attributes from existing styles. The system has advantages that are
similar to those of using CSS.

The problem was, the online reference material on CSS and styles that I
have been reading doesn't make it clear that you can't make up your own
styles that way.

Thanks again. I have been learning a lot from this group for the past
few weeks.

--
Steven

HOUSTON - First in Oil, First in Space,
Last in the National League Central Division
Jul 24 '05 #7
Steven (remove wax and invalid for reply) wrote:
What threw me, I think, is that "style" means something different in
programs such as Microsoft Word.
Indeed. MS Word "styles" and CSS "styles" are conceptually related, but
defined independently of each other. The good news is that if you know
MS Word styles and use them, you are much better prepared to learning
good Web authoring habits than people who do word processing in a naive
way, just setting fonts and margins etc. for each piece of text
separately (corresponding, somewhat, to bad old <font> tags in HTML).
There I can create entirely new styles
such as "Note" or "myHeading1 " and apply them throughout a document, or
export them to new documents.
Yes. If you use a Save as HTML (or Save as Web page or whatever they
call it this week) in MS Word, you'll see (if you can make your way
through the crap) that MS Word generates a <div class="Note">.. .</div>
element from a paragraph that you have defined to take the Note style
you have defined and inserts some messy CSS that corresponds to your
settings for that MS Word style.
A Word style can be based on, or inherit,
attributes from existing styles.
The CSS styles are different. There is no inheritance in _that_ sense.
But you can assign several styles to an element, e.g.
<div class="note warning">...</div>
and that way combine the settings you have made for the styles.
The problem was, the online reference material on CSS and styles that I
have been reading doesn't make it clear that you can't make up your own
styles that way.


The way that corresponds to making up new MS Word styles is to select a
name for a class (the choice is up to you, but it pays off to use names
that reflect meaning rather than appearance, e.g. "warning" rather than
"red"), start using it in markup (in class="..." attributes), and write
CSS rules for the class. You can start using a class and think about the
appearance later, and you can even write different stylistic definitions
for a class (e.g., one set for screen media, another for print media).

The class="..." attribute is often attached to a <div> element (for a
block) or a <span> element (for inline content), and often the element
is introduced into the markup just in order to have something to attach
the attribute to. But you can use them for (basically) any element, such
as <p> or <ul> or <strong>.

Well, in a sense this means that you _can_ base a style on an existing
style. Namely in the sense that elements like <p> or <ul> or <strong>
have default stylistic features (logically, there are browser default
style sheets that assign properties to them). Thus, if you use <p
class="note">, then all the default rendering features of <p> elements
apply, unless you override them in your style sheet.

P.S. The markup <div class="note">La st revised May 29, 2005</div> that
was suggested is certainly correct. Some of us might say that
<div class="note"><s mall>Last revised May 29, 2005</small></div>
can be justifiable, too. Then you need to watch out so that you won't
cause two cumulative size reductions to be applied. You could use
..note {text-align:center;}
..note small {font-size:80%;}

Yucca
Jul 24 '05 #8

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

Similar topics

9
2505
by: Theodore A. Jencks | last post by:
Hi All, I have a problem that is two fold. First a little about the enviroment I'm using; I am running Microsoft Windows XP with all security patches applied. I use Mozilla 1.6 for all testing before I test on IE 6 w/ all updates. I am editing my style sheet with StyleMaster 3.5.2 and am hand coding. I use Dreamweaver MX 2004 and am also hand coding. I have a problem that is easily solved by using tables however I don't want to use...
5
2699
by: Janet | last post by:
The following html code appears in an ASP page. The hyperlink is set to white (see the page link color), but when the page renders in IE 6.0, it initially appears in maroon with a white border around it. When the user clicks anywhere on the page, it turns white. Does anybody know how I can make it appear white when the page first renders? Response.Write("<html><body bgcolor=""#000000"" link=""#FFFFFF"" vlink=""#FFFFFF"">")
1
2447
by: Hank Flowers | last post by:
In trying to load a style sheet via JavaScript I ran into a problem...the style sheet doesn't load. This simple task has turned into a vexing problem. Here is the script and html: <html> <head> <title>load a style sheet</title> <script type="text/javascript" language="JavaScript"> var mystyle="css/mystyle.css"; document.write=("<link rel='stylesheet' href='" + mystyle + "'
2
2838
by: Saran | last post by:
Hi all, We have a property sheet that is created in one dll, and on that property sheet, there is a property page that is created in another dll. So, the property sheet and the property page come from different module states. Now, in CPropertySheet::OnKickIdle(), it calls GetActivePage(), which then sends a message in order to get the handle to the active page. Given the handle, it then calls CWnd::FromHandle() to get the pointer to the...
15
1766
by: DoomedLung | last post by:
Hey everyone, I'm writing a script that opens the current page into a new window with a different style sheet for printing, don't ask me why it needs to open into a new window, it's a request from powers that be! Anyway when I reload the page in IE it's fine but in FF it seems to render the html without a style sheet!!?? I think it may be to do a caching problem in FF with new windows but I'm not sure. Heres the code I've written:
0
1156
by: JohnK82 | last post by:
Hi guys I have a webcontrol that displays an article in multiple parts. You can jump back and forward between the parts (I call them sheets) by clicking on a label. Each sheet has a label. The control is used like this: <john:MyControl runat="server"> <john:Sheet label="Intro"> This is the first part of the text... </john:Sheet>
2
2464
by: davidson1 | last post by:
Hai friends..for menu to use in my website..i found in one website....pl look below website.... http://www.dynamicdrive.com/dynamicindex1/omnislide/index.htm i downloaded 2 files.... menuitems.js mmenu.js
35
2367
by: Guy Macon | last post by:
I have been running tests on various doctypes and found something interesting. I set up a test page using this doctype... <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0 Strict Level 1//EN"> ....and put this in the head: <link rel="stylesheet" type="text/css" href="http://www.example.com/test.css">
6
2894
by: azegurb | last post by:
Hello, I have one question again i created one table again and in this table i added some another options for ex at the previous table there were only one problem sum of the dynamically added rows in this beside sum i need to sum of the tax for ex: in column1 i added 300 and into 2-nd column i Chose 10% i would like when i chose from drop down box 10% Let in the 2-nd column appear 10% of the value which i addee first column for ex...
0
8989
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8828
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9537
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9319
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8241
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6795
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 presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6073
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4869
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
2780
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.