如何在3D轮播页面中插入背景图片 [英] how to insert background image in 3D Carousel page
问题描述
我正在使用此 http://www.flashxml.net/3d-carousel-menu.html [< ^ ]
我已经设法将自己的背景图片插入轮播后面,但是我也不能在其嵌入的页面上这样做:
Im using this http://www.flashxml.net/3d-carousel-menu.html[^]
I have managed to insert my own background image behind the carousel, but i cannot do it also on the page that its embedded on with this:
<body "background-image: url(qpq.jpg);">
也不是这样:
< script type ="text/javascript">
window.addEvent(''domready'',function(){
<!-BG图像加载->
window.addEvents({
//加载DOM时触发
domready:function(){
//图片的路径
var pathToBackgroundImage =''x11.jpg'';
//设置背景图像
$(document.body).setStyle(''background-image'',''url(''+ pathToBackgroundImage +'')'');
}
});
</script>
这是我正在讨论的页面的源代码:
nor with this:
<script type="text/javascript">
window.addEvent(''domready'',function(){
<!-- BG Image load -->
window.addEvents({
// fire when the DOM is loaded
domready: function(){
// path to the image
var pathToBackgroundImage = ''x11.jpg'';
// set the background-image
$(document.body).setStyle(''background-image'',''url('' + pathToBackgroundImage + '')'');
}
});
</script>
This is my source code for page in question:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head><title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
var flashvars = {};
var params = {};
params.scale = "noscale";
params.salign = "tl";
params.wmode = "transparent";
var attributes = {};
swfobject.embedSWF("3DCarouselMenuFX.swf", "CarouselDiv", "600", "400", "9.0.0", false, flashvars, params, attributes);
</script>
</head>
<body "background-image: url(images/02.jpg);">
<div style="border: 1px solid black; background-image: url(images/02.png); height: 400px; width: 600px;">
<div id="CarouselDiv"></div>
</div>
<div id="CarouselDiv"> <a href="http://www.adobe.com/go/getflashplayer"> <img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /> </a> </div>
<span style="z-index: 2; left: 602px; top: 0px; position: absolute;"><iframe name="I1" src="../innext.html" frameborder="0" height="415" scrolling="no" width="760">Your
browser does not
support inline frames or is currently configured
not to display inline frames.</iframe></span>
</body></html>
我强烈怀疑我只是将第二种方法放在错误的位置.我去了flashxml寻求帮助,但是他们说,因为它不是旋转木马里面的bg图像,所以没有帮助..所以我在这里.请帮忙.
i strongly suspect that i have just placed the second method in the wrong place. i went to flashxml for help but they said as its not the bg image inside carousel there not assisting with that..so i''m here. please help.
推荐答案
(document.body).setStyle(''background-image'',''url(''+ pathToBackgroundImage +'')'') );
}
});
</script>
这是我正在讨论的页面的源代码:
(document.body).setStyle(''background-image'',''url('' + pathToBackgroundImage + '')'');
}
});
</script>
This is my source code for page in question:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head><title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<script type="text/javascript" src="swfobject.js"></script>
<script type="text/javascript">
var flashvars = {};
var params = {};
params.scale = "noscale";
params.salign = "tl";
params.wmode = "transparent";
var attributes = {};
swfobject.embedSWF("3DCarouselMenuFX.swf", "CarouselDiv", "600", "400", "9.0.0", false, flashvars, params, attributes);
</script>
</head>
<body "background-image: url(images/02.jpg);">
<div style="border: 1px solid black; background-image: url(images/02.png); height: 400px; width: 600px;">
<div id="CarouselDiv"></div>
</div>
<div id="CarouselDiv"> <a href="http://www.adobe.com/go/getflashplayer"> <img src="http://www.adobe.com/images/shared/download_buttons/get_flash_player.gif" alt="Get Adobe Flash player" /> </a> </div>
<span style="z-index: 2; left: 602px; top: 0px; position: absolute;"><iframe name="I1" src="../innext.html" frameborder="0" height="415" scrolling="no" width="760">Your
browser does not
support inline frames or is currently configured
not to display inline frames.</iframe></span>
</body></html>
我强烈怀疑我只是将第二种方法放在错误的位置.我去了flashxml寻求帮助,但是他们说,因为它不是旋转木马里面的bg图像,所以没有帮助..所以我在这里.请帮忙.
i strongly suspect that i have just placed the second method in the wrong place. i went to flashxml for help but they said as its not the bg image inside carousel there not assisting with that..so i''m here. please help.
没关系,我找到解决方案的每个人
its OK everyone i found the solution
<style>
body {
background: url("http://yoursite.com/images/image_name.gif") 50% 50% no-repeat;
}
</style>
标签之间的处理就像对待!!
in between the tags works like a treat!
如上所述,如上所述,如上所述,如上所述,如上所述,如上所述,如上所述.
as above as above as above as above as above as above as above as above as above
这篇关于如何在3D轮播页面中插入背景图片的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!