Skip to content

Commit

Permalink
adding scayt check code
Browse files Browse the repository at this point in the history
  • Loading branch information
turnermm committed Nov 15, 2018
1 parent fa481e4 commit b0d1f11
Show file tree
Hide file tree
Showing 7 changed files with 26,772 additions and 6 deletions.
31 changes: 28 additions & 3 deletions action/meta.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,22 @@ function handle_profile_form(Doku_Event $event, $param) {
}

function _ajax_call(Doku_Event $event, $param) {

if ($event->data == 'cked_scaytchk') {
global $lang,$INPUT;
$event->stopPropagation();
$event->preventDefault();
$filename = metaFN('fckl:scayt','.meta');
$msg = $this->locale_xhtml('scayt');
if (!file_exists($filename)) {
io_saveFile($filename,'1');
echo "$msg\n";
return;
}


return;
}
if ($event->data == 'cked_upload') {
global $lang;
$event->stopPropagation();
Expand Down Expand Up @@ -181,7 +197,7 @@ function _ajax_call(Doku_Event $event, $param) {
echo $t;
return;
}
if ($event->data == 'wrap_lang') { //choose profile editor priority
if ($event->data == 'wrap_lang') { // parse and return language file to ckeditor warp plugin
$event->stopPropagation();
$event->preventDefault();
global $INPUT;
Expand Down Expand Up @@ -912,11 +928,20 @@ function reset_user_rewrite_check() {
function startup_msg() {
global $INFO;
global $ACT;

$show_msg = false;
if($INFO['isadmin'] || $INFO['ismanager'] ) { // only admins and mgrs get messages
$show_msg = true;
}
if(!$show_msg) return;
$filename = metaFN('fckl:scayt','.meta');
$msg = $this->locale_xhtml('scayt');

if (!file_exists($filename)) {
io_saveFile($filename,'1');
msg($msg,2);
return;
}
/*
$filename = metaFN('fckl:merger','.meta');
$msg = $this->locale_xhtml('merger');
if (!file_exists($filename)) {
Expand All @@ -934,7 +959,7 @@ function startup_msg() {
return;
}
}

*/
}
/**
checked for additional dw priority possibilities only if the dw priority option is set to true
Expand Down
Loading

0 comments on commit b0d1f11

Please sign in to comment.