对文本区域/输入焦点IE7按钮黑色边框 [英] Black border on IE7 buttons on textarea/input focus

查看:217
本文介绍了对文本区域/输入焦点IE7按钮黑色边框的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我碰到一个奇怪的问题,IE7 ..

I've run into a weird IE7 problem..

我有一个背景图片和坚实的1px的蓝色边框一些标准的CSS样式的按钮。他们的工作像预想的那样,除了在IE7 ..

I have some standard CSS styled buttons with a background picture and a solid 1px blue border. They work as supposed except in IE7..

如果我点击一个表单元素内(文本域/输入字段)在我的按钮会自动添加一个黑色边框。有时它也happends在元素聚焦/主动..

If I click inside a form element (textarea/input-field) it automatically adds a black border on my buttons.. Sometimes it also happends in other cases where elements are in focus/active..

您可以在这里看到一个简单的例子

You can see a simple example here

的事情是,我需要对造型的原因按钮的边界,所以不存在禁止在IE7这种行为不删除原有的边界的一种方式 - 无论是与CSS或jQuery的

The thing is that I need the border on the buttons for styling reasons, so isn't there a way of disabling this behaviour in IE7 without removing the original border - either with CSS or jQuery?

推荐答案

我的博客上讲述这里这个问题:<一href=\"http://markmintoff.com/2012/01/remove-internet-explorer-black-border-around-button/\">http://markmintoff.com/2012/01/remove-internet-explorer-black-border-around-button/

I blogged about this issue here: http://markmintoff.com/2012/01/remove-internet-explorer-black-border-around-button/

基本上你可以用下面的风格简单有效地删除有问题的边界。

Essentially you can use the following style to remove the offending border simply and effectively.

    input[type=submit],
    input[type=reset],
    input[type=button]
    {
        filter:chroma(color=#000000);
        color:#010101;
    }

这篇关于对文本区域/输入焦点IE7按钮黑色边框的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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