Giter Club home page Giter Club logo

ls_ckchange's Introduction

CKChange

Плагин позволяет выбирать фото из уже загруженных на сервер. Необходим CKFinder. По умолчанию данный функционал доступен только администраторам.

Лицензия

Данный плагин распространяется по лицензии MIT. Полный текст лицензии находится в файле LICENSE.txt

Установка

#####1. Распаковать архив в папку /plugins/ #####2. Заугрузить CKFinder (я советую загружать в папку /engine/lib/external/) #####3. В папке с CKFinder найти файл config.php

  • Найти определение функции CheckAuthentication (примерно 24 строка):

      function CheckAuthentication()
      {
              // WARNING : DO NOT simply return "true". By doing so, you are allowing
              // "anyone" to upload and list the files in your server. You must implement
              // some kind of session validation here. Even something very simple as...
    
              // return isset($_SESSION['IsAuthorized']) && $_SESSION['IsAuthorized'];
    
              // ... where $_SESSION['IsAuthorized'] is set to "true" as soon as the
              // user logs in your system. To be able to use session variables don't
              // forget to add session_start() at the top of this file.
    
              return false;
      }
    
  • Снести все это к чертям (удалить)

  • Далее найти:

      $config['Thumbnails'] = Array(
              'url' => $baseUrl . '_thumbs',
              'directory' => $baseDir . '_thumbs',
              'enabled' => true,
              'directAccess' => false,
              'maxWidth' => 100,
              'maxHeight' => 100,
              'bmpSupported' => false,
              'quality' => 80);
    
  • И после 'quality' => 80); добавить подключение файла /include/ck_config.php. Например, у меня это так:

      require_once($_SERVER['DOCUMENT_ROOT'].'/plugins/ckchange/include/ck_config.php');
    

#####4. Установить модуль через админку.

ls_ckchange's People

Contributors

ferryvg avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.