display->css; } $out .= ''; $out .='
'; if ($sxTopics) { $defaultview = mb_strtolower($sxTopics->display->defaultview); if ( ! $defaultview) $defaultview = 'static'; $out .= ( "\n"); } $out .= '
'; return $out; } public static function topics_exists($I18n) { if (file_exists(__DIR__ . '/../../config/topics/topics_' . $I18n . '.xml')) { return true; } if (file_exists(__DIR__ . '/../../config/topics/topics.xml')) { return true; } return false; } public static function dropdown_topics($I18n) { $out = ''; $xmlTopics = ''; $sxTopics = null; if (file_exists(__DIR__ . '/../../config/topics/topics_' . $I18n . '.xml')) $xmlTopics = __DIR__ . '/../../config/topics/topics_' . $I18n . '.xml'; if ($xmlTopics == '') { if (file_exists(__DIR__ . '/../../config/topics/topics.xml')) { $xmlTopics = __DIR__ . '/../../config/topics/topics.xml'; } } if ($xmlTopics == '') { return ''; } $jsTopics = 'null'; $maxdepth = 0; if (false !== $sxTopics = simplexml_load_file($xmlTopics)) { $jsTopics = self::topicsAsJS($sxTopics->topics, 0, $maxdepth); } $out .= ' '; $out .= '
' . _('boutton::chercher') . ' :
' . _('client::recherche: dans les categories') . '
'; for ($i = 0; $i <= $maxdepth; $i ++) { $out .= '

'; } $out .= '
'; return $out; } public static function history(appbox $appbox, $usr_id) { $conn = $appbox->get_connection(); $sql = "SELECT query from dsel where usr_id = :usr_id ORDER BY id DESC LIMIT 0,25"; $stmt = $conn->prepare($sql); $stmt->execute(array(':usr_id' => $usr_id)); $rs = $stmt->fetchAll(PDO::FETCH_ASSOC); $stmt->closeCursor(); $history = '