ddkits / ddkitsfacebook
由 Sam Elayyoub 开发的 Facebook 页面发布器,使用自定义表和自定义函数发布到 Facebook 上的页面或群组。
2.1
2021-10-03 06:33 UTC
Requires
- php: >=5.6.4
- facebook/graph-sdk: *
- laravelcollective/html: *
This package is not auto-updated.
Last update: 2024-10-01 05:17:36 UTC
README
作者:Sam Elayyoub
1: 安装 Laravel 5.x
2: Composer require ddkits/ddkitsfacebook
3: 在服务提供者中添加 DDkits
- ...
'providers' => [
/*
* Application Service Providers...
*/
...
Ddkits\Ddkitsfacebook\DdkitsfacebookServiceProvider::class,
],
4: 如果更换主题
- php artisan vendor:publish --tag="Ddkits\Ddkitsfacebook\DdkitsfacebookServiceProvider"
5: 迁移此插件所需的数据库表
- php artisan migrate
6: 检查配置
- ddkitsfacebook.php got some extra configs for major uses
- Path: when calling the function "publishToPageNew($feed, $id)" posts on facebook would be linked to a path located in your site
要求
- Facebook app and Access_token https://developers.facebook.com/tools/explorer/
- Posts/blogs or feeds fields
- title
- path (slug of your site if using ID please create the slug field and copy the id into it)
- image (your post image)
用法:../admin-ddkits-facebook(必须登录用户,使用 Auth::id())
- ...
use Ddkits\Ddkitsfacebook;
...
$feed ==> is the page or node you are posting link to facebook
Ddkitsfacebook::publishToPageNew($feed, $id);
- Can be used as schedule cron too.
完成!!!