|
1: 2014-03-21 (金) 16:19:50 marine |
| + | [[こちら:https://www.facebook.com/groups/313506525343887/#]]で、nao-ponさんに教えてもらった「d3downloadsでサイトワイドWikiヘルパーを使う方法」です。 |
| | | |
| + | d3downloads_origin.php を xoops_trust_path/modules/d3downloads/filters/enabled に配置すると、アイテムの保存画面の本文フィルターに ”Orignal Sanitizer” が出てきますので、そこにチェックを入れると xpWiki レンダラー機能 でレンダリングされるようになります。 |
| + | |
| + | d3downloads はもともと xpWikiレンダラー機能 に独自に対応していて、そのためのフィルターも同梱されています。 |
| + | しかし、d3downloads のテキストサニタイザ は HypConf でのxpWikiレンダラー機能が効かない仕様なので、今回は、XOOPS オリジナルのテキストサニタイザを使用するためのフィルタで、結果的に HypConf での xpWikiレンダラー機能が有効になるそうです。 |
| + | |
| + | というこことで、次のソースを保存して指定したディレクトリに入れましょう。 |
| + | d3downloads_origin.php |
| + | <?php |
| + | define( '_MD_D3DOWNLOADS_FILTERS_ORIGIN_TITLE','Orignal filter' ); |
| + | if ( ! function_exists('d3downloads_origin') ) { |
| + | function d3downloads_origin( $text, $html, $smiley, $xcode, $image, $br ) |
| + | { |
| + | $myts =& MyTextSanitizer::getInstance(); |
| + | return $myts->displayTarea( $text, $html, $smiley, $xcode, $image, $br ); |
| + | } |
| + | } |
| + | ?> |
Counter: 3647,
today: 2,
yesterday: 1