nathanfeitoza/firebase-php5.6
最新稳定版本:1.0.0
Composer 安装命令:
composer require nathanfeitoza/firebase-php5.6
包简介
Firebase Admin SDK
README 文档
README
This repository is a fork of the original version 2.3.1 so that users of php version 5.6 or lower can work with google firebase.
Thanks for all support of Jérôme Gamez.
This SDK makes it easy to interact with Google Firebase applications.
For support, please use the issue tracker, or join the Firebase Community Slack at https://firebase-community.appspot.com and join the #php channel.
Documentation
You can find the documentation at https://firebase-php.readthedocs.io/en/2.3.1
composer require nathanfeitoza/firebase-php5.6
Usage example
$firebase = (new \Firebase\Factory()) ->withCredentials(__DIR__.'/path/to/google-service-account.json') ->withDatabaseUri('https://my-project.firebaseio.com') ->create(); $database = $firebase->getDatabase(); $newPost = $database ->getReference('blog/posts') ->push([ 'title' => 'Post title', 'body' => 'This should probably be longer.' ]); $newPost->getKey(); // => -KVr5eu8gcTv7_AHb-3- $newPost->getUri(); // => https://my-project.firebaseio.com/blog/posts/-KVr5eu8gcTv7_AHb-3- $newPost->getChild('title')->set('Changed post title'); $newPost->getValue(); // Fetches the data from the realtime database $newPost->remove();
统计信息
- 总下载量: 4.17k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2019-09-11