XHTML 1.0 Validator:没有属性,没有定义元素...... [英] XHTML 1.0 Validator: No attributes, elements not defined...

查看:113
本文介绍了XHTML 1.0 Validator:没有属性,没有定义元素......的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

-------

第47行,第8栏:没有属性id

< DIV id =" LeftNavigation"风格= QUOT;位置:绝对的;左:8像素;顶部:6px;

宽度:200p

-------

第47行,第31栏:没有属性 style"

< DIV id =" LeftNavigation"风格= QUOT;位置:绝对的;左:8像素;顶部:6px;

宽度:200p

-------

第47行,第127列:元素DIV undefined

.... 1250px;的z-index:1;溢出:可见;">

-------


这些只是我在验证我的<时遇到的272个错误中的三个br />
site, http://www.zeonline.net/ 。我正在使用有效的XHTML 1.0

Transistional DOCTYPE语句。如果需要,您可以查看

源代码的开头:


-------源代码: http://www.zeonline.net/-------

<?xml version =" 1.0" encoding =" utf-8"?>

<?xml-stylesheet href =" http://www.zeonline.net/zeonline.css"

type =" text / css"?>

<?xml-stylesheet href =" #newsFormatting" type =" text / css"?>

<!DOCTYPE html PUBLIC" - // W3C // DTD XHTML 1.0 Transitional // EN"

" ; http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

< html xmlns =" http://www.w3.org/ 1999 / XHTML" xml:lang =" en-us"

lang =" en-us" dir =" ltr">

-------(更多...)-------


有事告诉我认为验证器搞砸了。我的所有标签

都是小写的,但验证器将它们显示为大写。我使用

Dreamweaver MX 2002来创建我的网站。程序错误?验证者

问题?或者我错过了什么?

-

Colin
http://www.zeonline.net/

解决方案

11/8/04 10:上午21点,Colin Cogle写道:

有些东西告诉我验证器搞砸了。我的所有标签都是小写的,但验证器将它们显示为大写。我使用
Dreamweaver MX 2002来创建我的网站。程序错误?验证器
问题?或者我错过了什么?




你的标签*不是全部小写。


你似乎失踪了*除了以外的其他东西*很多。验证器

似乎已经生成了一个非常全面的问题清单,所以我不想在这里列出它们。


我建议您阅读如何在XHTML文档中包含Javascript以获得

start。然后也许你可以纠正你的href属性中的错误

(提示:" .. showflat.php?Cat =?mber = 624816& page = 1 .."应该是

" .. showflat.php?Cat =?mber = 624816& amp; page = 1 .."等等)


玩得开心! />

Phil


-

Philip Ronan
ph *********** @ virgin.net

(请删除z s如果通过电子邮件回复)


Ma **** ******@earthlink.net (Colin Cogle)写道:

-------
第47行,第8栏:那里没有属性id
< DIV id =" LeftNavigation"风格= QUOT;位置:绝对的;左:8像素;顶部:6px;
宽度:200p
-------
第47行,第31栏:没有属性风格
< DIV id =" ; LeftNavigation"风格= QUOT;位置:绝对的;左:8像素;顶部:6px;
宽度:200p


这两个是由于下一个:

-------
第47行,第127列:元素DIV。 undefined
... 1250px;的z-index:1;溢出:可见;">
-------


XHTML中没有元素DIV,因此它没有任何属性

因此前两个错误。但是有一个元素div。

请记住,与HTML不同,XHTML需要小写元素和

属性名称。

这些只是三个我在验证我的网站时得到的272个错误, http://www.zeonline。净/
Something告诉我验证器搞砸了。我的所有标签都是小写的,但验证器将它们显示为大写。




视图源将它们显示为大写,所以问题似乎与

你的代码不是验证器。


大多数upprcase标签都在评论之间

<! - Begin LeftNavigation SSI - >并且<! - 结束SSI - >

所以看起来你忘了把你的内容包含在内。

XHTML兼容。 (还有一个大写的< SCRIPT>< / SCRIPT>后面的评论是

。)


史蒂夫


-

我的理论给你起见,我的异端邪说你,

我从不回信,你不喜欢我的领带。 " - 医生


Steve Pugh< st *** @ pugh.net> < http://steve.pugh.net/>


Colin Cogle写道:


< snip> < blockquote class =post_quotes>
东西告诉我验证器搞砸了。我的所有标签都是小写的,但验证器将它们显示为大写。


不,他们不是。只需向下滚过< body>声明。


我使用Dreamweaver MX 2002来创建我的网站。程序错误?验证器
问题?或者我只是错过了什么?




可能错过了很多东西。这就是验证者告诉你的事情!


-------
Line 47, column 8: there is no attribute "id"
<DIV id="LeftNavigation" style="position:absolute; left:8px; top:6px;
width:200p
-------
Line 47, column 31: there is no attribute "style"
<DIV id="LeftNavigation" style="position:absolute; left:8px; top:6px;
width:200p
-------
Line 47, column 127: element "DIV" undefined
....1250px; z-index:1; overflow:visible;">
-------

These are just three of 272 errors that I got when I validated my
site, http://www.zeonline.net/. I''m using a valid XHTML 1.0
Transistional DOCTYPE statement. You can check the beginning of the
source code if you want:

-------Source Code: http://www.zeonline.net/-------
<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet href="http://www.zeonline.net/zeonline.css"
type="text/css"?>
<?xml-stylesheet href="#newsFormatting" type="text/css"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-us"
lang="en-us" dir="ltr">
-------(more...)-------

Something tells me that the validator is messed up. All of my tags
are lowercase, but the validator shows them as uppercase. I use
Dreamweaver MX 2002 to create my sites. Program bug? Validator
problem? Or did I just miss something?
--
Colin
http://www.zeonline.net/

解决方案

On 11/8/04 10:21 am, Colin Cogle wrote:

Something tells me that the validator is messed up. All of my tags
are lowercase, but the validator shows them as uppercase. I use
Dreamweaver MX 2002 to create my sites. Program bug? Validator
problem? Or did I just miss something?



Your tags are *not* all lowercase.

And you appear to be missing *lots* of other things besides. The validator
seems to have generated a pretty comprehensive list of your problems, so I
won''t bother listing them here.

I suggest you read up on how to include Javascript in XHTML documents for a
start. And then perhaps you could correct the errors in your href attributes
(hint: "..showflat.php?Cat=mber=624816&page=1.." should be
"..showflat.php?Cat=mber=624816&amp;page=1.." , etc.)

Have fun!

Phil

--
Philip Ronan
ph***********@virgin.net
(Please remove the "z"s if replying by email)


Ma**********@earthlink.net (Colin Cogle) wrote:

-------
Line 47, column 8: there is no attribute "id"
<DIV id="LeftNavigation" style="position:absolute; left:8px; top:6px;
width:200p
-------
Line 47, column 31: there is no attribute "style"
<DIV id="LeftNavigation" style="position:absolute; left:8px; top:6px;
width:200p
These two are due to the next one:
-------
Line 47, column 127: element "DIV" undefined
...1250px; z-index:1; overflow:visible;">
-------
There is no element DIV in XHTML, thus it can''t have any attributes
and hence the earlier two errors. There is an element div though.
Remember that XHTML, unlike HTML, requires lowercase element and
attribute names.
These are just three of 272 errors that I got when I validated my
site, http://www.zeonline.net/. Something tells me that the validator is messed up. All of my tags
are lowercase, but the validator shows them as uppercase.



A view source shows them as uppercase, so the problem seems to be with
your code not the validator.

Most of the upprcase tags are between the comments
<!-- Begin LeftNavigation SSI --> and <!-- End SSI -->
so it looks like your forgot to make the contents of your include
XHTML compatible. (There''s also one uppercase <SCRIPT></SCRIPT> after
the latter comment.)

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don''t like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>


Colin Cogle wrote:

<snip>


Something tells me that the validator is messed up. All of my tags
are lowercase, but the validator shows them as uppercase.
No they''re not. Just scroll down past the <body> statement.

I use Dreamweaver MX 2002 to create my sites. Program bug? Validator
problem? Or did I just miss something?



Probably missed a load of things. That''s what the validator is telling you!


这篇关于XHTML 1.0 Validator:没有属性,没有定义元素......的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆