Инструменты пользователя

Инструменты сайта


it:dokuwiki

Различия

Показаны различия между двумя версиями страницы.

Ссылка на это сравнение

Предыдущая версия справа и слеваПредыдущая версия
Следующая версия
Предыдущая версия
it:dokuwiki [2020/06/13 19:37] – внешнее изменение 127.0.0.1it:dokuwiki [2023/08/06 09:30] (текущий) ura2404
Строка 10: Строка 10:
  
 [[https://wiki.rtzra.ru/wiki/installjacija_dokuwiki]] - про доп плагины, есть скрипт транслитерации имён файлов [[https://wiki.rtzra.ru/wiki/installjacija_dokuwiki]] - про доп плагины, есть скрипт транслитерации имён файлов
 +
 +[[https://wiki.soloshin.su/beget/dokuwiki/useful_plugins]] - Полезные плагины
  
 ---- ----
 В настройках В настройках
   *включить полную транслитерацию   *включить полную транслитерацию
 +  *включить вставку HTML и PHP (возможность больше не поддерживается)
  
 ---- ----
Строка 20: Строка 23:
   *[[https://www.dokuwiki.org/plugin%3Acolor|color]]   *[[https://www.dokuwiki.org/plugin%3Acolor|color]]
   *[[https://www.dokuwiki.org/plugin%253Ahighlight|Highlight]]   *[[https://www.dokuwiki.org/plugin%253Ahighlight|Highlight]]
 +  *[[https://www.dokuwiki.org/plugin:imagebox|imagebox]]
 +  *[[https://www.dokuwiki.org/plugin:commentsyntax|Comment Syntax Plugin]] - возможность скрывать текст
 +
  
 ---- ----
 +
 Добавил mime Добавил mime
 +  mht message/rfc822
   mhtml message/rfc822   mhtml message/rfc822
   eml message/rfc822   eml message/rfc822
 +  htm message/rfc822
 +  html message/rfc822
 +  kmz   application/vnd
 +  svg   image/svg+xml
 +  sh    text/plain
 +  py    text/plain
  
 +----
 +Для транслитирования имён файлов использовал скрипт\\
 +[[https://wiki.rtzra.ru/wiki/installjacija_dokuwiki]]\\
 +<file php convert.php>
 +<?php
 + 
 +if(!defined('DOKU_INC')) define('DOKU_INC',realpath(dirname(__FILE__).'/../').'/');
 +require_once(DOKU_INC.'inc/utf8.php');
 +require_once(DOKU_INC.'inc/infoutils.php');
 +require_once(DOKU_INC.'inc/Debug/DebugHelper.php');
 +require_once(DOKU_INC.'inc/Utf8/PhpString.php');
 +require_once(DOKU_INC.'inc/Utf8/Clean.php');
 +require_once(DOKU_INC.'inc/Utf8/Table.php');
 + 
 + 
 +/**
 + * Copy a file, or recursively copy a folder and its contents, and clean up the filenames according to the dokuwiki UTF-8 
 + *
 + * @original_author      Aidan Lister <aidan@php.net>
 + * @link        http://aidanlister.com/repos/v/function.copyr.php
 + * @param       string   $source    Source path
 + * @param       string   $dest      Destination path
 + * @return      bool     Returns TRUE on success, FALSE on failure
 + */
 +function copyr($source, $dest)
 +{
 +    $dest2=cleanID($dest);
 +    echo $source."->".$dest." ->$dest2<br/>";
 +    // Simple copy for a file
 +    if (is_file($source)) {
 +        return copy($source, $dest2);
 +    }
 + 
 +    // Make destination directory
 +    if (!is_dir($dest)) {
 +        mkdir($dest2);
 + 
 +    }
 + 
 +    // Loop through the folder
 +    $dir = dir($source);
 +    while (false !== $entry = $dir->read()) {
 +        // Skip pointers
 +        if ($entry == '.' || $entry == '..') {
 +            continue;
 +        }
 + 
 +        // Deep copy directories
 +        if ($dest !== "$source/$entry") {
 +            copyr("$source/$entry", "$dest/$entry");
 +        }
 +    }
 + 
 +    // Clean up
 +    $dir->close();
 +    return true;
 +}
 + 
 +copyr("/var/www/su.urx.wiki/data/","/var/www/su.urx.wiki/datanew/"); // пути к папкам на сервере (исходный и конечный)
 + 
 +function cleanID($id,$ascii=false){
 +  $id = trim(urldecode($id));
 +  $id = utf8_strtolower($id);
 +  $id = utf8_romanize($id);
 +  utf8_deaccent($id,-1);
 +  $id = preg_replace('#\'+#','_',$id);
 +  return($id);
 +}
 + 
 +?>
 +</file>
      
it/dokuwiki.1592077070.txt.gz · Последнее изменение: 2020/06/13 19:37 — 127.0.0.1