0
我是java腳本新手,所以我從字面上複製和粘貼代碼,我認爲它沒有正確加載圖像。無法在我的360度滑塊上加載圖像
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" type="text/css" href="CSS.css">
<link rel="shortcut icon" type="image/ico"
href="../../CONTENT/Images/Logo/ICO.ico" />
<link rel="stylesheet" href="src/styles/threesixty.css">
<title>pappu-lighting</title>
<script src="jquery-3.2.1.js"></script>
</head>
<body>
<div class="threesixty" id="mythreesixty">
<div class="spinner">
<span>0%</span>
</div>
<ol class="threesixty_images"></ol>
</div>
<script type="text/javascript" src="src/threesixty.js"></script>
<script>
window.onload = init;
var product;
function init(){
my360 = $('#mythreesixty').ThreeSixty({
totalFrames: 72, // Total no. of image you have for 360 slider
endFrame: 72, // end frame for the auto spin animation
currentFrame: 1, // This the start frame for auto spin
imgList: '.threesixty_images', // selector for image list
progress: '.spinner', // selector to show the loading progress
imagePath:'assets/product1', // path of the image assets
filePrefix: 'ipod-', // file prefix if any
ext: '.jpg', // extention for the assets
height: 265,
width: 400,
navigation: true,
disableSpin: true // Default false
});
}
</script>
</body>
</html>
所以我的圖片源是在目錄中相同的文件夾:/資產/產品1/
我真的不知道什麼是錯的,但所有的插件和CSS文件正確加載。
沒有改變...我的圖片被命名爲1.jpg/2.jpg/3.jpg等。我是否需要更改他們的名字?這個文件前綴?他們需要重新命名爲: ipod-1.jpg/ipod-2.jpg ... –
無需重命名 – Rahul
imagePath:'/ assets/product1 /', – Rahul