$info__){ $tree__[$info__->_id]['name'] = $info__->_name; $tree__[$info__->_id]['catname'] = $info__->_catname; $tree__[$info__->_id]['pid'] = $_start; $tree__[$info__->_id]['lang'] = $_lang; $tree__[$info__->_id]['uri'] = ($_url?$_url .'/':'/').cleanUrl($info__->_catname).'/'.(cleanUrl($info__->_name)?cleanUrl($info__->_name):'index').'.html'; if (!cleanUrl($info__->_catname)){ unset ($tree__[$info__->_id]); } generate_articles_tree($info__->_id, $_lang, $_url.'/'.cleanUrl($info__->_catname)); } } function cleanUrl($_word){ //return $_word; $word = str_replace( array('ä','ö','ü','Ä','Ö','Ü','ß'), array('ae','oe','ue','Ae','Oe','Ue','ss'), $_word ); $word = preg_replace('/[^a-zA-Z0-9_-]/', ' ', $word); $word = str_replace(' ', '_', trim($word)); $word = strtolower($word); while(strstr($word, '__')) $word = str_replace('__', '_', $word); return $word; } function generate_tree(){ global $path__; if (in_path(15)){ $lang = 'en'; }else{ $lang = 'de'; } $sql = rexVarSql('SELECT id, name, catname FROM rex_artcile'); $i=0; $check__[]=0; while (sizeof($check__)>0){ for ($i=0; $icreate_function('$name', 'return rexRequestGetVar($name, "GET" );'), 'p'=>create_function('$name', 'return rexRequestGetVar($name, "POST" );'), 'c'=>create_function('$name', 'return rexRequestGetVar($name, "COOKIE" );'), 'e'=>create_function('$name', 'return rexRequestGetVar($name, "ENV" );'), 'r'=>create_function('$name', 'return rexRequestGetVar($name, "REQUEST");'), 'f'=>create_function('$name', 'return rexRequestGetVar($name, "FILES" );'), 's'=>create_function('$value', 'return (string)$value;'), 'i'=>create_function('$value', 'return (intval($value)!=$value ? floatval($value) : intval($value));'), 'b'=>create_function('$value', 'return (bool)$value;'), 'AS'=>create_function('$value', 'return addslashes($value);'), 'HT'=>create_function('$value', 'return htmlspecialchars($value);'), 'NL'=>create_function('$value', 'return nl2br($value);'), 'TR'=>create_function('$value', 'return trim($value);')/*, '_DAT'=>create_function('$value', 'return ($value=sscanf($value,"%d-%d-%d",&$y,&$m,&$d)*0+mktime(0,0,0,$m,$d,$y))>0?$value:time();')*/ ); $args = func_get_args (); $args = explode($VAR_DELIM, str_replace(array("\r","\n","\t", " "),'',implode($VAR_DELIM, $args))); $result = array(); $extra = ''; foreach($args as $key=>$value) { if ($value) { if (strpos($value, $EXTRA_DELIM)!==false) { list($name, $extra) = explode($EXTRA_DELIM, $value); if (!preg_match("/[gprcef]{1}/", $extra)) { $extra.="r"; } $args[$key] = $name; foreach($filters as $filter=>$func) { if (strpos($extra, $filter)!==false) { if (is_array($args[$key])) { array_walk($args[$key], create_function('&$v, $k, $func', '$v=$func($v);'), $func); } else { $args[$key] = $func($args[$key]); } } } } else { $args[$key] = rexRequestGetVar($value); } } if (preg_replace ("!([0-9]+)!e", "\$limit=\$1", $extra)) { if (isset ($limit)) { $args[$key] = substr ($args[$key], 0, $limit); unset ($limit); } } } return (strpos($extra, '!')!==false && (count($args)==1) ? pos($args) : $args); } function rexRequestGetVar($name, $OnlyMethod='REQUEST') { return rexRequestGetVarEx($name, $OnlyMethod); } function rexRequestGetVarEx($name, $OnlyMethod='REQUEST'){ $var_arr = '$_'.StrToUpper($OnlyMethod)."['$name']"; # eval("\$value = (isset($var_arr) ? $var_arr : NULL);"); if (($OnlyMethod=='FILES') && $value) { if ($value['error']>0) { $value = NULL; } else { $value['ext'] = substr(strstr($value['name'], "."), 1); } } # return is_array($value)?$value:stripslashes($value);//(get_magic_quotes_gpc() && is_string($value) ? stripslashes($value) : $value); } function rexVarSql_CallBack($m) { global $__re; if (!$__re) return "''"; $value = array_shift($__re); switch($m[0]{1}) { case 'n': /*number**/ return intval($value); case 's': /*string**/ return "'".addslashes($value)."'"; case 'w': /*without*/ return $value; case 'b': /*binary**/ return '0x'.bin2hex($value); case 'f': /*float***/ return floatval(str_replace(',','.',$value)); } } function rexVarSql() { global $__re; $__re = func_get_args(); $sql = array_shift($__re); return preg_replace_callback('/\?[nswbf]{1}/', 'rexVarSql_CallBack', $sql); } function in_path($_article_id){ if (!defined('REX_PATH')) return false; $path=REX_PATH; $path=explode('|', $path); global $article_id; if($_article_id==$article_id) return true; if (in_array($_article_id, $path)) return true; } function dbauto_generate_cache_file_name($_image_id, $_image_ext, $_image_crop, $_image_width, $_image_height){ return $file_name = $_image_id.'_'. md5($_image_crop.'_'. $_image_width.'_'. $_image_height).'.'.$_image_ext; } function dbauto_entry_image($_image_id, $_image_ext, $_image_crop=1, $_image_width="", $_image_height="", $_image_alt=""){ $cache_name = dbauto_generate_cache_file_name($_image_id, $_image_ext, $_image_crop, $_image_width, $_image_height); $generate_new = false; if (!is_file(DB_IMAGES_CACHE_PATH.$cache_name)) $generate_new = true; else{ if (!is_file(DB_IMAGES_UPLOAD_PATH.$_image_id.'.'.$_image_ext)) return; $c_file_time = filectime(DB_IMAGES_CACHE_PATH.$cache_name); $o_file_time = filectime(DB_IMAGES_UPLOAD_PATH.$_image_id.'.'.$_image_ext); if ($o_file_time > $c_file_time) $generate_new = true; } if ($generate_new){ return ''; } list($width, $height) = getimagesize(DB_IMAGES_CACHE_PATH.$cache_name); return ''.$_image_alt.''; } function rexFEUserIsLoggedIn(){ global $_SESSION; if (isset($_SESSION['tvsfeuser']['feuser']['id']) && $_SESSION['tvsfeuser']['feuser']['id']){ return $_SESSION['tvsfeuser']['feuser']; } return false; } function schultes_fe_merkzettel(){ list($func) = rexVarInput('func'); global $clang, $article_id, $_SESSION; if (!isset($_SESSION['mz']) || !is_array($_SESSION['mz'])){ $_SESSION['mz'] = array(); } switch ($func){ case "add" : { list($prod_id) = rexVarInput('prod_id'); $prod_id = (int) $prod_id; if ($prod_id) $_SESSION['mz'][$prod_id] = $prod_id; header('Location:index.php?article_id='.$article_id.'&clang='.$clang.'&msg=success'); exit; break; } case "del" : { list($prod_id) = rexVarInput('prod_id'); $prod_id = (int) $prod_id; if ($prod_id && isset($_SESSION['mz'][$prod_id])) unset($_SESSION['mz'][$prod_id]); header('Location:index.php?article_id='.$article_id.'&clang='.$clang.'&msg=success'); exit; break; } default : { if (sizeof($_SESSION['mz'])>0){ foreach($_SESSION['mz'] as $products_id){ $products_id = (int) $products_id; $_SESSION['mz'][$products_id] = $products_id; } //print_r($_SESSION['mz']); foreach ($_SESSION['mz'] as $art_id){ $art = OOArticle::getArticleById($art_id, $clang); if ($slice = OOArticleSlice::getFirstSliceForArticle($art->_id, $clang)){ if ($slice->getModuleId()==16){ $_mz_content[$art_id]['title'] = $slice->getValue(1); $_mz_content[$art_id]['content'] = $slice->getValue(2); $_mz_content[$art_id]['bild'] = $slice->getMedia(1); } while($slice = $slice->getNextSlice()){ if ($slice->getModuleId()==16){ $_mz_content[$art_id]['title'] = $slice->getValue(1); $_mz_content[$art_id]['content'] = $slice->getValue(2); $_mz_content[$art_id]['bild'] = $slice->getMedia(1); } } } } if (is_array($_mz_content)){ echo '
'; }else{ echo '
Ihr Merkzettel ist Leer.
'; } /* $sql = rexVarSql('SELECT products_id, products_image, products_name_de, products_name_es, products_k_description_de, products_k_description_es FROM rex_pro_product WHERE products_id IN (?w) AND products_active=?n AND '.($clang==0?'products_de':'products_es').'=?n ORDER BY products_seq ASC', implode(', ', $_SESSION['mz']), 1, 1); $res = mysql_query($sql); if (mysql_num_rows($res)>0){ echo '
'; }else{ echo '
Ihr Merkzettel ist Leer.
'; } break; } } } ?>0){ foreach ($service__ as $service){ $service = trim($service); $services__[my_strtoupper(mb_substr($service, 0, 1))][$service][] = $data__; } ksort($services__[my_strtoupper(mb_substr($service, 0, 1))]); } $hp__[$data__['udh_id']] = $data__; } ksort($services__); ksort($data_a_z__); ksort($data_ort__); list($show) = rexVarInput('show'); echo '
'; switch($show){ case 'item' : list($item_id) = rexVarInput('item_id'); if (isset($hp__[$item_id])){ echo '
'.$hp__[$item_id]['udh_title'].'
Therapieverfahren:
'.nl2br($hp__[$item_id]['udh_service']).'
'.($hp__[$item_id]['udh_str']?'
Adresse:
'.$hp__[$item_id]['udh_str'].'
':'').' '.($hp__[$item_id]['udh_plz']?'
Plz & Ort:
'.$hp__[$item_id]['udh_plz'].', '.$hp__[$item_id]['udh_ort'].'
':'').' '.($hp__[$item_id]['udh_tel']?'
Telefon:
'.$hp__[$item_id]['udh_tel'].'
':'').' '.($hp__[$item_id]['udh_fax']?'
Fax:
'.$hp__[$item_id]['udh_fax'].'
':'').' '.($hp__[$item_id]['udh_email']?'
E-mail:
'.$hp__[$item_id]['udh_email'].'
':'').' '.($hp__[$item_id]['udh_www']?'
Homepage:
'.$hp__[$item_id]['udh_www'].'
':'').'
'; } break; case 'ort' : if (sizeof($data_ort__)>0){ echo '
'; foreach($data_ort__ as $b=>$items__){ echo ''.$b.' '; } echo '
'; foreach($data_ort__ as $b=>$items__){ echo '

'.$b.'

'; if(sizeof($items__)>0){ foreach($items__ as $item){ echo ''; } } } echo '
'; } break; case 'service' : if (sizeof($services__)>0){ echo '
'; foreach($services__ as $b=>$items__){ echo ''.$b.' '; } echo '
'; foreach($services__ as $b=>$service__){ echo '

'.$b.'

'; if(sizeof($service__)>0){ foreach($service__ as $service => $items__){ echo '

'.$service.'

'; foreach($items__ as $item){ echo ''; } } } } echo '
'; } break; default : if (sizeof($data_a_z__)>0){ echo '
'; foreach($data_a_z__ as $b=>$items__){ echo ''.$b.' '; } echo '
'; foreach($data_a_z__ as $b=>$items__){ echo '

'.$b.'

'; if(sizeof($items__)>0){ foreach($items__ as $item){ echo ''; } } } echo '
'; } break; } } ?>getValue("art_keywords"); $meta_beschreibung = $this->getValue("art_description"); $article_text = $this->getArticle(); if (isset($_GET['print'])){ ?> Print Version: Mitglied werden :
'; } ?> Mitglied werden :