定制 gwhitcher/cakephp-photo-gallery 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

gwhitcher/cakephp-photo-gallery

Composer 安装命令:

composer require gwhitcher/cakephp-photo-gallery

包简介

PhotoGallery plugin for CakePHP.

README 文档

README

Developed by: George Whitcher

Installation

You can install this plugin into your CakePHP application using composer.

  • The recommended way to install composer packages is: composer require gwhitcher/cakephp-photo-gallery (If composer is unavailable download the zip and extract it to your plugins directory.)

  • PhotoGallery requires Imagick php extension for image resizing: Imagick. You cannot run it without it.

  • Install the database tables by visiting DOMAIN.com/photo_gallery/install or by running the below queries on your database.

CREATE TABLE gallery ( id INT UNSIGNED AUTO_INCREMENT PRIMARY KEY, category_id INT(11), title VARCHAR(50), description TEXT, img VARCHAR(50), created DATETIME DEFAULT NULL, modified DATETIME DEFAULT NULL );

CREATE TABLE category ( id INT UNSIGNED AUTO_INCREMENT PRIMARY KEY, title VARCHAR(50), description TEXT, img VARCHAR(50), created DATETIME DEFAULT NULL, modified DATETIME DEFAULT NULL );

  • CHMOD 777 your /plugins/PhotoGallery/webroot/img/gallery and all it's subfolders.

  • Go to your /ROOT/config/bootstrap.php and load the plugin by adding the following to the end of the file: Plugin::load('PhotoGallery', ['bootstrap' => false, 'routes' => true]);

  • Congratulations you are all setup!

URL Structure (this can be changed in routes.php)

The URL's are as follows: Auto Installer: DOMAIN.com/photo_gallery/install

Main gallery view: DOMAIN.com/photo_gallery/gallery DOMAIN.com/photo_gallery/category

Gallery image add: DOMAIN.com/photo_gallery/gallery/add

Category add: DOMAIN.com/photo_gallery/category/add

Gallery image edit: (replace ID) DOMAIN.com/photo_gallery/gallery/edit/ID

Category edit: (replace ID) DOMAIN.com/photo_gallery/category/edit/ID

Gallery image delete: (replace ID) DOMAIN.com/photo_gallery/gallery/delete/ID

Category delete: (replace ID) DOMAIN.com/photo_gallery/category/delete/ID

CUSTOM SECURITY

Open /plugins/PhotoGallery/src/Controller/AppController.php

You will see some commented out code. Remove the comments so it will be functioning.

Get your IP and replace it with the 127.0.0.1 (If you remove the comments from echo $ip you can get your current IP. It will show at the top of any unsecured page. Just make sure to remove it after you have noted your IP.)

统计信息

  • 总下载量: 41
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-07-21