Permalink
Browse files

php7でOnly variables should be passed by referenceが起きる問題の一部修正。

  • Loading branch information...
1 parent b9e7ba5 commit 90d505b58b98a194819a7a9412404d89649bbab5 @logue committed Jul 7, 2016
@@ -1,13 +1,4 @@
/* ==|== Tweek Tags ========================================================= */
-/* Fix italic font */
-i, em, cite, q {
- font-style: normal;
- -webkit-transform: skewX(-15deg);
- -moz-transform: skewX(-15deg);
- -ms-transform: skewX(-15deg);
- -o-transform: skewX(-15deg);
- transform: skewX(-15deg);
-}
/* Fix Gecko Ruby Tag */
.gecko ruby {
display: inline-table !important;
@@ -24,16 +24,11 @@
@import "bootstrap";
@import "font-awesome";
-/*!
- * PukiWiki base stylesheet start
- */
@import 'components/browser';
@import 'components/table';
@import 'components/tweeks';
@import 'components/plugin';
-/*!
- * PukiWiki widgets stylesheet start
- */
+
@import 'components/widgets';
@import 'components/widgets-dataTables';
@import 'components/widgets-google-search';
@@ -42,7 +42,7 @@ class Render{
/**
* jQueryのバージョン
*/
- const JQUERY_VER = '2.1.3';
+ const JQUERY_VER = '3.0.0';
//const JQUERY_VER = '1.11.2';
/**
* jQuery UIのバージョン
@@ -248,19 +248,19 @@ public function getContent(){
// ステータスアイコン
if ($this->wiki->isFreezed()){
// 錠前マーク(フリーズされてる)
- $view->status = '<span class="fa fa-lock" title="Freezed"></span>';
+ $view->status = '<i class="fa fa-lock" title="Freezed" aria-hidden="true"></i>';
}else if (!$this->wiki->isEditable()){
// 駐禁マーク(編集できない)
- $view->status = '<span class="fa fa-ban" title="Not Editable"></span>';
+ $view->status = '<i class="fa fa-ban" title="Not Editable" aria-hidden="true"></i>';
}else{
// 鉛筆マーク(編集できる)
- $view->status = '<span class="fa fa-pencil-square" title="Editable"></span>';
+ $view->status = '<i class="fa fa-pencil-square" title="Editable" aria-hidden="true"></i>';
}
}else{
// プラグインを実行する場合、大抵の場合メニューバーやサイドバーを表示しない
$view->colums = View::CLASS_NO_COLUMS;
// ステータスアイコンを歯車にする
- $view->status = '<span class="fa fa-cog" title="Function mode"></span>';
+ $view->status = '<i class="fa fa-cog" title="Function mode" aria-hidden="true"></i>';
}
// ナビバー
@@ -355,6 +355,7 @@ private function getJs(){
}
$pkwk_head_js[] = array('type'=>'text/javascript', 'src'=>JS_URI.'locale.js', 'defer'=>'defer' );
+ $pkwk_head_js[] = array('type'=>'text/javascript', 'src'=>'/assets/js/app.js', 'defer'=>'defer' );
// $js_vars[] = 'var pukiwiki = {};';
foreach( $js_init as $key=>$val){
@@ -5,10 +5,10 @@
* @package PukiWiki\Renderer\Element
* @access public
* @author Logue <logue@hotmail.co.jp>
- * @copyright 2013-2014 PukiWiki Advance Developers Team
+ * @copyright 2013-2014,2016 PukiWiki Advance Developers Team
* @create 2013/01/26
* @license GPL v2 or (at your option) any later version
- * @version $Id: DList.php,v 1.0.1 2014/03/17 17:20:00 Logue Exp $
+ * @version $Id: DList.php,v 1.0.1 2016/07/07 18:10:00 Logue Exp $
*/
namespace PukiWiki\Renderer\Element;
@@ -26,7 +26,8 @@ class DList extends ListContainer
public function __construct($out)
{
parent::__construct('dl', 'dt', ':', $out[0]);
- $this->last = Element::insert(new ListElement($this->level, 'dd'));
+ $element = new ListElement($this->level, 'dd');
+ $this->last = Element::insert($element);
if ( !empty($out[1]) )
$this->last = $this->last->insert(ElementFactory::factory('InlineElement', null, $out[1]));
}
@@ -5,10 +5,10 @@
* @package PukiWiki\Renderer\Element
* @access public
* @author Logue <logue@hotmail.co.jp>
- * @copyright 2013 PukiWiki Advance Developers Team
+ * @copyright 2013,2016 PukiWiki Advance Developers Team
* @create 2013/01/26
* @license GPL v2 or (at your option) any later version
- * @version $Id: RootElement.php,v 1.0.0 2013/02/12 15:13:00 Logue Exp $
+ * @version $Id: RootElement.php,v 1.0.1 2016/07/07 18:06:00 Logue Exp $
*/
namespace PukiWiki\Renderer\Element;
@@ -85,7 +85,8 @@ public function parse($lines)
if (preg_match('/^(LEFT|CENTER|RIGHT|JUSTIFY):(.*)$/', $line, $matches)) {
// <div style="text-align:...">
- $this->last = $this->last->add(new Align(strtolower($matches[1])));
+ $align = new Align(strtolower($matches[1]));
+ $this->last = $this->last->add($align);
if (empty($matches[2])) continue;
$line = $matches[2];
}
@@ -100,7 +101,8 @@ public function parse($lines)
// Horizontal Rule
if (substr($line, 0, 4) == '----') {
- $this->insert(new HRule($this, $line));
+ $hrule = new HRule($this, $line);
+ $this->insert($hrule);
continue;
}
@@ -131,13 +133,15 @@ public function parse($lines)
// Pre
if ($head === ' ' || $head === "\t") {
- $this->last = $this->last->add(new Pre($this, $line));
+ $pre = new Pre($this, $line);
+ $this->last = $this->last->add($pre);
continue;
}
// CPre (Plus!)
if (substr($line,0,2) === '# ' or substr($line,0,2) == "#\t") {
- $this->last = $this->last->add(new SharpPre($this,$line));
+ $sharppre = new SharpPre($this,$line);
+ $this->last = $this->last->add($sharppr);
continue;
}
@@ -198,7 +202,8 @@ public function parse($lines)
$next_line = preg_replace("/[\r\n]*$/", '', array_shift($lines)) ;
$line .= "\n" . ' ' . $next_line;
}
- $this->last = $this->last->add(new BlockPlugin(array(null, 'mathjax', $line)));
+ $mathjax = new BlockPlugin(array(null, 'mathjax', $line));
+ $this->last = $this->last->add($mathjax);
continue;
}
}
@@ -5,10 +5,10 @@
* @package PukiWiki\Renderer
* @access public
* @author Logue <logue@hotmail.co.jp>
- * @copyright 2012-2015 PukiWiki Advance Developers Team
+ * @copyright 2012-2016 PukiWiki Advance Developers Team
* @create 2012/12/18
* @license GPL v2 or (at your option) any later version
- * @version $Id: RendererDefines.php,v 1.0.1 2015/05/20 18:57:00 Logue Exp $
+ * @version $Id: RendererDefines.php,v 1.0.1 2016/07/07 17:27:00 Logue Exp $
*/
namespace PukiWiki\Renderer;
@@ -37,27 +37,27 @@ class RendererDefines{
/**
* 内部リンクのアイコン
*/
- const INTERNAL_LINK_ICON = '<span class="fa fa-external-link-square" title="Internal Link"></span>';
+ const INTERNAL_LINK_ICON = '<i class="fa fa-external-link-square" title="Internal Link" aria-hidden="true"></i>';
/**
* 外部リンクのアイコン
*/
- const EXTERNAL_LINK_ICON = '<span class="fa fa-external-link" title="External Link"></span>';
+ const EXTERNAL_LINK_ICON = '<i class="fa fa-external-link" title="External Link" aria-hidden="true"></i>';
/**
* メールリンクのアイコン
*/
- const MAILTO_ICON = '<span class="fa fa-envelope" title="mailto:"></span>';
+ const MAILTO_ICON = '<i class="fa fa-envelope" title="mailto:" aria-hidden="true"></i>';
/**
* 電話番号リンクのアイコン
*/
- const TELEPHONE_ICON = '<span class="fa fa-phone" title="tel:"></span>';
+ const TELEPHONE_ICON = '<i class="fa fa-phone" title="tel:" aria-hidden="true"></i>';
/**
* InterWikiNameのアイコン
*/
- const INTERWIKINAME_ICON = '<span class="fa fa-globe" title="InterWikiName"></span>';
+ const INTERWIKINAME_ICON = '<i class="fa fa-globe" title="InterWikiName" aria-hidden="true"></i>';
/**
* 部分編集リンクのアイコン
*/
- const PARTIAL_EDIT_LINK_ICON = '<span class="fa fa-pencil" title="Edit here"></span>';
+ const PARTIAL_EDIT_LINK_ICON = '<i class="fa fa-pencil" title="Edit here" aria-hidden="true"></i>';
/**
* 見つからないページのリンク
*/
@@ -77,7 +77,7 @@ class RendererDefines{
/**
* ノートのアイコン
*/
- const FOOTNOTE_ANCHOR_ICON = '<span class="glyphicon glyphicon-pushpin"></span>';
+ const FOOTNOTE_ANCHOR_ICON = '<i class="fa fa-thumb-tack" aria-hidden="true"></i>';
}
/* End of file RendererDefines.php */
@@ -21,7 +21,7 @@ class MeCab{
public $usable = false;
public function __construct($mecab_path = ''){
if (!extension_loaded('mecab')) {
- if (!empty($mecab_path) && file_exists($mecab_path)){
+ if (!empty($mecab_path) && @file_exists($mecab_path)){
$this->mecab_path = $mecab_path;
$this->usable = true;
//throw new Exception('Mecab is not found or not executable. Please check mecab path: '.$mecab_path);
@@ -47,11 +47,11 @@
}
define('REMOTE_ADDR', isset($_SERVER['HTTP_CF_CONNECTING_IP']) ? $_SERVER['HTTP_CF_CONNECTING_IP'] : $_SERVER['REMOTE_ADDR']);
-
-if (class_exists('PDO')){
+/*
+if (class_exists('Pdo')){
die('PukiWiki Adv. requires PDO.');
}
-
+*/
// Load Bad-behavior
if (file_exists(VENDOR_DIR . 'bad-behavior' . DIRECTORY_SEPARATOR . 'bad-behavior-sqlite.php') ){
require( VENDOR_DIR . 'bad-behavior' . DIRECTORY_SEPARATOR . 'bad-behavior-sqlite.php');
@@ -1,7 +1,7 @@
<?php
// table_edit2.inc.php, 3.1+calc0.6+func0.3 2009/11/19 taru plugin
-// Modified by PukiWiki Adv. Team 2012,2015
+// Modified by PukiWiki Adv. Team 2012,2015,2016
use PukiWiki\Auth\Auth;
use PukiWiki\Factory;
use PukiWiki\Router;
@@ -39,7 +39,6 @@ function plugin_table_edit2_convert()
$wiki = Factory::Wiki($page);
$count = $number[$page]++;
$r_page = rawurlencode($page);
- if (! function_exists('_')) table_edit2_message();
// 初期設定
$opt = array(
@@ -1029,7 +1028,6 @@ function plugin_table_edit2_inline()
'table_sub_num' => '',
'cell_count' => '',
);
- if (! function_exists('_')) table_edit2_message();
$s_table_edit = T_('edit');
$s_table_add = T_('addition');
@@ -1091,8 +1089,6 @@ function plugin_table_edit2_action()
$table_sub_num_chk = 1; //td
$setting = 0;
$import = $export = $csv_cancel = 0;
-
- if (! function_exists('_')) table_edit2_message();
$edit_mod = isset($vars['edit_mod']) ? $vars['edit_mod'] : '';

0 comments on commit 90d505b

Please sign in to comment.