从网站中的元素中删除边框线

Removing a border line from an element in a website

我正在努力从我网站的垂直菜单中删除该行http://propertypricesearch.com/(有一条垂直线)

我试图检查元素,它似乎是 .vertical_area_background class

.vertical_area_background{
    position: fixed;
    width: 290px;
    height: 100%;
    background-position: right top;
    background-repeat: no-repeat;
    background-size: cover;
    border-right-width: 0px !important;
    top: 0px;
    left: 0px;
    right: 0px;
    border-style: none;
    z-index: 0;
    -webkit-transition: opacity 0.5s ease, background-color 0.5s ease;
    -moz-transition: opacity 0.5s ease, background-color 0.5s ease;
    -o-transition: opacity 0.5s ease, background-color 0.5s ease;
    -ms-transition: opacity 0.5s ease, background-color 0.5s ease;
    transition: opacity 0.5s ease, background-color 0.5s ease;
    opacity: 1;
    background-color: #1d2022;
}

在那里我放了这样的行

right: 0px;

border-right-width: 0px !important;

但它仍然显示线

用 Chrome 检查并找到导致该行的规则。像这样覆盖它:

body.vertical_menu_background_opacity_over_slider_on  .vertical_menu_area {
  border-right: 0 !important;
}

问题

此元素上有边框,

body.vertical_menu_background_opacity_over_slider_on .vertical_menu_area

解决方案

改变这个,

body.vertical_menu_background_opacity_over_slider_on .vertical_menu_area {
    border-right: 1px solid rgba(255,255,255,0.5);

}

1.

 body.vertical_menu_background_opacity_over_slider_on .vertical_menu_area {
        border-right: 1px solid rgba(255,255,255,0.5);
         border-right: none !important;

    }

2.

body.vertical_menu_background_opacity_over_slider_on .vertical_menu_area {
    border-right: 1px solid rgba(255,255,255,0.5);
     border-right: 0 !important;

}

3.

body.vertical_menu_background_opacity_over_slider_on .vertical_menu_area {
    border-right: 1px solid rgba(255,255,255,0.5);

}

基本上,这些选项中的每一个都是删除规则或用 !important

覆盖它

如果您有权访问,我会删除该规则。如果您必须覆盖它,那么我会向我的 css 添加一条新规则,看起来像这样,

body.vertical_menu_background_opacity_over_slider_on .vertical_menu_area {
         border-right: none !important;

    }

使用border-right: 0;border-right: none;的区别

border: none; However, the line-style value of none will cause the color and width values to be ignored as stated in the CSS Specification: 'none' No border. Color and width are ignored (i.e., the border has width 0

或者,您也可以在特定的 div 支架上放置边框:none 或右边框:none,而不是使用 !important

<aside class="vertical_menu_area with_scroll " tabindex="5000" style="overflow-y: hidden; outline: none; border-right: none;">