diff --git a/languages/english.php b/languages/english.php index 9a49c88..8b114fa 100644 --- a/languages/english.php +++ b/languages/english.php @@ -2,4 +2,3 @@ $GLOBALS['english']["can't open"] = 'Write successfully'; $GLOBALS['english']["ok"] = "I can't open $file"; $GLOBALS['english']["showClass/showOther"] = "I can't find the settings showClass and showOther"; -?> \ No newline at end of file diff --git a/languages/slovenian.php b/languages/slovenian.php index b6cdc3b..5622ab4 100644 --- a/languages/slovenian.php +++ b/languages/slovenian.php @@ -1,5 +1,4 @@ \ No newline at end of file diff --git a/php-config.php b/php-config.php index d3705bb..4cad083 100644 --- a/php-config.php +++ b/php-config.php @@ -1,140 +1,154 @@ $a=array($b,$c,$GLOBALS['stevilo']); - } - } - - function toString($class='',$addclass='',$addnoclass=''){ - if($GLOBALS['status']!=0) { - if($GLOBALS['showClass']==''or $GLOBALS['showOther']=='') { - $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]['showClass/showOther'] ; - $GLOBALS['status']=0;} - $string .='$a=array($b,$c,$GLOBALS['stevilo']); + } + } + + public function toString($class = '', $addclass = '', $addnoclass = '') + { + if ($GLOBALS['status']!=0) { + if ($GLOBALS['showClass']==''or $GLOBALS['showOther']=='') { + $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]['showClass/showOther'] ; + $GLOBALS['status']=0; + } + $string .='$v) { - if($v['1'] == '') { - $string .= 'public $'.$k." = '".$v[0]."'; - "; - }else{ - $string .= 'public $'.$k." = '".$v[0]."'; //".$v[1]." - "; - } - if($GLOBALS['komentar'][$v[2]] != ''){ - $string .= ' + } + foreach ($this as $k => $v) { + if ($v['1'] == '') { + $string .= 'public $'.$k." = '".$v[0]."'; + "; + } else { + $string .= 'public $'.$k." = '".$v[0]."'; //".$v[1]." + "; + } + if ($GLOBALS['komentar'][$v[2]] != '') { + $string .= ' /*'.$GLOBALS['komentar'][$v[2]].'*/ '; - } - } - if($addclass!='') { - $string .=' -'.$addclass.'';} - $string .=" + } + } + if ($addclass!='') { + $string .=' +'.$addclass.''; + } + $string .=" }";$string .=" -";} - if($GLOBALS['showOther']==1) { -if (isset($GLOBALS['komentar'][0])) { - $string .= '/*'.$GLOBALS['komentar'][0].'*/'; - } -foreach ($this as $k=>$v) { - if($v['1'] == '') { - $string .= ' +"; + } + if ($GLOBALS['showOther']==1) { + if (isset($GLOBALS['komentar'][0])) { + $string .= '/*'.$GLOBALS['komentar'][0].'*/'; + } + foreach ($this as $k => $v) { + if ($v['1'] == '') { + $string .= ' $'.$k.' = "'.$v[0].'"; '; - }else{ - $string .= ' + } else { + $string .= ' $'.$k.' = "'.$v[0].'"; //'.$v[1]; -if($GLOBALS['komentar'][$v[2]] != ''){ - $string .= ' + if ($GLOBALS['komentar'][$v[2]] != '') { + $string .= ' /*'.$GLOBALS['komentar'][$v[2]].'*/'; - } - } + } + } + } + } + if ($addnoclass!='') { + $string .=' -} -} -if($addnoclass!='') { -$string .=' - -'.$addnoclass.''; } -$string .=" +'.$addnoclass.''; + } + $string .=" ?>"; - return $string; - } - } - - function comment($a) { - if($$GLOBALS['status']!=0) { - $GLOBALS['komentar'][''.$GLOBALS['stevilo'].''] = $a; - } - } - - function toFile($file,$data) { - if($GLOBALS['status']!=0) { - $fd = fopen ($file , "w") or $statusek=0; - if($statusek==0) { - $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]["can't open"]; - $GLOBALS['status']=0; - } - fwrite($fd, $data); - fclose($fd) ; - - $fd = fopen ($file , "r") or $statusek2=0; - if($statusek2==0) { - $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]["can't open"]; - $GLOBALS['status']=0; - } - $data2=fread ($fd , filesize ($file)); - if($data==$data2) { - $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]["ok"]; - $GLOBALS['status']=1; - } - fclose($fd) ; - } - } - - function status() { - return $GLOBALS['status']; - } - - function status_message() { - return $GLOBALS['status_message']; - } + return $string; + } + } + + public function comment($a) + { + if ($$GLOBALS['status']!=0) { + $GLOBALS['komentar'][''.$GLOBALS['stevilo'].''] = $a; + } + } + + public function toFile($file, $data) + { + if ($GLOBALS['status']!=0) { + $fd = fopen($file, "w") or $statusek=0; + if ($statusek==0) { + $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]["can't open"]; + $GLOBALS['status']=0; + } + fwrite($fd, $data); + fclose($fd) ; + + $fd = fopen($file, "r") or $statusek2=0; + if ($statusek2==0) { + $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]["can't open"]; + $GLOBALS['status']=0; + } + $data2=fread($fd, filesize($file)); + if ($data==$data2) { + $GLOBALS['status_message']=$GLOBALS[$GLOBALS['language']]["ok"]; + $GLOBALS['status']=1; + } + fclose($fd) ; + } + } + + public function status() + { + return $GLOBALS['status']; + } + + public function status_message() + { + return $GLOBALS['status_message']; + } } -?>