LoginSignup
0
0

More than 5 years have passed since last update.

【サルが書く】cakephp2.x にgithubからogpプラグインをインストールする

Last updated at Posted at 2018-02-02

ogpをプラグインで設定したいよ〜〜

/app/composer.jsonに追加したいプラグインを記述する。


{
    "require": {
        "cakephp/cakephp": "2.*",
        "hogehoge" : "1.4.3",
        "fugafuga": "2.4.0",
        "monsat/ogp": "dev-master" // NEW!!!    
        },
}

追加するときのバージョン指定はpackagistを確認するなり、githubで確認するなりして指定してください。
https://packagist.org/

今回のogpのプラグインに関してはバージョンが開発バージョンしかなかったのでdev-masterという記述にしてあります。

記述後ローカルでcomposer update を行うとこのようなlogが出ると思います。

$ composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
  - Installing monsat/ogp (dev-master 89179c4): Cloning 89179c4e0e from cache
Writing lock file
Generating autoload files

下から3行目でInstalling monsat/ogpとなっているので、プラグインが入っているのだと確認できますね。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0