") . &StoreCodeRaw($2) . &StoreRaw("\n<\/PRE>") . "\n"/igem; ### 이 줄 추가 s/(^|\n)\{\{\{#!((\w+)( .+)?)[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/$1.&StorePlugin($2,$5)."\n"/igem; ### {{{lang|n|t }}} 처리 s/(^|\n)\{\{\{([a-zA-Z0-9+]+)(\|(n|\d*|n\d+|\d+n))?[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/&StoreRaw("") . &StoreSyntaxHighlight($2, $4, $5) . &StoreRaw("<\/PRE>") . "\n"/igem; ### ############### }}} 다음 함수 통채로 추가 {{{#!vim perl ### 외부 plugin 지원 sub StorePlugin { my ($command, $content) = @_; my $name; my @opt; my $plugin_file = "";; $command = &UnquoteHtmlForPageContent($command); @opt = split (/\s/, $command); $name = shift @opt; my ($PluginDir, $MyPluginDir) = ("./plugin/", "./myplugin/"); if (-f "$MyPluginDir/$name.pl") { $plugin_file = "$MyPluginDir/$name.pl"; } elsif (-f "$PluginDir/$name.pl") { $plugin_file = "$PluginDir/$name.pl"; } if ($plugin_file eq "") { # 플러그인이 없음 return &StoreRaw("\n"). &StoreRaw("\nNo such plugin found: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } my $loadplugin = eval "require '$plugin_file'"; if (not $loadplugin) { # 플러그인 로드에 실패 return &StoreRaw("\n"). &StoreRaw("\nFailed to load plugin: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } my $func = "plugin_$name"; my $content_unquoted = &UnquoteHtmlForPageContent($content); my $txt = &{\&$func}($content_unquoted, @opt); if (not defined $txt) { # 플러그인이 undef 반환 return &StoreRaw("\n"). &StoreRaw("\nError occurred while processing: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } return &StoreRaw($txt); } }}} {{{#!vim perl sub GetPageLinks { ... $text =~ s/(.|\n)*?\<\/code>/ /ig; ### {{{ }}} 내의 내용은 태그로 간주하지 않음 $text =~ s/(^|\n)\{\{\{[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; $text =~ s/(^|\n)\{\{\{([a-zA-Z0-9+]+)(\|(n|\d*|n\d+|\d+n))?[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; # 아래 줄 추가 $text =~ s/(^|\n)\{\{\{#!((\w+)( .+)?)[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; ### if ($interlink) { ... } }}} === 추가 업데이트 내역 === ext1.72a - 플러그인호출시의 에러처리 개선 ext1.73b - 플러그인이 에러가 나서 원래 텍스트를 보여 줄 때 부등호 등이 치환되어 버리는 문제를 수정 ext1.74a - 미리보기에서 플러그인이 동작하지 않는 문제 수정 (저장된 텍스트를 읽을 때는 줄바꿈이 \n이지만 textarea에 있는 텍스트를 미리보기에 넘겨줄 때는 줄바꿈이 \r\n임) ext1.75 - 굳이 사용자가 바꿀 일이 없다고 판단되어서, 플러그인 파일이 들어가는 디렉토리 설정을 config 파일에서 제거함. ext1.95a - {{{#!...}}} 안의 내용 중에 위키네임이나 이중대괄호쌍이 있더라도 그것을 링크로 취급하지 않게 함. (즉, 역링크 검색이나 전체 링크 출력시 표시되지 않게 함) === 사용자 의견 === 다양한 플러그인이 나오기를 기대합니다~ :-) ---- [[위키위키분류]]
") . &StoreSyntaxHighlight($2, $4, $5) . &StoreRaw("<\/PRE>") . "\n"/igem; ### ############### }}} 다음 함수 통채로 추가 {{{#!vim perl ### 외부 plugin 지원 sub StorePlugin { my ($command, $content) = @_; my $name; my @opt; my $plugin_file = "";; $command = &UnquoteHtmlForPageContent($command); @opt = split (/\s/, $command); $name = shift @opt; my ($PluginDir, $MyPluginDir) = ("./plugin/", "./myplugin/"); if (-f "$MyPluginDir/$name.pl") { $plugin_file = "$MyPluginDir/$name.pl"; } elsif (-f "$PluginDir/$name.pl") { $plugin_file = "$PluginDir/$name.pl"; } if ($plugin_file eq "") { # 플러그인이 없음 return &StoreRaw("\n"). &StoreRaw("\nNo such plugin found: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } my $loadplugin = eval "require '$plugin_file'"; if (not $loadplugin) { # 플러그인 로드에 실패 return &StoreRaw("\n"). &StoreRaw("\nFailed to load plugin: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } my $func = "plugin_$name"; my $content_unquoted = &UnquoteHtmlForPageContent($content); my $txt = &{\&$func}($content_unquoted, @opt); if (not defined $txt) { # 플러그인이 undef 반환 return &StoreRaw("\n"). &StoreRaw("\nError occurred while processing: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } return &StoreRaw($txt); } }}} {{{#!vim perl sub GetPageLinks { ... $text =~ s/(.|\n)*?\<\/code>/ /ig; ### {{{ }}} 내의 내용은 태그로 간주하지 않음 $text =~ s/(^|\n)\{\{\{[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; $text =~ s/(^|\n)\{\{\{([a-zA-Z0-9+]+)(\|(n|\d*|n\d+|\d+n))?[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; # 아래 줄 추가 $text =~ s/(^|\n)\{\{\{#!((\w+)( .+)?)[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; ### if ($interlink) { ... } }}} === 추가 업데이트 내역 === ext1.72a - 플러그인호출시의 에러처리 개선 ext1.73b - 플러그인이 에러가 나서 원래 텍스트를 보여 줄 때 부등호 등이 치환되어 버리는 문제를 수정 ext1.74a - 미리보기에서 플러그인이 동작하지 않는 문제 수정 (저장된 텍스트를 읽을 때는 줄바꿈이 \n이지만 textarea에 있는 텍스트를 미리보기에 넘겨줄 때는 줄바꿈이 \r\n임) ext1.75 - 굳이 사용자가 바꿀 일이 없다고 판단되어서, 플러그인 파일이 들어가는 디렉토리 설정을 config 파일에서 제거함. ext1.95a - {{{#!...}}} 안의 내용 중에 위키네임이나 이중대괄호쌍이 있더라도 그것을 링크로 취급하지 않게 함. (즉, 역링크 검색이나 전체 링크 출력시 표시되지 않게 함) === 사용자 의견 === 다양한 플러그인이 나오기를 기대합니다~ :-) ---- [[위키위키분류]]
"). &StoreRaw("\nNo such plugin found: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } my $loadplugin = eval "require '$plugin_file'"; if (not $loadplugin) { # 플러그인 로드에 실패 return &StoreRaw("\n"). &StoreRaw("\nFailed to load plugin: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } my $func = "plugin_$name"; my $content_unquoted = &UnquoteHtmlForPageContent($content); my $txt = &{\&$func}($content_unquoted, @opt); if (not defined $txt) { # 플러그인이 undef 반환 return &StoreRaw("\n"). &StoreRaw("\nError occurred while processing: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } return &StoreRaw($txt); } }}} {{{#!vim perl sub GetPageLinks { ... $text =~ s/(.|\n)*?\<\/code>/ /ig; ### {{{ }}} 내의 내용은 태그로 간주하지 않음 $text =~ s/(^|\n)\{\{\{[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; $text =~ s/(^|\n)\{\{\{([a-zA-Z0-9+]+)(\|(n|\d*|n\d+|\d+n))?[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; # 아래 줄 추가 $text =~ s/(^|\n)\{\{\{#!((\w+)( .+)?)[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; ### if ($interlink) { ... } }}} === 추가 업데이트 내역 === ext1.72a - 플러그인호출시의 에러처리 개선 ext1.73b - 플러그인이 에러가 나서 원래 텍스트를 보여 줄 때 부등호 등이 치환되어 버리는 문제를 수정 ext1.74a - 미리보기에서 플러그인이 동작하지 않는 문제 수정 (저장된 텍스트를 읽을 때는 줄바꿈이 \n이지만 textarea에 있는 텍스트를 미리보기에 넘겨줄 때는 줄바꿈이 \r\n임) ext1.75 - 굳이 사용자가 바꿀 일이 없다고 판단되어서, 플러그인 파일이 들어가는 디렉토리 설정을 config 파일에서 제거함. ext1.95a - {{{#!...}}} 안의 내용 중에 위키네임이나 이중대괄호쌍이 있더라도 그것을 링크로 취급하지 않게 함. (즉, 역링크 검색이나 전체 링크 출력시 표시되지 않게 함) === 사용자 의견 === 다양한 플러그인이 나오기를 기대합니다~ :-) ---- [[위키위키분류]]
"). &StoreRaw("\nFailed to load plugin: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } my $func = "plugin_$name"; my $content_unquoted = &UnquoteHtmlForPageContent($content); my $txt = &{\&$func}($content_unquoted, @opt); if (not defined $txt) { # 플러그인이 undef 반환 return &StoreRaw("\n"). &StoreRaw("\nError occurred while processing: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } return &StoreRaw($txt); } }}} {{{#!vim perl sub GetPageLinks { ... $text =~ s/(.|\n)*?\<\/code>/ /ig; ### {{{ }}} 내의 내용은 태그로 간주하지 않음 $text =~ s/(^|\n)\{\{\{[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; $text =~ s/(^|\n)\{\{\{([a-zA-Z0-9+]+)(\|(n|\d*|n\d+|\d+n))?[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; # 아래 줄 추가 $text =~ s/(^|\n)\{\{\{#!((\w+)( .+)?)[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; ### if ($interlink) { ... } }}} === 추가 업데이트 내역 === ext1.72a - 플러그인호출시의 에러처리 개선 ext1.73b - 플러그인이 에러가 나서 원래 텍스트를 보여 줄 때 부등호 등이 치환되어 버리는 문제를 수정 ext1.74a - 미리보기에서 플러그인이 동작하지 않는 문제 수정 (저장된 텍스트를 읽을 때는 줄바꿈이 \n이지만 textarea에 있는 텍스트를 미리보기에 넘겨줄 때는 줄바꿈이 \r\n임) ext1.75 - 굳이 사용자가 바꿀 일이 없다고 판단되어서, 플러그인 파일이 들어가는 디렉토리 설정을 config 파일에서 제거함. ext1.95a - {{{#!...}}} 안의 내용 중에 위키네임이나 이중대괄호쌍이 있더라도 그것을 링크로 취급하지 않게 함. (즉, 역링크 검색이나 전체 링크 출력시 표시되지 않게 함) === 사용자 의견 === 다양한 플러그인이 나오기를 기대합니다~ :-) ---- [[위키위키분류]]
"). &StoreRaw("\nError occurred while processing: $name\n"). &StoreCodeRaw($content). &StoreRaw("\n<\/PRE>") . "\n"; } return &StoreRaw($txt); } }}} {{{#!vim perl sub GetPageLinks { ... $text =~ s/(.|\n)*?\<\/code>/ /ig; ### {{{ }}} 내의 내용은 태그로 간주하지 않음 $text =~ s/(^|\n)\{\{\{[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; $text =~ s/(^|\n)\{\{\{([a-zA-Z0-9+]+)(\|(n|\d*|n\d+|\d+n))?[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; # 아래 줄 추가 $text =~ s/(^|\n)\{\{\{#!((\w+)( .+)?)[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; ### if ($interlink) { ... } }}} === 추가 업데이트 내역 === ext1.72a - 플러그인호출시의 에러처리 개선 ext1.73b - 플러그인이 에러가 나서 원래 텍스트를 보여 줄 때 부등호 등이 치환되어 버리는 문제를 수정 ext1.74a - 미리보기에서 플러그인이 동작하지 않는 문제 수정 (저장된 텍스트를 읽을 때는 줄바꿈이 \n이지만 textarea에 있는 텍스트를 미리보기에 넘겨줄 때는 줄바꿈이 \r\n임) ext1.75 - 굳이 사용자가 바꿀 일이 없다고 판단되어서, 플러그인 파일이 들어가는 디렉토리 설정을 config 파일에서 제거함. ext1.95a - {{{#!...}}} 안의 내용 중에 위키네임이나 이중대괄호쌍이 있더라도 그것을 링크로 취급하지 않게 함. (즉, 역링크 검색이나 전체 링크 출력시 표시되지 않게 함) === 사용자 의견 === 다양한 플러그인이 나오기를 기대합니다~ :-) ---- [[위키위키분류]]
(.|\n)*?\<\/code>/ /ig; ### {{{ }}} 내의 내용은 태그로 간주하지 않음 $text =~ s/(^|\n)\{\{\{[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; $text =~ s/(^|\n)\{\{\{([a-zA-Z0-9+]+)(\|(n|\d*|n\d+|\d+n))?[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; # 아래 줄 추가 $text =~ s/(^|\n)\{\{\{#!((\w+)( .+)?)[ \t\r\f]*\n((.|\n)*?)\n\}\}\}[ \t\r\f]*\n/ \n/igm; ### if ($interlink) { ... } }}} === 추가 업데이트 내역 === ext1.72a - 플러그인호출시의 에러처리 개선 ext1.73b - 플러그인이 에러가 나서 원래 텍스트를 보여 줄 때 부등호 등이 치환되어 버리는 문제를 수정 ext1.74a - 미리보기에서 플러그인이 동작하지 않는 문제 수정 (저장된 텍스트를 읽을 때는 줄바꿈이 \n이지만 textarea에 있는 텍스트를 미리보기에 넘겨줄 때는 줄바꿈이 \r\n임) ext1.75 - 굳이 사용자가 바꿀 일이 없다고 판단되어서, 플러그인 파일이 들어가는 디렉토리 설정을 config 파일에서 제거함. ext1.95a - {{{#!...}}} 안의 내용 중에 위키네임이나 이중대괄호쌍이 있더라도 그것을 링크로 취급하지 않게 함. (즉, 역링크 검색이나 전체 링크 출력시 표시되지 않게 함) === 사용자 의견 === 다양한 플러그인이 나오기를 기대합니다~ :-) ---- [[위키위키분류]]