我正在使用以下HTML代码从我的服务器加载广告, 我想在中心显示它,我使用的是从互联网上获得的一些风格,但没有任何工作。
显示在右上角,必须是响应并且在中心
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<style type="text/css">
html, body {
width:100%;
height: 100%;
margin: 0px;
padding: 0px;
// some code I got to center that content
max-width: 100%;
max-height: 100%;
margin: auto;
overflow: auto;
position: fixed;
margin-left: auto; margin-right: auto;
}
</style>
</head>
<body>
<!-- this script loads the ad -->
<script type='text/javascript'>
var age = "23";
var gender="male";
//var location1="testifying";
var m3_u = (location.protocol=='https:'?'https://openxtest.wfihotspotnet.in/delivery/ajs.php':'http://openxtest.wfihotspotnet.in/delivery/ajs.php');
var m3_r = Math.floor(Math.random()*99999999999);
if (!document.MAX_used) document.MAX_used = ',';
document.write ("<scr"+"ipt type='text/javascript' src='"+m3_u);
document.write ("?zoneid=6");
document.write ("&TarGender=");
document.write ('&cb=' + m3_r);
if (document.MAX_used != ',') document.write ("&exclude=" + document.MAX_used);
document.write (document.charset ? '&charset='+document.charset : (document.characterSet ? '&charset='+document.characterSet : ''));
document.write ("&loc=" + escape(window.location));
if (document.referrer) document.write ("&referer=" + escape(document.referrer));
if (document.context) document.write ("&context=" + escape(document.context));
if (document.mmm_fo) document.write ("&mmm_fo=1");
document.write ("'><\/scr"+"ipt>");
</script>
</body>
</html>
此代码有什么问题,提前致谢
答案 0 :(得分:2)