显示焦点 [英] Showing focus

查看:78
本文介绍了显示焦点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的应用中的特定

屏幕中看不到当前焦点时遇到问题。焦点不会显示为type = text或

textarea。我试图在测试应用程序中重现这个问题,

但是没有成功就是这样做了。


实际应用程序有一个显示的屏幕在模板上,

内容是来自AJAX调用的返回。在该内容中有一个

隐藏块。单击显示区域中的按钮会导致显示

隐藏块(灰色背景位于屏幕上

的固定位置)。在那个区域我有文本字段和文本

区域。我也有下拉列表和按钮。只有文本区域和

文本字段在那里没有显示焦点,但我可以输入它们所以

我知道焦点就在那里。


对于我的测试应用程序,我复制了我一直使用的CSS文件,并将

我的内容放在同一个名为< div>的内容中,其中实际内容为

出现在模板上。有了这个测试应用程序,没有问题。

测试应用程序位于 http:// www .sheldonlg.com / multiplesel ... multiples5.php


我甚至不知道从哪里开始寻找问题。我在谷歌搜索了ht ml showfocus,但这没什么帮助。


有什么建议吗?


(在comp.lang.javascript和alt.html中交叉发布)

解决方案

sheldonlg写道:
< blockquote class =post_quotes> http://www.sheldonlg.com/multiplesel ... multiples5.php



404


-

保重,


Jonathan

-------------------

小作品工作室
http://www.LittleWorksStudio.com


Jonathan N. Little写道:


sheldonlg写道:


> http://www.sheldonlg.com/multiplesel...multiples5.php



404

http://www.sheldonlg.com/multiplesel.../multiple5.php


对不起。


sheldonlgaécrit:


我遇到一个问题,即在特定情况下没有看到当前的焦点

屏幕在我的应用程序中。焦点不会显示为type = text或

textarea。我试图在测试应用程序中重现这个问题,

但是没有成功就是这样做了。


实际应用程序有一个显示的屏幕在模板上,

内容是来自AJAX调用的返回。在该内容中有一个

隐藏块。单击显示区域中的按钮会导致显示

隐藏块(灰色背景位于屏幕上

的固定位置)。在那个区域我有文本字段和文本

区域。我也有下拉列表和按钮。只有文本区域和

文本字段在那里不显示焦点,但我可以输入它们,所以

我知道焦点就在那里。



CSS(对于IE以外的其他人):


输入{background:silver}

输入:焦点{背景:白色}


HTML:


< input onfocus =" if(IE)this.background =' 'white'';"

onblur =" if(IE)this.background ='''';"

id =" hiddenInput" name =" Name">


JS:


IE = false; / * @ cc_on IE = true; @ * /


是你的div风格的visibity:隐藏;或显示:无; ?


是你的div同样的形式,当这个div出现在后面的表格时

前面?


这也发生在Firefox上吗?

-

sm


I have a problem with not seeing the current focus while in a particular
screen in a my app. The focus does not show for a type=text or
textarea. I have tried to reproduce this problem in a test application,
but have not been successful is doing that.

The actual app has a screen which is displayed on a template and the
contents are the return from an AJAX call. In that content there is a
hidden block. Clicking on a button in the displayed area causes that
hidden block to appear (with a gray background in a fixed location on
the screen). It is in that area that I have both text fields and text
areas. I also have dropdown lists and buttons. Only the text areas and
text fields do not display focus when there, but I can type into them so
I know that focus is there.

For my test app I copied the CSS file that I had been using and placed
my content within the same two named <div>s where the actual content
appears on the template. With this test app there is no problem. The
test app is at http://www.sheldonlg.com/multiplesel...multiples5.php.

I don''t even know where to start looking for the problem. I did a
search in Google for "ht ml showfocus", but that wasn''t much help.

Any suggestions?

(crossposted in comp.lang.javascript and alt.html)

解决方案

sheldonlg wrote:

http://www.sheldonlg.com/multiplesel...multiples5.php.

404

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com


Jonathan N. Little wrote:

sheldonlg wrote:

> http://www.sheldonlg.com/multiplesel...multiples5.php.


404

http://www.sheldonlg.com/multiplesel.../multiple5.php

Sorry.


sheldonlg a écrit :

I have a problem with not seeing the current focus while in a particular
screen in a my app. The focus does not show for a type=text or
textarea. I have tried to reproduce this problem in a test application,
but have not been successful is doing that.

The actual app has a screen which is displayed on a template and the
contents are the return from an AJAX call. In that content there is a
hidden block. Clicking on a button in the displayed area causes that
hidden block to appear (with a gray background in a fixed location on
the screen). It is in that area that I have both text fields and text
areas. I also have dropdown lists and buttons. Only the text areas and
text fields do not display focus when there, but I can type into them so
I know that focus is there.

CSS (for others than IE) :

input { background: silver }
input:focus { background: white }

HTML :

<input onfocus="if(IE) this.background=''white'';"
onblur="if(IE) this.background='''';"
id="hiddenInput" name="Name">

JS :

IE = false; /*@cc_on IE=true; @*/

is your div styled visibity: hidden; or display: none; ?

is your div in same form that the form in rear when this div comes at
front ?

does that happens also with Firefox ?
--
sm


这篇关于显示焦点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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