Business solutions
  • Business events in Russia
  • Negotiations in Russia
  • Representative office in Russia
  • Investment projects in Russia
  • Legal support in Russia
  • Marketing in Russia (Internet marketing, SMM, PR, Event)
  • Exclusive Business Solutions (GR)
  • Business education (eMBA)
  • Immigration consulting
  • State registration of medical devices in the Russian Federation
News
  • RAUIE's news
  • Press about RAUIE
  • Eurasia Business News
Events
  • Calendar of events
  • Media gallery
About the RAUIE
  • About the RAUIE
  • Supervisory Board
  • Expert Council
  • Committees
  • Centers
  • Heads of RAUIE Representative Offices
  • Advisers
  • Partners and members
  • Internship and career at RAUIE
Membership
Contacts
Ещё
    Ask a Question
    +7 (495)136-9992
    +7 (800)700-2738
    Request a call
    office@raspp.ru
    Москва, 115035, 1-ый Кадашевский пер. д. 13, стр. 1
    • Facebook
    • Twitter
    • Instagram
    • Telegram
    • YouTube
    +7 (495)136-9992
    +7 (800)700-2738
    Request a call

    Business solutions
    • Business events in Russia
    • Negotiations in Russia
    • Representative office in Russia
    • Investment projects in Russia
    • Legal support in Russia
    • Marketing in Russia (Internet marketing, SMM, PR, Event)
    • Exclusive Business Solutions (GR)
    • Business education (eMBA)
    • Immigration consulting
    • State registration of medical devices in the Russian Federation
    News
    • RAUIE's news
    • Press about RAUIE
    • Eurasia Business News
    Events
    • Calendar of events
    • Media gallery
    About the RAUIE
    • About the RAUIE
    • Supervisory Board
    • Expert Council
    • Committees
    • Centers
    • Heads of RAUIE Representative Offices
    • Advisers
    • Partners and members
    • Internship and career at RAUIE
    Membership
    Contacts

      Business solutions
      • Business events in Russia
      • Negotiations in Russia
      • Representative office in Russia
      • Investment projects in Russia
      • Legal support in Russia
      • Marketing in Russia (Internet marketing, SMM, PR, Event)
      • Exclusive Business Solutions (GR)
      • Business education (eMBA)
      • Immigration consulting
      • State registration of medical devices in the Russian Federation
      News
      • RAUIE's news
      • Press about RAUIE
      • Eurasia Business News
      Events
      • Calendar of events
      • Media gallery
      About the RAUIE
      • About the RAUIE
      • Supervisory Board
      • Expert Council
      • Committees
      • Centers
      • Heads of RAUIE Representative Offices
      • Advisers
      • Partners and members
      • Internship and career at RAUIE
      Membership
      Contacts
        • Business solutions
          • Назад
          • Business solutions
          • Business events in Russia
          • Negotiations in Russia
          • Representative office in Russia
          • Investment projects in Russia
          • Legal support in Russia
          • Marketing in Russia (Internet marketing, SMM, PR, Event)
          • Exclusive Business Solutions (GR)
          • Business education (eMBA)
          • Immigration consulting
          • State registration of medical devices in the Russian Federation
        • News
          • Назад
          • News
          • RAUIE's news
          • Press about RAUIE
          • Eurasia Business News
        • Events
          • Назад
          • Events
          • Calendar of events
          • Media gallery
        • About the RAUIE
          • Назад
          • About the RAUIE
          • About the RAUIE
          • Supervisory Board
          • Expert Council
          • Committees
          • Centers
          • Heads of RAUIE Representative Offices
          • Advisers
          • Partners and members
          • Internship and career at RAUIE
        • Membership
        • Contacts
        • +7 (495)136-9992
          • Назад
          • +7 (495)136-9992
          • +7 (800)700-2738
          • Request a call
        office@raspp.ru
        Москва, 115035, 1-ый Кадашевский пер. д. 13, стр. 1
        • Facebook
        • Twitter
        • Instagram
        • Telegram
        • YouTube

        Контролируемое скачивание

        • Меню
        • Контролируемое скачивание
        • Импорт RSS
        • Настраиваемая регистрация
        • Мои компоненты
          • Как сделать свой компонент?
          • Список новостей
          • Новость детально
          • Комплексный компонент
          • Комплексный компонент. ЧПУ
        • Правила обработки адресов (ЧПУ)
        • Форма обратной связи
        Request a call
        Write message
        Leave feedback
        Nearest office
        Скачать файл manual.zip

        Скачать файл private_file.zip

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

        В каталоге /examples/download/ находится пример скачивания общедоступных файлов с сайта с фиксацией событий в модуле статистики. Все файлы для скачивания лежат в каталоге /examples/download/files/. При создании ссылки на файл для скачивания каталог /files/ не указывается.

        При клике по созданной ссылке вызывается файл, указанный как обработчик 404 ошибки в файле .htaccess в текущем каталоге. В нашем примере это файл download.php.

        В этом же каталоге есть скрипт download_balance.php. Он позволяет регулировать нагрузку скачиваний между несколькими серверами. На этих серверах должны быть абсолютно идентичные каталоги /download/ с одинаковым набором файлов и подкаталогов.
        Для того чтобы подключить этот скрипт необходимо:
        1. В файле .htaccess установить обработчик 404 ошибки на этот скрипт.
        2. В скрипте download_balance.php раскомментировать массив $arrHOSTS и задать в нем адреса серверов для скачиваний и вероятности выбора того или иного сервера.
        Для того чтобы система разрешала скачивать файлы всем без авторизации, необходимо в корне сайта разместить файл .access.php со следующим содержимым:
        <? $PERM["/"]["*"]="R"; ?>

        В каталоге /examples/download/download_private/ приведен пример реализации скачивания файлов с ограниченным доступом с фиксацией события в модуле статистики.

        Все файлы лежат в каталоге /examples/download/download_private/files/, а ссылка на файл для скачивания имеет вид:
        <a href="/examples/download/download_private/private_file.zip"> private_file.zip</a> (т.е. без каталога /files/).
        Настройки произведены таким образом, что только зарегистрированные пользователи имеют право на скачивание этого файла из каталога. Доступ на чтение каталога /files имеют только зарегистрированные пользователи.
        Файл download_private.php вызывается в этом случае как обработчик 404 ошибки.
        Business solutions
        News
        Events
        About the RAUIE
        Membership
        Contacts
        • Facebook
        • Twitter
        • Instagram
        • Telegram
        • YouTube
        +7 (495)136-9992
        +7 (800)700-2738
        Request a call
        office@raspp.ru
        Москва, 115035, 1-ый Кадашевский пер. д. 13, стр. 1
        Подписка на рассылку
        Версия для печати
        © 2023 All rights reserved.
        Privacy policy
        Request a call
        Write message
        Leave feedback
        Nearest office