Commits vergleichen

...

5 Commits

Autor SHA1 Nachricht Datum
o.pinke 6847130805 add new methods, cleanup, PHP8 fixes 2023-02-17 15:17:20 +01:00
o.pinke 44382f8da0 increase CL version 2023-02-17 15:14:57 +01:00
o.pinke 965c7054f4 increase CL version 2023-02-17 15:14:30 +01:00
o.pinke 97a3370258 remove pear stuff, fix php8.x issues 2023-02-17 15:13:58 +01:00
o.pinke 9367766e7d remove old php5 support 2023-02-17 15:10:36 +01:00
11 geänderte Dateien mit 156 neuen und 1513 gelöschten Zeilen

Datei anzeigen

@ -144,8 +144,7 @@ class cHTMLInputSelectElement extends cHTMLSelectElement {
*
* @return int Number of items added
* */
function addCategories($iMaxLevel = 0, $bColored = false, $bCatVisible = true, $bCatPublic = true,
$bWithArt = false, $bArtOnline = true) {
function addCategories($iMaxLevel = 0, $bColored = false, $bCatVisible = true, $bCatPublic = true, $bWithArt = false, $bArtOnline = true) {
global $cfg, $client, $lang;
$oDB = new DB_Contenido;
@ -259,27 +258,18 @@ class cHTMLInputSelectElement extends cHTMLSelectElement {
}
}
/**
* Selects specified elements as selected
*
* @param array $aElements Array with "values" of the cHTMLOptionElement to set
*
* @return none
*/
function setSelected($aElements) {
if (is_array($this->_options) && is_array($aElements)) {
foreach ($this->_options as $sKey => $oOption) {
if (in_array($oOption->getAttribute("value"), $aElements)) {
$oOption->setSelected(true);
$this->_options[$sKey] = $oOption;
} else {
$oOption->setSelected(false);
$this->_options[$sKey] = $oOption;
}
}
}
public function addFiles($sPath) {
$iCount = 0;
$aFiles = cDirHandler::read($sPath);
asort($aFiles);
$iCounter = count($this->_options);
foreach ($aFiles as $sValue) {
$oOption = new cHTMLOptionElement($sValue, $sValue);
$this->addOptionElement($iCounter, $oOption);
$iCounter++;
}
return count($aFiles);
}
}
class UI_Config_Table {
@ -302,16 +292,24 @@ class UI_Config_Table {
var $_sColorLight;
var $_sColorDark;
/**
*
* @var type
*/
protected $_iRowCnt = 0;
function __construct() {
global $cfg;
$cfg = cRegistry::getConfig();
$this->_sPadding = 2;
$this->_sBorder = 0;
$this->_sBorderColor = $cfg['color']['table_border'];
$this->_sTplCellCode = ' <td align="{ALIGN}" valign="{VALIGN}" class="{CLASS}" colspan="{COLSPAN}" style="{EXTRA}white-space:nowrap;" nowrap="nowrap">{CONTENT}</td>' . "\n";
$this->_sBorderColor = cRegistry::getConfigValue('color', 'table_border');
$this->_sTplCellCode = '<td align="{ALIGN}" valign="{VALIGN}" class="{CLASS}" colspan="{COLSPAN}" style="{EXTRA}white-space:nowrap;" nowrap="nowrap">' . "\n"
. '{CONTENT}' . "\n"
. '</td>' . "\n";
$this->_sTplTableFile = $cfg['path']['contenido'] . $cfg['path']['templates'] . $cfg['templates']['generic_list'];
$this->_sColorLight = $cfg['color']['table_light'];
$this->_sColorDark = $cfg['color']['table_dark'];
$this->_sColorLight = cRegistry::getConfigValue('color', 'table_light');
$this->_sColorDark = cRegistry::getConfigValue('color', 'table_dark');
}
function setCellTemplate($sCode) {
@ -417,8 +415,37 @@ class UI_Config_Table {
return $sSkript;
}
function render($bPrint = false) {
$oTable = new Template;
/**
* increase row counter
*/
public function nextRow() {
$this->_iRowCnt++;
}
/**
* get current row count
*
* @return int row count
*/
public function getRowCount() : int {
return $this->_iRowCnt;
}
public function setRowCell(int $iCell, $mContent) {
$this->setCell($this->_iRowCnt, $iCell, $mContent);
}
public function setRowBorder(string $sWhich = 'bottom') {
$sStyle = '';
switch ($sWhich) {
case 'bottom':
$this->setRowExtra($this->_iRowCnt, 'border-bottom: 1px solid silver;');
break;
}
}
public function render($bPrint = false) {
$oTable = new Template();
$oTable->reset();
$oTable->set('s', 'CELLPADDING', $this->_sPadding);
@ -437,6 +464,8 @@ class UI_Config_Table {
$iCount = 0;
foreach ($aCells as $sCell => $sData) {
$sData = $this->_processContentData($sData);
$iCount++;
$sTplCell = $this->_sTplCellCode;
@ -525,4 +554,57 @@ class UI_Config_Table {
}
}
}
/**
* returns different types of content data as string
* you can use
* - string
* - object, needs to have a render method
* - array of objects and/or strings
*
* @author Ortwin Pinke
* @since 2.3.0
*
*
* @param mixed $mData
* @return string
*/
protected function _processContentData($mData): string {
if (is_string($mData)) {
return $mData;
}
$sData = '';
if (is_array($mData) && count($mData) > 0) {
foreach ($mData as $mElement) {
if (is_string($mElement)) {
$sData .= $mElement;
continue;
}
$sData .= $this->_renderObject($mElement);
}
} else {
$sData = $this->_renderObject($mData);
}
return $sData;
}
/**
* Renders an object using its render method
*
* @author Ortwin Pinke
* @since 2.3.0
*
* @param type $oObject
* @return string rendered string from object | empty string
*/
protected function _renderObject($oObject): string {
$sReturn = '';
if (is_object($oObject) && method_exists($oObject, 'render')) {
$sReturn = $oObject->render();
}
return $sReturn;
}
}

Datei anzeigen

@ -20,11 +20,7 @@
// security check
defined('CON_FRAMEWORK') or die('Illegal call');
/*
if (!class_exists("HTML_Common2")) {
cInclude("pear", "HTML/Common2.php");
}
*/
/* Global ID counter */
$cHTMLIDCount = 0;

Datei anzeigen

@ -293,6 +293,4 @@ class InUseItem extends Item
$this->loadByPrimaryKey($mId);
}
}
}
?>
}

Datei-Diff unterdrückt, da er zu groß ist Diff laden

Datei anzeigen

@ -209,7 +209,11 @@ class Template {
if (!is_file($template)) {
$content = & $template; //template is a string (it is a reference to save memory!!!)
} else {
$content = implode("", file($template)); //template is a file
if(cFileHandler::readable($template)) {
$content = implode("", file($template)); //template is a file
} else {
return $template;
}
}
$content = (($note) ? "<!-- Generated by ConLite " . $cfg['version'] . "-->\n" : "") . $content;

Datei anzeigen

@ -2052,57 +2052,6 @@ function notifyOnError($errortitle, $errormessage) {
}
}
function cIDNAEncode($sourceEncoding, $string) {
if (extension_loaded("iconv")) {
cInclude('pear', 'Net/IDNA.php');
$idn = Net_IDNA :: getInstance();
$string = iconv("UTF-8", $sourceEncoding, $string);
$string = $idn->encode($string);
return ($string);
}
if (extension_loaded("recode")) {
cInclude('pear', 'Net/IDNA.php');
$idn = Net_IDNA :: getInstance();
$string = $idn->decode($string);
$string = recode_string("UTF-8.." . $sourceEncoding, $string);
return $string;
}
return $string;
}
function cIDNADecode($targetEncoding, $string) {
if (extension_loaded("iconv")) {
cInclude('pear', 'Net/IDNA.php');
$idn = Net_IDNA :: getInstance();
$string = $idn->decode($string);
$string = iconv($targetEncoding, "UTF-8", $string);
return ($string);
}
if (extension_loaded("recode")) {
cInclude('pear', 'Net/IDNA.php');
$idn = Net_IDNA :: getInstance();
$string = recode_string($targetEncoding . "..UTF-8", $string);
$string = $idn->decode($string);
return $string;
}
return $string;
}
/**
* Checks for a named key of an array, pushes it if not set with a default value
*

Datei anzeigen

@ -233,101 +233,6 @@ if (!isset($idcat))
$idcat = 0;
if (!isset($action))
$action = 0;
/*
function buildTree(&$rootItem, &$items) {
global $nextItem, $perm, $tmp_area;
while ($item_list = each($items)) {
list($key, $item) = $item_list;
unset($newItem);
$bCheck = false;
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_newtree");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_newcat");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_makevisible");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_makepublic");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_deletecat");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_moveupcat");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_movedowncat");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_movesubtree");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action($tmp_area, "str_renamecat");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_area_action("str_tplcfg", "str_tplcfg");
}
if (!$bCheck) {
$bCheck = $perm->have_perm_item($tmp_area, $item['idcat']);
}
if ($bCheck) {
$newItem = new TreeItem($item['name'], $item['idcat'], true);
} else {
$newItem = new TreeItem($item['name'], $item['idcat'], false);
}
$newItem->collapsed_icon = 'images/open_all.gif';
$newItem->expanded_icon = 'images/close_all.gif';
$newItem->custom['idtree'] = $item['idtree'];
$newItem->custom['level'] = $item['level'];
$newItem->custom['idcat'] = $item['idcat'];
$newItem->custom['idtree'] = $item['idtree'];
$newItem->custom['parentid'] = $item['parentid'];
$newItem->custom['alias'] = $item['alias'];
$newItem->custom['preid'] = $item['preid'];
$newItem->custom['postid'] = $item['postid'];
$newItem->custom['visible'] = $item['visible'];
$newItem->custom['idtplcfg'] = $item['idtplcfg'];
$newItem->custom['public'] = $item['public'];
if ($perm->have_perm_item("str", $item['idcat'])) {
$newItem->custom['forcedisplay'] = 1;
}
if (array_key_exists($key + 1, $items)) {
$nextItem = $items[$key + 1];
} else {
$nextItem = 0;
}
if (array_key_exists($key - 1, $items)) {
$lastItem = $items[$key - 1];
} else {
$lastItem = 0;
}
$rootItem->addItem($newItem);
if ($nextItem['level'] > $item['level']) {
$oldRoot = $rootItem;
buildTree($newItem, $items);
$rootItem = $oldRoot;
}
if ($nextItem['level'] < $item['level']) {
return;
}
}
}
*
*/
function buildTree(&$rootItem, $itemsIterator) {
global $nextItem, $perm, $tmp_area;

Datei anzeigen

@ -71,7 +71,7 @@ if (!defined('CL_ENVIRONMENT')) {
*/
if (!defined('CL_VERSION')) {
define('CL_VERSION', '2.3.0 RC');
define('CL_VERSION', '3.0.0 RC');
}

Datei anzeigen

@ -1,4 +1,5 @@
<?php
/**
* Project:
* ConLite CMS
@ -19,37 +20,32 @@
* @link http://www.contenido.org
*
*/
/**
* No direct call
*/
if(!defined('CON_FRAMEWORK')) {
if (!defined('CON_FRAMEWORK')) {
die('Illegal call');
}
// Compatibility for php < 5.3 using closures or not, @todo remove if we only support PHP >= 5.3
if(version_compare(PHP_VERSION, "5.3", "<")) {
cInclude("plugins", "chains/createmetatags/includes/keyword_density_php52.php");
} else {
cInclude("plugins", "chains/createmetatags/includes/keyword_density.php");
}
cInclude("plugins", "chains/createmetatags/includes/keyword_density.php");
cInclude("plugins", "chains/createmetatags/classes/class.metatag.creator.html5.php");
function cecCreateMetatags($metatags) {
global $cfg, $lang, $idart, $client, $cfgClient, $idcat, $idartlang;
$bIsHTML5 = ((getEffectiveSetting('generator', 'html5', 'false') == 'false') ? false : true);
if($bIsHTML5) {
$bIsHTML5 = ((getEffectiveSetting('generator', 'html5', 'false') == 'false') ? false : true);
if ($bIsHTML5) {
$aConfig = array(
'cachetime' => 3600,
'cachedir' => $cfgClient[$client]['path']['frontend'] . "cache/"
'cachedir' => $cfgClient[$client]['path']['frontend'] . "cache/"
);
$oHtml5MetaCreator = new MetaTagCreatorHtml5($metatags, $aConfig);
$oHtml5MetaCreator = new MetaTagCreatorHtml5($metatags, $aConfig);
return $oHtml5MetaCreator->generateMetaTags();
}
}
//Basic settings
$cachetime = 3600; // measured in seconds
@ -59,8 +55,8 @@ function cecCreateMetatags($metatags) {
$metatags = array();
}
$hash = 'metatag_'.md5($idart.'/'.$lang);
$cachefilename = $cachedir.$hash.'.tmp';
$hash = 'metatag_' . md5($idart . '/' . $lang);
$cachefilename = $cachedir . $hash . '.tmp';
#Check if rebuilding of metatags is necessary
$reload = true;
@ -70,7 +66,7 @@ function cecCreateMetatags($metatags) {
if (file_exists($cachefilename)) {
$fileexists = true;
$diff = time() - filemtime($cachefilename);
$diff = time() - filemtime($cachefilename);
if ($diff > $cachetime) {
$reload = true;
@ -84,7 +80,7 @@ function cecCreateMetatags($metatags) {
$db = new DB_ConLite();
#Get encoding
$sql = "SELECT * FROM ".$cfg['tab']['lang']." WHERE idlang=".(int)$lang;
$sql = "SELECT * FROM " . $cfg['tab']['lang'] . " WHERE idlang=" . (int) $lang;
$db->query($sql);
if ($db->next_record()) {
$sEncoding = strtoupper($db->f('encoding'));
@ -95,12 +91,12 @@ function cecCreateMetatags($metatags) {
#Get idcat of homepage
$sql = "SELECT a.idcat
FROM
".$cfg['tab']['cat_tree']." AS a,
".$cfg['tab']['cat_lang']." AS b
" . $cfg['tab']['cat_tree'] . " AS a,
" . $cfg['tab']['cat_lang'] . " AS b
WHERE
(a.idcat = b.idcat) AND
(b.visible = 1) AND
(b.idlang = ".Contenido_Security::toInteger($lang).")
(b.idlang = " . Contenido_Security::toInteger($lang) . ")
ORDER BY a.idtree LIMIT 1";
$db->query($sql);
@ -112,7 +108,7 @@ function cecCreateMetatags($metatags) {
$availableTags = conGetAvailableMetaTagTypes();
#Get first headline and first text for current article
$oArt = new Article ($idart, $client, $lang);
$oArt = new Article($idart, $client, $lang);
#Set idartlang, if not set
if ($idartlang == '') {
@ -140,7 +136,7 @@ function cecCreateMetatags($metatags) {
}
$sHeadline = strip_tags($sHeadline);
$sHeadline = substr(str_replace(chr(13).chr(10),' ',$sHeadline),0,100);
$sHeadline = substr(str_replace(chr(13) . chr(10), ' ', $sHeadline), 0, 100);
$arrText1 = $oArt->getContent("html");
$arrText2 = $oArt->getContent("text");
@ -163,19 +159,19 @@ function cecCreateMetatags($metatags) {
}
$sText = strip_tags(urldecode($sText));
$sText = keywordDensity ('', $sText);
$sText = keywordDensity('', $sText);
//Get metatags for homeapge
$arrHomepageMetaTags = array();
$sql = "SELECT startidartlang FROM ".$cfg["tab"]["cat_lang"]." WHERE (idcat=".Contenido_Security::toInteger($idcat_homepage).") AND(idlang=".Contenido_Security::toInteger($lang).")";
$sql = "SELECT startidartlang FROM " . $cfg["tab"]["cat_lang"] . " WHERE (idcat=" . Contenido_Security::toInteger($idcat_homepage) . ") AND(idlang=" . Contenido_Security::toInteger($lang) . ")";
$db->query($sql);
if($db->next_record()){
if ($db->next_record()) {
$iIdArtLangHomepage = $db->f('startidartlang');
#get idart of homepage
$sql = "SELECT idart FROM ".$cfg["tab"]["art_lang"]." WHERE idartlang =".Contenido_Security::toInteger($iIdArtLangHomepage);
$sql = "SELECT idart FROM " . $cfg["tab"]["art_lang"] . " WHERE idartlang =" . Contenido_Security::toInteger($iIdArtLangHomepage);
$db->query($sql);
@ -186,10 +182,10 @@ function cecCreateMetatags($metatags) {
$t1 = $cfg["tab"]["meta_tag"];
$t2 = $cfg["tab"]["meta_type"];
$sql = "SELECT ".$t1.".metavalue,".$t2.".metatype FROM ".$t1.
" INNER JOIN ".$t2." ON ".$t1.".idmetatype = ".$t2.".idmetatype WHERE ".
$t1.".idartlang =".$iIdArtLangHomepage.
" ORDER BY ".$t2.".metatype";
$sql = "SELECT " . $t1 . ".metavalue," . $t2 . ".metatype FROM " . $t1 .
" INNER JOIN " . $t2 . " ON " . $t1 . ".idmetatype = " . $t2 . ".idmetatype WHERE " .
$t1 . ".idartlang =" . $iIdArtLangHomepage .
" ORDER BY " . $t2 . ".metatype";
$db->query($sql);
@ -197,7 +193,7 @@ function cecCreateMetatags($metatags) {
$arrHomepageMetaTags[$db->f("metatype")] = $db->f("metavalue");
}
$oArt = new Article ($iIdArtHomepage, $client, $lang);
$oArt = new Article($iIdArtHomepage, $client, $lang);
$arrHomepageMetaTags['pagetitle'] = $oArt->getField('title');
}
@ -206,12 +202,12 @@ function cecCreateMetatags($metatags) {
foreach ($availableTags as $key => $value) {
$metavalue = conGetMetaValue($idartlang, $key);
if (strlen($metavalue) == 0){
if (strlen($metavalue) == 0) {
//Add values for metatags that don't have a value in the current article
switch(strtolower($value["name"])){
switch (strtolower($value["name"])) {
case 'author':
//Build author metatag from name of last modifier
$oArt = new Article ($idart, $client, $lang);
$oArt = new Article($idart, $client, $lang);
$lastmodifier = $oArt->getField("modifiedby");
$oUser = new User();
$oUser->loadUserByUserID(md5($lastmodifier));
@ -224,7 +220,7 @@ function cecCreateMetatags($metatags) {
break;
case 'date':
//Build date metatag from date of last modification
$oArt = new Article ($idart, $client, $lang);
$oArt = new Article($idart, $client, $lang);
$lastmodified = $oArt->getField("lastmodified");
$iCheck = CheckIfMetaTagExists($metatags, 'date');
@ -260,7 +256,6 @@ function cecCreateMetatags($metatags) {
// save metatags in cache file
file_put_contents($cachefilename, serialize($metatags));
} else {
#Get metatags from file system cache
$metatags = unserialize(file_get_contents($cachefilename));
@ -269,7 +264,6 @@ function cecCreateMetatags($metatags) {
return $metatags;
}
/**
* Checks if the metatag allready exists inside the metatag list.
*
@ -295,4 +289,5 @@ function CheckIfMetaTagExists($arrMetatags, $sCheckForMetaTag) {
// metatag doesn't exists, return next position
return count($arrMetatags);
}
?>

Datei anzeigen

@ -1,221 +0,0 @@
<?php
// security check
defined('CON_FRAMEWORK') or die('Illegal call');
/**
* Compare int values
*
* @param int $a
* @param int $b
* @return int 0 for equal, 1 for higher and -1 for lower
*/
function __cmp($a, $b) {
if ($a == $b) return 0;
return ($a > $b) ? -1 : 1;
}
/**
*
* @param array $singlewordcounter
* @param int $maxKeywords
* @return array Array with valued keywords
*/
function stripCount($singlewordcounter, $maxKeywords = 15) {
// strip all with only 1
$tmp = array();
$result = array();
$tmpToRemove = 1;
foreach ($singlewordcounter as $key => $value) {
if ($value > $tmpToRemove) {
$tmp[$key] = $value;
}
}
if (sizeof($tmp) <= $maxKeywords) {
foreach ($tmp as $key => $value) {
$result[] = $key;
}
} else {
$dist = array();
foreach ($tmp as $key => $value) {
$dist[$value]++;
}
uksort($dist, "__cmp");
reset($dist);
$count = 0;
$resultset = array();
$useQuantity = array();
foreach ($dist as $key => $value) {
$_count = $count + $value;
if ($_count <= $maxKeywords) {
$count += $value;
$useQuantity[] = $key;
} else {
break;
}
}
// run all keywords and select by quantities to use
foreach ($singlewordcounter as $key => $value) {
if (in_array($value, $useQuantity)) {
$result[] = $key;
}
}
}
return $result;
}
/**
* Generate keywords from content
*
* @version 1.0
* @since 2.0.0
* @author Ortwin Pinke <o.pinke@conlite.org>
*
* @param string $sHeadline
* @param string $sText
* @param string $sEncoding
* @param int $iMinLen
* @return mixed commaseparated string of keywords or false
*/
function keywordDensity($sHeadline, $sText, $sEncoding = "UTF-8", $iMinLen = 5) {
global $aAllWords;
$sHeadline = strip_tags($sHeadline);
$sText = strip_tags($sText);
$sText = clHtmlEntityDecode($sText, ENT_QUOTES, $sEncoding);
$aSingleWordHeadline = str_word_count($sHeadline, 1);
// double array for higher valenz of headline
$aSingleWordHeadline = array_merge($aSingleWordHeadline,$aSingleWordHeadline);
$aSingleWordHeadline = array_count_values($aSingleWordHeadline);
$aSingleWordText = str_word_count($sText, 1);
$aSingleWordText = array_count_values($aSingleWordText);
$aAllWords = array_merge($aSingleWordHeadline, $aSingleWordText);
array_walk($aAllWords, create_function('&$n, $key, $iLen', '
global $aAllWords;
if(strlen($key) < $iLen || clIsStopWord($key)) {
unset($aAllWords[$key]);
}'), $iMinLen);
arsort($aAllWords, SORT_NUMERIC);
$aAllWords = stripCount($aAllWords);
if(is_array($aAllWords)) {
return implode(', ', $aAllWords);
}
return false;
}
/**
* Check keyword against stopword list
*
* @version 1.0
* @since 2.0.0
* @author Ortwin Pinke <o.pinke@conlite.org>
* @todo move stopwords to sqlite
*
* @global int $lang
* @global array $encoding
* @param string $sWord
* @return boolean
*/
function clIsStopWord($sWord) {
global $lang, $encoding;
$aStopWords = array();
$aStopWords['de_DE'] = array("aber", "als", "am", "an", "auch", "auf", "aus", "bei", "bin",
"bis", "bist", "da", "dadurch", "daher", "darum", "das", "daß", "dass", "dein",
"deine", "dem", "den", "der", "des", "dessen", "deshalb", "die", "dies", "dieser", "dieses",
"doch", "dort", "du", "durch", "ein", "eine", "einem", "einen", "einer", "eines", "er",
"es", "euer", "eure", "für", "hatte", "hatten", "hattest", "hattet", "hier", "hinter",
"ich", "ihr", "ihre", "im", "in", "ist", "ja", "jede", "jedem", "jeden", "jeder", "jedes",
"jener", "jenes", "jetzt", "kann", "kannst", "können", "könnt", "machen", "mein",
"meine", "mit", "muß", "mußt", "musst", "müssen", "müßt", "nach", "nachdem", "nein",
"nicht", "nun", "oder", "seid", "sein", "seine", "sich", "sie",
"sind", "soll", "sollen", "sollst", "sollt", "sonst", "soweit", "sowie", "und", "unser",
"unsere", "unter", "vom", "von", "vor", "wann", "warum", "was", "weiter", "weitere", "wenn",
"wer", "werde", "werden", "werdet", "weshalb", "wie", "wieder", "wieso", "wir", "wird",
"wirst", "wo", "woher", "wohin", "zu", "zum", "zur", "über");
$aStopWords['en_EN'] = $aStopWords['en_US'] = array("a", "able", "about", "above", "abst",
"accordance", "according", "accordingly", "across", "act", "actually", "added", "adj",
"affected", "affecting", "affects", "after", "afterwards", "again", "against", "ah", "all",
"almost", "alone", "along", "already", "also", "although", "always", "am", "among",
"amongst", "an", "and", "announce", "another", "any", "anybody", "anyhow", "anymore",
"anyone", "anything", "anyway", "anyways", "anywhere", "apparently", "approximately",
"are", "aren", "arent", "arise", "around", "as", "aside", "ask", "asking", "at", "auth",
"available", "away", "awfully", "b", "back", "be", "became", "because", "become", "becomes",
"becoming", "been", "before", "beforehand", "begin", "beginning", "beginnings", "begins",
"behind", "being", "believe", "below", "beside", "besides", "between", "beyond", "biol",
"both", "brief", "briefly", "but", "by", "c", "ca", "came", "can", "cannot", "can't",
"cause", "causes", "certain", "certainly", "co", "com", "come", "comes", "contain",
"containing", "contains", "could", "couldnt", "d", "date", "did", "didn't", "different",
"do", "does", "doesn't", "doing", "done", "don't", "down", "downwards", "due", "during",
"e", "each", "ed", "edu", "effect", "eg", "eight", "eighty", "either", "else", "elsewhere",
"end", "ending", "enough", "especially", "et", "et-al", "etc", "even", "ever", "every",
"everybody", "everyone", "everything", "everywhere", "ex", "except", "f", "far", "few",
"ff", "fifth", "first", "five", "fix", "followed", "following", "follows", "for", "former",
"formerly", "forth", "found", "four", "from", "further", "furthermore", "g", "gave", "get",
"gets", "getting", "give", "given", "gives", "giving", "go", "goes", "gone", "got", "gotten",
"h", "had", "happens", "hardly", "has", "hasn't", "have", "haven't", "having", "he", "hed",
"hence", "her", "here", "hereafter", "hereby", "herein", "heres", "hereupon", "hers",
"herself", "hes", "hi", "hid", "him", "himself", "his", "hither", "home", "how", "howbeit",
"however", "hundred", "i", "id", "ie", "if", "i'll", "im", "immediate", "immediately",
"importance", "important", "in", "inc", "indeed", "index", "information", "instead", "into",
"invention", "inward", "is", "isn't", "it", "itd", "it'll", "its", "itself", "i've", "j",
"just", "k", "keep", "keeps", "kept", "kg", "km", "know", "known", "knows", "l", "largely",
"last", "lately", "later", "latter", "latterly", "least", "less", "lest", "let", "lets",
"like", "liked", "likely", "line", "little", "'ll", "look", "looking", "looks", "ltd", "m",
"made", "mainly", "make", "makes", "many", "may", "maybe", "me", "mean", "means", "meantime",
"meanwhile", "merely", "mg", "might", "million", "miss", "ml", "more", "moreover", "most",
"mostly", "mr", "mrs", "much", "mug", "must", "my", "myself", "n", "na", "name", "namely",
"nay", "nd", "near", "nearly", "necessarily", "necessary", "need", "needs", "neither",
"never", "nevertheless", "new", "next", "nine", "ninety", "no", "nobody", "non", "none",
"nonetheless", "noone", "nor", "normally", "nos", "not", "noted", "nothing", "now", "nowhere",
"o", "obtain", "obtained", "obviously", "of", "off", "often", "oh", "ok", "okay", "old",
"omitted", "on", "once", "one", "ones", "only", "onto", "or", "ord", "other", "others",
"otherwise", "ought", "our", "ours", "ourselves", "out", "outside", "over", "overall", "owing",
"own", "p", "page", "pages", "part", "particular", "particularly", "past", "per", "perhaps",
"placed", "please", "plus", "poorly", "possible", "possibly", "potentially", "pp", "predominantly",
"present", "previously", "primarily", "probably", "promptly", "proud", "provides", "put",
"q", "que", "quickly", "quite", "qv", "r", "ran", "rather", "rd", "re", "readily", "really",
"recent", "recently", "ref", "refs", "regarding", "regardless", "regards", "related",
"relatively", "research", "respectively", "resulted", "resulting", "results", "right",
"run", "s", "said", "same", "saw", "say", "saying", "says", "sec", "section", "see",
"seeing", "seem", "seemed", "seeming", "seems", "seen", "self", "selves", "sent", "seven",
"several", "shall", "she", "shed", "she'll", "shes", "should", "shouldn't", "show",
"showed", "shown", "showns", "shows", "significant", "significantly", "similar", "similarly",
"since", "six", "slightly", "so", "some", "somebody", "somehow", "someone", "somethan",
"something", "sometime", "sometimes", "somewhat", "somewhere", "soon", "sorry", "specifically",
"specified", "specify", "specifying", "still", "stop", "strongly", "sub", "substantially",
"successfully", "such", "sufficiently", "suggest", "sup", "sure", "t", "take", "taken",
"taking", "tell", "tends", "th", "than", "thank", "thanks", "thanx", "that", "that'll",
"thats", "that've", "the", "their", "theirs", "them", "themselves", "then", "thence",
"there", "thereafter", "thereby", "thered", "therefore", "therein", "there'll", "thereof",
"therere", "theres", "thereto", "thereupon", "there've", "these", "they", "theyd", "they'll",
"theyre", "they've", "think", "this", "those", "thou", "though", "thoughh", "thousand",
"throug", "through", "throughout", "thru", "thus", "til", "tip", "to", "together", "too",
"took", "toward", "towards", "tried", "tries", "truly", "try", "trying", "ts", "twice",
"two", "u", "un", "under", "unfortunately", "unless", "unlike", "unlikely", "until", "unto",
"up", "upon", "ups", "us", "use", "used", "useful", "usefully", "usefulness", "uses", "using",
"usually", "v", "value", "various", "'ve", "very", "via", "viz", "vol", "vols", "vs", "w",
"want", "wants", "was", "wasn't", "way", "we", "wed", "welcome", "we'll", "went", "were",
"weren't", "we've", "what", "whatever", "what'll", "whats", "when", "whence", "whenever",
"where", "whereafter", "whereas", "whereby", "wherein", "wheres", "whereupon", "wherever",
"whether", "which", "while", "whim", "whither", "who", "whod", "whoever", "whole", "who'll",
"whom", "whomever", "whos", "whose", "why", "widely", "willing", "wish", "with", "within",
"without", "won't", "words", "world", "would", "wouldn't", "www", "x", "y", "yes", "yet",
"you", "youd", "you'll", "your", "youre", "yours", "yourself", "yourselves", "you've", "z", "zero");
if(is_int($lang) && is_array($encoding)) {
$sUseEnc = $encoding[$lang];
if(empty($sUseEnc) || !array_key_exists($sUseEnc, $aStopWords)) {
$sUseEnc = "de_DE";
}
}
if(in_array(utf8_encode($sWord), $aStopWords['de_DE'])) {
return true;
}
return false;
}
?>

Datei anzeigen

@ -39,7 +39,7 @@ define('C_SETUP_STEPWIDTH', 28);
define('C_SETUP_STEPHEIGHT', 28);
define('C_SETUP_MIN_PHP_VERSION', '7.4.0');
define('C_SETUP_MAX_PHP_VERSION', '8.3.0');
define('C_SETUP_VERSION', '2.3.0');
define('C_SETUP_VERSION', '3.0.0');
$sDefLocalPath = dirname(__FILE__).DIRECTORY_SEPARATOR.'defines.local.php';
if(file_exists($sDefLocalPath)) {