gajus / falbum
用户界面,用于从Facebook相册中选择照片。
dev-master
2014-03-26 08:34 UTC
Requires
- php: >=5.5
Requires (Dev)
- satooshi/php-coveralls: dev-master
This package is not auto-updated.
Last update: 2024-09-14 16:03:12 UTC
README
演示。注意,演示实际上不会上传任何文件。然而,PHP文件中已经写下了所有逻辑。您需要向PHP脚本发起XHR请求以启动上传到服务器。
用法
脚本将自动确保用户已获得所需的权限(即user_photos
)。
$.gajus.falbum({callback: function(r) {
if (!r) {
// User did not select any photo.
} else if(r.url) {
// Url of the selected photo.
} else if (r.error) {
// Error object containing the error.code and error.message.
}
},
loader: $('#your-loader'), // Optional. jQuery reference to the element that will be displayed when the script is loading (XHR requestss, etc.).
debug: false // Optional. Allows to track (console.) script activity.
});