【发布时间】:2015-08-12 09:10:26
【问题描述】:
场景:-
我需要从 Facebook 相册中获取照片。为此,我使用 Galleria。
代码片段:-
$(document).ready(function (e) {
alert('jQuery loaded');
loadGallery();
function loadGallery() {
debugger;
Galleria.loadTheme('js/galleria/themes/classic/galleria.classic.min.js');
Galleria.run('#galleria', {
facebook: 'album:123xxxxx',
width: 745,
height: 550,
lightbox: true
});
}
});
<!DOCTYPE HTML/>
<html>
<head>
<title> Test </title>
<script src="jQuery"> </script>
<script src="galleria-1.4.2.min.js"></script>
<script src="js/galleria.facebook.js"></script>
</head>
<div id="galleria"></div>
</html>
请注意,我的配置中没有提到APP_ID或APP_SecretKey,据我所知,在使用Galleria时,我们只需要传递albumID。
【问题讨论】:
-
阅读我的ios答案可能会有所帮助.....stackoverflow.com/questions/30207465/…
标签: jquery facebook-graph-api galleria