需要帮助在Opera中查找CSS错误 [英] Need help finding CSS bug in Opera

查看:63
本文介绍了需要帮助在Opera中查找CSS错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经整理了一个两层CSS标签的原型,它在IE6,IE7和FF2中运行得非常好。

。它在Opera 9.27中运行得非常好_except_

下层标签的位置搞砸了。 XHTML和CSS

都可以验证,没有任何错误或警告。任何人都可以帮我搞清楚

是错的吗?


我会特别感兴趣的是你用来弄清楚在哪里的技术
问题是
。当我试图弄明白为什么

某些东西没有正确显示时,我仍然很挣扎。


你可以在 http://westown.qqqq.ca/2000a.html


-

顺便说一下,如果有人感兴趣,我还有另外两个

分层标签的原型 - 这一个没用GIF -
http://westown.qqqq.ca/2000.html 。我会对批评或

建议两种原型的改进感兴趣。我会特别感兴趣

来了解残障人士是否可以轻松访问这些页面。我真的很好

不知道怎么测试。


-

犀牛


I''ve put together a prototype of two-tiered CSS tabs that works really well
in IE6, IE7, and FF2. It also works very well in Opera 9.27 _except_ that
the placement of the lower tier of tabs is messed up. Both the XHTML and CSS
validate without any errors or warnings. Can anyone help me figure out what
is wrong?

I''d be especially interested in the technique you used to figure out where
the problem was. I still struggle a lot when I try to figure out why
something is not displaying correctly.

You can see the prototype at http://westown.qqqq.ca/2000a.html.

--
By the way, in case anyone''s interested, I have another prototype of two
tiered tabs - this one doesn''t use GIFs - at
http://westown.qqqq.ca/2000.html. I''d be interested in critiques or
suggestions for improvement on both prototypes. I''d be especially interested
to know if these pages are easily accessible to the handicapped. I''m really
not sure how to test for that.

--
Rhino


推荐答案

2008-06-14,rhino< No **************** *******@anonymous.comwrote:
On 2008-06-14, rhino <No***********************@anonymous.comwrote:

我已经把两层CSS标签的原型组合在一起非常好用
IE6,IE7和FF2中的
。它在Opera 9.27中运行得非常好_except_

下层标签的位置搞砸了。 XHTML和CSS

都可以验证,没有任何错误或警告。任何人都可以帮我弄清楚

是错的吗?
I''ve put together a prototype of two-tiered CSS tabs that works really well
in IE6, IE7, and FF2. It also works very well in Opera 9.27 _except_ that
the placement of the lower tier of tabs is messed up. Both the XHTML and CSS
validate without any errors or warnings. Can anyone help me figure out what
is wrong?



这不是一个错误:你正在设置位置:绝对在ul#subnav-2000但是

没有设置顶部。


这意味着如果浏览器是正常流量的话浏览器应该将它定位在它将会消失的地方,但根据规范,这个位置是免费的




Opera猜对了。


它'靠这个是不安全的。如果你使用position:absolute,我建议至少设置一个顶部/底部和一个左/右。


不确定为什么你需要位置:绝对在这里 - 它会停止

第二行标签,扩展第一个

行第一个标签的宽度,但我不知道为什么第二行需要是HTML中第一行的第一行元素。

It''s not a bug: you''re setting position: absolute on ul#subnav-2000 but
not setting top.

That means the browser is supposed to position it where it would have
gone if it had been normal-flow, but, according to the spec, it is free
to make a guess at that position.

Opera just guessed differently.

It''s not safe to rely on this. If you use position: absolute, I
recommend set at least one of top/bottom and one of left/right.

Not sure why you need position: absolute here anyway-- it stops the
second row of tabs extending the width of the first tab on the first
row, but I don''t know why the second row needs to be a child of the
first element of the first row in the HTML.




Ben C < sp ****** @ spam.eggswrote in message

news:sl ********************* @ bowser。 marioworld ...

"Ben C" <sp******@spam.eggswrote in message
news:sl*********************@bowser.marioworld...

2008-06-14,rhino< No ******************* ****@anonymous.comwrote:
On 2008-06-14, rhino <No***********************@anonymous.comwrote:

>我已经整理了一个双层CSS标签的原型,它真的很好用吗<在IE6,IE7和FF2中。它在Opera 9.27 _except_中也很有效,因为下层标签的位置搞砸了。 XHTML和
CSS都可以在没有任何错误或警告的情况下进行验证。任何人都可以帮我弄清楚什么是错的?
>I''ve put together a prototype of two-tiered CSS tabs that works really
well
in IE6, IE7, and FF2. It also works very well in Opera 9.27 _except_ that
the placement of the lower tier of tabs is messed up. Both the XHTML and
CSS
validate without any errors or warnings. Can anyone help me figure out
what
is wrong?



这不是一个错误:你正在设置位置:绝对在ul#subnav-2000但是

没有设置顶部。


这意味着如果浏览器是正常流量的话浏览器应该将它定位在它将会消失的地方,但根据规范,这个位置是免费的




Opera猜对了。


它'靠这个是不安全的。如果你使用position:absolute,我建议至少设置一个顶部/底部和一个左/右。


不确定为什么你需要位置:绝对在这里 - 它会停止

第二行标签,扩展第一个

行第一个标签的宽度,但我不知道为什么第二行需要是HTML中第一行

第一行的子元素。


It''s not a bug: you''re setting position: absolute on ul#subnav-2000 but
not setting top.

That means the browser is supposed to position it where it would have
gone if it had been normal-flow, but, according to the spec, it is free
to make a guess at that position.

Opera just guessed differently.

It''s not safe to rely on this. If you use position: absolute, I
recommend set at least one of top/bottom and one of left/right.

Not sure why you need position: absolute here anyway-- it stops the
second row of tabs extending the width of the first tab on the first
row, but I don''t know why the second row needs to be a child of the
first element of the first row in the HTML.



坦率地说,我不知道为什么还有一些CSS规则。我没有/ b $ b从头创建这个。我发现了一个非常接近我想要做的事情的例子,并调整它直到它按照我想要的方式行事 - 除了

来自第二层的位置Opera中的选项卡。


正如您可能看到的那样,原型试图显示一个双层菜单

,该网站的访问者可以查看各种新闻通讯由

网站发布。用户在上层标签中选择特定年份,然后显示

适当的较低层,以显示为该

年发布的问题。 (我假设某些年份可能有比其他年份更多或更多的问题)。一旦选择了适当的年份并且显示了该年度的问题选项卡

,用户就会选择他们想要的问题。


此HTML的HTML菜单集包含一个无序列表,每年有一个< lifor

。此列表是CSS的#topnav部分。然后,对于该外部列表中的每年

,其中还有另一个无序列表,显示该年度可用的

问题。每个问题列表都有一个不同的名称,例如

subnav-2000。每个关于简报的网页都包含确切的

相同的嵌套列表,显示每年的_all_问题。我在每个网页中使用本地CSS

来关闭所有问题列表,除了当前选择的

年份。


我假设原始代码中的CSS试图确保

问题标签位于年份标签下方。我不确定为什么

使用绝对定位;也许是为了确保问题

制表符位于年份标签下面?


无论如何,你能否建议我应该采取哪些不同的做法。我是

当然不会坚持使用绝对定位。我只是希望问题

标签会立即显示在年份标签下。


-

Rhino

Frankly, I''m not sure why some of the CSS rules are there either. I didn''t
create this from scratch. I found an example that came fairly close to what
I wanted to do and tweaked it until it was behaving the way I wanted - aside
from the placement of the second tier of tabs in Opera.

As you can probably see, the prototype is trying to show a two-tiered menu
where the visitor to the site can view various newsletters published by the
site. The user chooses a particular year in the upper tier of tabs, then the
appropriate lower tier is displayed to show the issues published for that
year. (I''m assuming that some years may have more or different issues than
other years). Once the appropriate year has been selected and the issues tab
for that year has been displayed, the user chooses the issue they want.

The HTML for this set of menus contains an unordered list with an <lifor
each year. This list is the #topnav portion of the CSS. Then, for each year
in that outer list, there is another unordered list within it, showing the
issues available in that year. Each issue list has a distinct name, like
subnav-2000. Every webpage concerning the newsletters contains the exact
same nested list showing _all_ of the issues for each year. I use local CSS
within each webpage to turn off all the issue lists except for the
currently-selected year.

I assume the CSS from the original code is trying to make sure that the
issues tabs are immediately below the years tabs. I''m not really sure why
the absolute positioning is being used; perhaps it is to ensure that issues
tabs is situated below the years tabs??

In any case, can you suggest what I should be doing differently. I''m
certainly not wedded to using absolute positioning. I just want the issues
tabs to be immediately under the years tabs.

--
Rhino


在文章< g3 ********** @ news.datemas.de>,

" rhino" < No *********************** @ anonymous.comwrote:
In article <g3**********@news.datemas.de>,
"rhino" <No***********************@anonymous.comwrote:

>

" Ben C" < sp ****** @ spam.eggswrote in message

news:sl ********************* @ bowser。 marioworld ...
>
"Ben C" <sp******@spam.eggswrote in message
news:sl*********************@bowser.marioworld...

2008-06-14,rhino< No ******************* ****@anonymous.comwrote:
On 2008-06-14, rhino <No***********************@anonymous.comwrote:

我已经整理了一个双层CSS标签的原型,它真的很有用

好吧
IE6,IE7和FF2中的
。它在Opera 9.27中运行得非常好_except_

下层标签的位置搞砸了。 XHTML和

CSS

验证没有任何错误或警告。任何人都可以帮我搞清楚

什么

错了?
I''ve put together a prototype of two-tiered CSS tabs that works really
well
in IE6, IE7, and FF2. It also works very well in Opera 9.27 _except_ that
the placement of the lower tier of tabs is messed up. Both the XHTML and
CSS
validate without any errors or warnings. Can anyone help me figure out
what
is wrong?



这不是一个错误:你正在设置位置:绝对在ul#subnav-2000但是

没有设置顶部。

It''s not a bug: you''re setting position: absolute on ul#subnav-2000 but
not setting top.


...

...


不知道为什么你需要位置:绝对在这里 - 它停止了

第二行标签扩展了第一行

行第一个标签的宽度,但我不知道为什么第二排需要成为
的孩子
HTML中第一行的第一个元素。
Not sure why you need position: absolute here anyway-- it stops the
second row of tabs extending the width of the first tab on the first
row, but I don''t know why the second row needs to be a child of the
first element of the first row in the HTML.



坦率地说,我不知道为什么还有一些CSS规则。 ...


在任何情况下,你能否提出我应该做的不同的事情。我是

当然不会坚持使用绝对定位。我只是希望问题

标签会立即显示在年份标签下。


Frankly, I''m not sure why some of the CSS rules are there either. ...

In any case, can you suggest what I should be doing differently. I''m
certainly not wedded to using absolute positioning. I just want the issues
tabs to be immediately under the years tabs.



有一种双层菜单似乎可以在Opera OK中使用


< http: //tvrs.org.au/disability/children.html>


可能会给你一个不同方法的想法吗?


-

dorayme

There''s a sort of two-tiered menu that seems to work in Opera OK at

<http://tvrs.org.au/disability/children.html>

Might give you an idea for a different approach?

--
dorayme


这篇关于需要帮助在Opera中查找CSS错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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