summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ea699a4)
raw | patch | inline | side by side (parent: ea699a4)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 8 Jul 2010 13:33:54 +0000 (13:33 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 8 Jul 2010 13:33:54 +0000 (13:33 +0000) |
-Respect encoding modification for uploaded scripts too.
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18967 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18967 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/fai/admin/fai/class_faiScriptEntry.inc | patch | blob | history |
diff --git a/gosa-plugins/fai/admin/fai/class_faiScriptEntry.inc b/gosa-plugins/fai/admin/fai/class_faiScriptEntry.inc
index edafad3cf699257c2a9f54fb1b69c056c91ac8ec..9f42d330203e168db9b3520ae6990348b4f1f3a7 100644 (file)
}else{
$str = file_get_contents($_FILES['ImportFile']['tmp_name']);
$this->FAIscript = $str;
+
+ // Check encoding again
+ if($this->mb_extension){
+ $this->enc_before_edit = mb_detect_encoding($this->FAIscript);
+ if($this->enc_before_edit != "ASCII"){
+ $this->write_protect = TRUE;
+ }
+ }
}
}