現在の業務で、下記のコードを転用しなければならないのですが、
なにがなにやらさっぱりわかりません。。
どなたかjquery初心者の僕にもわかるように文章化していただけませんか。。
var imgList = [];
if(!$('#page-top').length){
imgList.push(
'../images/index/flower-body-11.png',
'../images/index/flower-body-12.png',
'../images/index/flower-body-13.png',
'../images/index/flower-body-21.png',
'../images/index/logo_main.png',
'../images/index/main_bg.jpg'
);
}else{ imgList.push( 'images/index/flower-body-11.png', 'images/index/flower-body-12.png', 'images/index/flower-body-13.png', 'images/index/flower-body-21.png', 'images/index/logo_main.png', 'images/index/main_bg.jpg' ); }
ex. #page-topが●●で●●のとき●●を●●する←例のような表現だと大変ありがたいです!!
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2016/02/18 11:47