Html 背景图片后面的谷歌翻译下拉列表

Html 背景图片后面的谷歌翻译下拉列表,html,css,Html,Css,我正在使用谷歌网站翻译器,但当我将网页翻译成另一种语言时,浏览器顶部会出现一个下拉列表,导致我网站中除背景图像外的所有内容下降 我的网站是 您可以检查它,并可以查看我的源代码以了解问题。主体和背景照片的代码为: body { margin: 0; padding: 0; color: #555; font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 11px; line-height: 20px; background-c

我正在使用谷歌网站翻译器,但当我将网页翻译成另一种语言时,浏览器顶部会出现一个下拉列表,导致我网站中除背景图像外的所有内容下降

我的网站是

您可以检查它,并可以查看我的源代码以了解问题。主体和背景照片的代码为:

body {
margin: 0;
padding: 0;
color: #555;
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 11px;
line-height: 20px; 
background-color: #fff; 
background-image: url(images/templatemo_header.png);
background-position: top;
background-position:inherit;
background-repeat: repeat-x
}

尝试将以下样式添加到网站的样式表中:

.skiptranslate {display: none !important;}
 .background {
     background-image: url(images/templatemo_header.png);
     height: 188px;
     position: absolute;
     width: 100%;
  }

这将隐藏翻译完成后Google在您的网站上放置的栏。

您可以将背景移到正文外,因此它将成为Google translate也可以移动的DOM元素

在您的标签下方插入:


编辑:并从正文css规则中删除背景属性。

对我来说,它工作正常,谷歌翻译菜单覆盖了你的所有网站,包括背景否,我指的是菜单后面的顶部背景图像……当你更改语言时,会出现一个下拉列表,将所有内容向下推,但顶部背景图像不会随内容移动
 .background {
     background-image: url(images/templatemo_header.png);
     height: 188px;
     position: absolute;
     width: 100%;
  }