loadsys/cakephp_sociallinks
Composer 安装命令:
composer require loadsys/cakephp_sociallinks
包简介
Adds fields to a model for saving social links, eg. Blog, Facebook, Twitter, etc.
README 文档
README
Adds fields to a model for saving social links, eg. Blog, Facebook, Twitter, etc.
Requirements
- PHP 5.3+
- CakePHP 2.1+
Installation
Composer
$ composer require loadsys/cakephp_sociallinks:~1.0
Usage
- Add SocialLinks to your application by adding this line to your bootstrap.php
CakePlugin::load('SocialLinks');
- Add Behavior to the Model, each parameter is the database field name, or
falseto not include that field
public $actsAs = array( 'SocialLinks.SocialLinks' => array( 'blog' => 'blog', //blog field name in the database, or false if you don't have this field 'pinterest' => false, //pinterest field name in the database, or false if you don't have this field 'googleplus' => 'googleplus', //googleplus field name in the database, or false if you don't have this field 'youtube' => 'youtube', //youtube field name in the database, or false if you don't have this field 'linkedin' => 'linkedin', //linkedin field name in the database, or false if you don't have this field 'facebook' => 'facebook', //facebook field name in the database, or false if you don't have this field 'twitter' => 'twitter', //twitter field name in the database, or false if you don't have this field ), );
Contributing
- Fork the plugin to your Github account
- Checkout the plugin
- Create a new branch with your changes
- Issue a PR back to the master branch with your changes
##License
Copyright (c) 2015 Loadsys Web Strategies
统计信息
- 总下载量: 298
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 3
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2014-02-17