「モジュール:String」の版間の差分

エラーメッセージとエラーカテゴリの日本語化
(1版 をインポートしました)
template>ネイ
(エラーメッセージとエラーカテゴリの日本語化)
115行目: 115行目:
{{#invoke:String|match|source_string|pattern_string|start_index|match_number|plain_flag|nomatch_output}}
{{#invoke:String|match|source_string|pattern_string|start_index|match_number|plain_flag|nomatch_output}}
OR
OR
{{#invoke:String|pos|s=source_string|pattern=pattern_string|start=start_index
{{#invoke:String|match|s=source_string|pattern=pattern_string|start=start_index
     |match=match_number|plain=plain_flag|nomatch=nomatch_output}}
     |match=match_number|plain=plain_flag|nomatch=nomatch_output}}


423行目: 423行目:
function str._error( error_str )
function str._error( error_str )
     local frame = mw.getCurrentFrame();
     local frame = mw.getCurrentFrame();
     local error_category = frame.args.error_category or 'Errors reported by Module String';
     local error_category = frame.args.error_category or 'モジュールStringのエラー';
     local ignore_errors = frame.args.ignore_errors or false;
     local ignore_errors = frame.args.ignore_errors or false;
     local no_category = frame.args.no_category or false;
     local no_category = frame.args.no_category or false;
431行目: 431行目:
     end
     end
      
      
     local error_str = '<strong class="error">String Module Error: ' .. error_str .. '</strong>';
     local error_str = '<strong class="error">モジュールStringのエラー: ' .. error_str .. '</strong>';
     if error_category ~= '' and not str._getBoolean( no_category ) then
     if error_category ~= '' and not str._getBoolean( no_category ) then
         error_str = '[[Category:' .. error_category .. ']]' .. error_str;
         error_str = '[[Category:' .. error_category .. ']]' .. error_str;
匿名利用者