function BOUCLE_rubrique_principalhtml_0caead67327defaf94febb642f511490(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) { static $command = array(); static $connect; $command['connect'] = $connect = ''; if (!isset($command['table'])) { $command['table'] = 'rubriques'; $command['id'] = '_rubrique_principal'; $command['from'] = array('rubriques' => 'spip_rubriques'); $command['type'] = array(); $command['groupby'] = array(); $command['select'] = array("rubriques.id_rubrique", "rubriques.lang", "rubriques.titre", "rubriques.id_secteur", "rubriques.texte", "rubriques.descriptif"); $command['orderby'] = array(); $command['join'] = array(); $command['limit'] = ''; $command['having'] = array(); } $command['where'] = array(quete_condition_statut('rubriques.statut', '!', 'publie', ''), array('=', 'rubriques.id_rubrique', sql_quote(@$Pile[0]['id_rubrique'], '', 'bigint(21) NOT NULL AUTO_INCREMENT'))); if (defined("_BOUCLE_PROFILER")) { $timer = time() + microtime(); } $t0 = ""; // REQUETE $iter = IterFactory::create("SQL", $command, array('squelettes/rubrique.html', 'html_0caead67327defaf94febb642f511490', '_rubrique_principal', 1, $GLOBALS['spip_lang'])); if (!$iter->err()) { lang_select($GLOBALS['spip_lang']); $SP++; // RESULTATS while ($Pile[$SP] = $iter->fetch()) { lang_select_public($Pile[$SP]['lang'], 'oui', $Pile[$SP]['titre']); $t0 .= ' <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="' . spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']) . '" lang="' . spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']) . '" dir="' . lang_dir($Pile[$SP]['lang'], 'ltr', 'rtl') . '"> <head> <title>[' . interdire_scripts(textebrut(typo($GLOBALS['meta']['nom_site'], "TYPO", $connect, $Pile[0]))) . '] : ' . interdire_scripts(entites_html(textebrut(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0]))))) . '</title> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-meta') . ', array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',7,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> <link rel="alternate" type="application/rss+xml" title="' . _T('public|spip|ecrire:syndiquer_rubrique') . ' : ' . interdire_scripts(entites_html(textebrut(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0]))))) . '" href="' . interdire_scripts(parametre_url(generer_url_public('backend', ''), 'id_rubrique', $Pile[$SP]['id_rubrique'])) . '" /> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('styles') . ', array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',10,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> </head> <body dir="' . lang_dir($Pile[$SP]['lang'], 'ltr', 'rtl') . '" class="' . spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']) . ' rubrique sect' . $Pile[$SP]['id_secteur'] . ' ' . BOUCLE_rubriques_bodyhtml_0caead67327defaf94febb642f511490($Cache, $Pile, $doublons, $Numrows, $SP) . ' rub' . $Pile[$SP]['id_rubrique'] . '"> <div id="page" class="rubrique rub' . $Pile[$SP]['id_rubrique'] . '"> <!-- ***************************************************************** Bandeau, titre du site et menu langue Header and main menu (top and right) ************************************************************* --> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-bandeau') . ', array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',20,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> <!-- ***************************************************************** Contenu principal (centre) Main content (center) ************************************************************* --> <div id="bloc-contenu"> <h5> <a href="' . spip_htmlspecialchars(sinon($GLOBALS['meta']['adresse_site'], '.')) . '" title="' . _T('public|spip|ecrire:accueil_site') . ' : ' . interdire_scripts(typo($GLOBALS['meta']['nom_site'], "TYPO", $connect, $Pile[0])) . '">' . _T('public|spip|ecrire:accueil_site') . '</a> ' . (($t1 = BOUCLE_rubriques_cheminhtml_0caead67327defaf94febb642f511490($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? ' ' . $t1 . ' ' : '') . ' ' . (($t1 = strval(interdire_scripts(couper(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])), '60')))) !== '' ? '<b class=\'separateur\'>></b> ' . $t1 : '') . ' </h5> <div class="ligne-debut"></div><!-- ligne-debut --> ' . (($t1 = strval(filtrer('image_graver', filtrer('image_reduire', !is_array($l = quete_logo('id_rubrique', 'ON', $Pile[$SP]['id_rubrique'], quete_parent($Pile[$SP]['id_rubrique']), 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />', '120', '0')))) !== '' ? '<div class="logo-liste-art"> ' . $t1 . ' </div>' : '') . ' <h1 class="titre-article">' . interdire_scripts(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0]))) . '</h1> ' . (($t1 = strval(interdire_scripts(($a = filtrer('image_graver', filtrer('image_reduire', propre($Pile[$SP]['texte'], $connect, $Pile[0]), '560', '0')) or is_string($a) and strlen($a)) ? $a : interdire_scripts(propre($Pile[$SP]['descriptif'], $connect, $Pile[0]))))) !== '' ? '<div class="chapo ' . interdire_scripts($Pile[$SP]['texte'] ? '' : '') . '" id="description"> ' . $t1 . (' ' . (($t2 = strval(interdire_scripts(calculer_notes()))) !== '' ? '<div class="notes" style="padding: 0 1.5em;">' . $t2 . '</div>' : '') . ' </div><!-- chapo -->') : '') . ' ' . recuperer_fond('inc/inc-rub-documents', array_merge($Pile[0], array('id_rubrique' => $Pile[$SP]['id_rubrique'])), array('compil' => array('squelettes/rubrique.html', 'html_0caead67327defaf94febb642f511490', '_rubrique_principal', 43, $GLOBALS['spip_lang'])), _request('connect')) . ' ' . (($t1 = BOUCLE_type_miniplanhtml_0caead67327defaf94febb642f511490($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? $t1 . ' ' : ' ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-rub-articles') . ', array_merge(' . var_export($Pile[0], 1) . ',array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'id_secteur\' => ' . argumenter_squelette($Pile[$SP]['id_secteur']) . ', \'self\' => ' . argumenter_squelette(self()) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . ')), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',63,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> ') . ' <br class="nettoyeur" /> </div><!-- bloc-contenu --> <!-- ***************************************************************** Menus contextuels (droite) Contextual menus (right) ************************************************************* --> <div id="encart"> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-annonces') . ', array_merge(' . var_export($Pile[0], 1) . ',array(\'self\' => ' . argumenter_squelette(self()) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . ')), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',76,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-breves') . ', array_merge(' . var_export($Pile[0], 1) . ',array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'self\' => ' . argumenter_squelette(self()) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . ')), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',78,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-syndic') . ', array_merge(' . var_export($Pile[0], 1) . ',array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'self\' => ' . argumenter_squelette(self()) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . ')), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',80,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> </div><!-- encart --> <!-- ***************************************************************** Navigation principale et rubriques (haut et/ou gauche) Main and Sections Navigation (top and/orleft) ************************************************************* --> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-menu') . ', array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',88,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> <!-- ***************************************************************** Pied de page - Footer ************************************************************* --> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-bas') . ', array(\'id_rubrique\' => ' . argumenter_squelette($Pile[$SP]['id_rubrique']) . ', \'id_secteur\' => ' . argumenter_squelette($Pile[$SP]['id_secteur']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/rubrique.html\',\'html_0caead67327defaf94febb642f511490\',\'\',92,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> </div><!-- page --> </body> </html> '; lang_select(); } lang_select(); $iter->free(); } if (defined("_BOUCLE_PROFILER") and 1000 * ($timer = time() + microtime() - $timer) > _BOUCLE_PROFILER) { spip_log(intval(1000 * $timer) . "ms BOUCLE_rubrique_principal @ squelettes/rubrique.html", "profiler" . _LOG_AVERTISSEMENT); } return $t0; }
function BOUCLE_auteur_principalhtml_ce97d1249b67fffb20134bd49b8a9e29(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) { static $command = array(); static $connect; $command['connect'] = $connect = ''; if (!isset($command['table'])) { $command['table'] = 'auteurs'; $command['id'] = '_auteur_principal'; $command['from'] = array('auteurs' => 'spip_auteurs'); $command['type'] = array(); $command['groupby'] = array(); $command['select'] = array("auteurs.id_auteur", "auteurs.lang", "auteurs.nom", "auteurs.bio", "auteurs.url_site", "auteurs.nom_site", "auteurs.email"); $command['orderby'] = array(); $command['join'] = array(); $command['limit'] = ''; $command['having'] = array(); } $command['where'] = array(quete_condition_statut('auteurs.statut', '!5poubelle', '!5poubelle', ''), array('=', 'auteurs.id_auteur', sql_quote(@$Pile[0]['id_auteur'], '', 'bigint(21) NOT NULL AUTO_INCREMENT'))); if (defined("_BOUCLE_PROFILER")) { $timer = time() + microtime(); } $t0 = ""; // REQUETE $iter = IterFactory::create("SQL", $command, array('squelettes/auteur.html', 'html_ce97d1249b67fffb20134bd49b8a9e29', '_auteur_principal', 1, $GLOBALS['spip_lang'])); if (!$iter->err()) { $SP++; // RESULTATS while ($Pile[$SP] = $iter->fetch()) { $t0 .= ' <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="' . spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']) . '" lang="' . spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']) . '" dir="' . lang_dir($Pile[$SP]['lang'], 'ltr', 'rtl') . '"> <head> <title>' . interdire_scripts(textebrut(typo(supprimer_numero($Pile[$SP]['nom']), "TYPO", $connect, $Pile[0]))) . ' - [' . interdire_scripts(textebrut(typo($GLOBALS['meta']['nom_site'], "TYPO", $connect, $Pile[0]))) . ']</title> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-meta') . ', array(\'id_auteur\' => ' . argumenter_squelette($Pile[$SP]['id_auteur']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/auteur.html\',\'html_ce97d1249b67fffb20134bd49b8a9e29\',\'\',7,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> <link rel="alternate" type="application/rss+xml" title="' . interdire_scripts(textebrut(typo(supprimer_numero($Pile[$SP]['nom']), "TYPO", $connect, $Pile[0]))) . '" href="' . interdire_scripts(parametre_url(generer_url_public('backend', ''), 'id_auteur', $Pile[$SP]['id_auteur'])) . '" /> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('styles') . ', array(\'id_auteur\' => ' . argumenter_squelette($Pile[$SP]['id_auteur']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/auteur.html\',\'html_ce97d1249b67fffb20134bd49b8a9e29\',\'\',9,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> </head> <body dir="' . lang_dir($Pile[$SP]['lang'], 'ltr', 'rtl') . '" class="' . spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']) . ' auteur aut' . $Pile[$SP]['id_auteur'] . '"> <div id="page" class="auteur"> <!-- ***************************************************************** Bandeau, titre du site et menu langue Header and main menu (top and right) ************************************************************* --> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-bandeau') . ', array(\'id_auteur\' => ' . argumenter_squelette($Pile[$SP]['id_auteur']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/auteur.html\',\'html_ce97d1249b67fffb20134bd49b8a9e29\',\'\',19,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> <!-- ***************************************************************** Contenu principal (centre) Main content (center) ************************************************************* --> <div id="bloc-contenu"> <div class="cartouche"> ' . (($t1 = strval(filtrer('image_graver', filtrer('image_reduire', !is_array($l = quete_logo('id_auteur', 'ON', $Pile[$SP]['id_auteur'], '', 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />', '120', '0')))) !== '' ? '<span style="float:right;">' . $t1 . '</span>' : '') . ' <h1 class="">' . interdire_scripts(typo(supprimer_numero($Pile[$SP]['nom']), "TYPO", $connect, $Pile[0])) . '</h1> <div class="texte"> ' . (($t1 = strval(interdire_scripts(propre($Pile[$SP]['bio'], $connect, $Pile[0])))) !== '' ? '<div class="bio">' . $t1 . '</div>' : '') . ' ' . (($t1 = strval(calculer_url($Pile[$SP]['url_site'], '', 'url', $connect))) !== '' ? '<b>' . interdire_scripts(typo(supprimer_numero(calculer_url($Pile[$SP]['url_site'], $Pile[$SP]['nom_site'], 'titre', $connect, false)), "TYPO", $connect, $Pile[0])) . ' : <a href="' . $t1 . ('">' . calculer_url($Pile[$SP]['url_site'], '', 'url', $connect) . '</a></b><br />') : '') . ' ' . (($t1 = strval(interdire_scripts(calculer_notes()))) !== '' ? $t1 . '<br />' : '') . ' <br /> ' . (($t1 = strval(executer_balise_dynamique('FORMULAIRE_ECRIRE_AUTEUR', array($Pile[$SP]['id_auteur'], @$Pile[0]['id_article'], $Pile[$SP]['email']), array('squelettes/auteur.html', 'html_ce97d1249b67fffb20134bd49b8a9e29', '_auteur_principal', 27, $GLOBALS['spip_lang'])))) !== '' ? '<h2 id="message">' . _T('public|spip|ecrire:info_envoyer_message_prive') . '</h2>' . $t1 : '') . ' </div><!-- texte --> </div><!-- cartouche --> <!-- Articles de l\'auteur --> <h2>' . _T('public|spip|ecrire:articles_auteur') . '</h2> ' . (($t1 = BOUCLE_articleshtml_ce97d1249b67fffb20134bd49b8a9e29($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? $t1 : ' ') . ' </div><!-- bloc-contenu --> <!-- ***************************************************************** Menus contextuels (droite) Contextual menus (right) ************************************************************* --> <div id="encart"> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-annonces') . ', array(\'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/auteur.html\',\'html_ce97d1249b67fffb20134bd49b8a9e29\',\'\',53,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> ' . (($t1 = BOUCLE_auteurshtml_ce97d1249b67fffb20134bd49b8a9e29($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? ' <!-- Tous les auteurs --> <div class="menu"> <ul class="titre"> <li><b>' . _T('public|spip|ecrire:icone_tous_auteur') . '</b> ' . $t1 . ' </li> </ul> </div><!-- menu --> ' : '') . ' </div><!-- encart --> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-menu') . ', array(\'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/auteur.html\',\'html_ce97d1249b67fffb20134bd49b8a9e29\',\'\',72,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> ' . '<' . '?php echo recuperer_fond( ' . argumenter_squelette('inc/inc-bas') . ', array(\'id_auteur\' => ' . argumenter_squelette($Pile[$SP]['id_auteur']) . ', \'lang\' => ' . argumenter_squelette($GLOBALS["spip_lang"]) . '), array("compil"=>array(\'squelettes/auteur.html\',\'html_ce97d1249b67fffb20134bd49b8a9e29\',\'\',73,$GLOBALS[\'spip_lang\'])), _request("connect")); ?' . '> </div><!-- page --> </body> </html> '; } $iter->free(); } if (defined("_BOUCLE_PROFILER") and 1000 * ($timer = time() + microtime() - $timer) > _BOUCLE_PROFILER) { spip_log(intval(1000 * $timer) . "ms BOUCLE_auteur_principal @ squelettes/auteur.html", "profiler" . _LOG_AVERTISSEMENT); } return $t0; }
function html_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons = array(), $Numrows = array(), $SP = 0) { if (isset($Pile[0]["doublons"]) and is_array($Pile[0]["doublons"])) { $doublons = nettoyer_env_doublons($Pile[0]["doublons"]); } $connect = ''; $page = BOUCLE_lien_webfontshtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP) . ' <!-- META DATA --> <meta http-equiv="Content-Type" content="text/html; charset=' . interdire_scripts($GLOBALS['meta']['charset']) . '" /> <meta http-equiv="Content-language" content="' . spip_htmlentities(@$Pile[0]['lang'] ? @$Pile[0]['lang'] : $GLOBALS['spip_lang']) . '" /> <meta name="language" content="' . spip_htmlentities(@$Pile[0]['lang'] ? @$Pile[0]['lang'] : $GLOBALS['spip_lang']) . '" /> <meta http-equiv="Content-Style-Type" content="text/css" /> <meta http-equiv="Content-Script-Type" content="text/javascript" /> <meta name="generator" content="SPIP' . (($t1 = strval(spip_version())) !== '' ? ' ' . $t1 : '') . '" /> <meta name="robots" content="index,follow" /> <link rel="schema.DCTERMS" href="http://purl.org/dc/terms/" /> <link rel="schema.DC" href="http://purl.org/dc/elements/1.1/" /> ' . (($t1 = BOUCLE_article_headhtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? $t1 : ' ' . (($t2 = BOUCLE_breve_headhtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? $t2 : (($t3 = BOUCLE_mot_headhtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? $t3 : (($t4 = BOUCLE_rubrique_headhtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? $t4 : (($t5 = BOUCLE_site_headhtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? $t5 : ' <!-- META pages recapitulatives - META summary pages --> ' . (($t6 = BOUCLE_keywords_recaphtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? ' <meta name="keywords" content="' . $t6 . '" />' : '') . ' ' . (($t6 = strval(interdire_scripts(attribut_html(propre($GLOBALS['meta']['descriptif_site'], $connect, $Pile[0]))))) !== '' ? '<meta name="description" content="' . $t6 . '" />' : '') . ' <meta name="author" content="' . BOUCLE_author_recaphtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP) . '" /> <!-- META Dublin Core - voir: http://uk.dublincore.org/documents/dcq-html/ --> ' . (($t6 = strval(interdire_scripts(entites_html(textebrut(typo($GLOBALS['meta']['nom_site'], "TYPO", $connect, $Pile[0])))))) !== '' ? '<meta name="DC.title" content="' . $t6 . '" /> ' : '') . (($t6 = strval(spip_htmlentities(@$Pile[0]['lang'] ? @$Pile[0]['lang'] : $GLOBALS['spip_lang']))) !== '' ? '<meta name="DC.language" scheme="ISO639-1" content="' . $t6 . '" /> ' : '') . (($t6 = strval(spip_htmlspecialchars(sinon($GLOBALS['meta']['adresse_site'], '.')))) !== '' ? '<meta name="DC.identifier" scheme="DCTERMS.URI" content="' . $t6 . '" /> ' : '') . (($t6 = strval(spip_htmlspecialchars(sinon($GLOBALS['meta']['adresse_site'], '.')))) !== '' ? '<meta name="DC.source" scheme="DCTERMS.URI" content="' . $t6 . '" />' : '') . BOUCLE_recap_auteursDChtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP) . (($t6 = strval(interdire_scripts(attribut_html(couper(propre($GLOBALS['meta']['descriptif_site'], $connect, $Pile[0]), '150'))))) !== '' ? ' <meta name="DC.description" content="' . $t6 . '" />' : '') . (($t6 = BOUCLE_recap_subjectDChtml_f7a72f7c15527e9fefe562fecb18cf87($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? ' <meta name="DC.subject" content="' . $t6 . '" />' : '') . (($t6 = strval(interdire_scripts(date_iso(normaliser_date(@$Pile[0]['date']))))) !== '' ? ' <meta name="DC.date" scheme="ISO8601" content="' . $t6 . '" />' : '') . ' '))))) . ' ' . (($t1 = strval(interdire_scripts(($a = extraire_attribut(filtrer('image_graver', filtrer('image_format', filtrer('image_recadre', filtrer('image_passe_partout', ($a = ($a = table_valeur(@$Pile[0], (string) 'favicon', null) or is_string($a) and strlen($a)) ? $a : find_in_path('favicon.ico') or is_string($a) and strlen($a)) ? $a : (!is_array($l = quete_logo('id_syndic', 'ON', "'0'", '', 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />'), '32', '32'), '32', '32', 'center'), 'ico')), 'src') or is_string($a) and strlen($a)) ? $a : find_in_path('spip.ico')))) !== '' ? ' <link rel="shortcut icon" href="' . $t1 . '" type="image/x-icon" />' : '') . ' ' . (($t1 = strval(interdire_scripts(generer_url_public('backend', '')))) !== '' ? ' <link rel="alternate" type="application/rss+xml" title="' . _T('public|spip|ecrire:syndiquer_site') . ' : ' . interdire_scripts(textebrut(typo($GLOBALS['meta']['nom_site'], "TYPO", $connect, $Pile[0]))) . '" href="' . $t1 . '" />' : '') . ' '; return analyse_resultat_skel('html_f7a72f7c15527e9fefe562fecb18cf87', $Cache, $page, 'squelettes/inc/inc-meta.html'); }
function BOUCLE_rubriques_editohtml_0167a54ed63f4fd0ee2bbef24b5ac307(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) { static $command = array(); static $connect; $command['connect'] = $connect = ''; $in = array(); if (!is_array($a = @$Pile[0]['lang'])) { $in[] = $a; } else { $in = array_merge($in, $a); } if (!isset($command['table'])) { $command['table'] = 'rubriques'; $command['id'] = '_rubriques_edito'; $command['from'] = array('rubriques' => 'spip_rubriques', 'L1' => 'spip_mots_liens', 'L2' => 'spip_mots'); $command['type'] = array(); $command['groupby'] = array("rubriques.id_rubrique"); $command['select'] = array("0+rubriques.titre AS num", "rubriques.titre", "rubriques.id_rubrique", "rubriques.descriptif", "rubriques.texte", "rubriques.lang"); $command['orderby'] = array('num', 'rubriques.titre'); $command['join'] = array('L1' => array('rubriques', 'id_objet', 'id_rubrique', 'L1.objet=' . sql_quote('rubrique')), 'L2' => array('L1', 'id_mot')); $command['limit'] = '0,10'; $command['having'] = array(); } $command['where'] = array(quete_condition_statut('rubriques.statut', '!', 'publie', ''), !(is_array(@$Pile[0]['lang']) ? count(@$Pile[0]['lang']) : strlen(@$Pile[0]['lang'])) ? '' : (is_array(@$Pile[0]['lang']) ? sql_in('rubriques.lang', sql_quote($in)) : array('=', 'rubriques.lang', sql_quote($GLOBALS['spip_lang'], '', 'varchar(10) NOT NULL DEFAULT \'\''))), array('=', 'L2.titre', "'Editorial'")); if (defined("_BOUCLE_PROFILER")) { $timer = time() + microtime(); } $t0 = ""; // REQUETE $iter = IterFactory::create("SQL", $command, array('squelettes/inc/inc-sommaire-edito.html', 'html_0167a54ed63f4fd0ee2bbef24b5ac307', '_rubriques_edito', 8, $GLOBALS['spip_lang'])); if (!$iter->err()) { lang_select($GLOBALS['spip_lang']); $SP++; // RESULTATS while ($Pile[$SP] = $iter->fetch()) { lang_select_public($Pile[$SP]['lang'], '', $Pile[$SP]['titre']); $t0 .= ' <br class="nettoyeur" /> ' . (($t1 = strval(interdire_scripts(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0]))))) !== '' ? '<h3 class="edito-titre"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_rubrique'], 'rubrique', '', '', true))) . '">' . $t1 . '</a></h3>' : '') . ' ' . (($t1 = strval(filtrer('image_graver', filtrer('image_reduire', strlen($logo = !is_array($l = quete_logo('id_rubrique', 'ON', $Pile[$SP]['id_rubrique'], quete_parent($Pile[$SP]['id_rubrique']), 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />') ? '<a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_rubrique'], 'rubrique', '', '', true))) . '">' . $logo . '</a>' : '', '150', '0')))) !== '' ? '<div class="logo-liste-art"> ' . $t1 . ' </div>' : '') . ' ' . (($t1 = strval(interdire_scripts(($a = propre($Pile[$SP]['descriptif'], $connect, $Pile[0]) or is_string($a) and strlen($a)) ? $a : interdire_scripts(propre($Pile[$SP]['texte'], $connect, $Pile[0]))))) !== '' ? '<div class="chapo ' . interdire_scripts($Pile[$SP]['descriptif'] ? '' : '') . '">' . $t1 . ' <div style="clear: both; height: .1em;"> </div> </div>' : '') . ' '; lang_select(); } lang_select(); $iter->free(); } if (defined("_BOUCLE_PROFILER") and 1000 * ($timer = time() + microtime() - $timer) > _BOUCLE_PROFILER) { spip_log(intval(1000 * $timer) . "ms BOUCLE_rubriques_edito @ squelettes/inc/inc-sommaire-edito.html", "profiler" . _LOG_AVERTISSEMENT); } return $t0; }
function BOUCLE_article_languehtml_76ddbc2b5f1671bea60186a8fa5bb500(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) { static $command = array(); static $connect; $command['connect'] = $connect = ''; $doublons_index = array(); $command['pagination'] = array(isset($Pile[0]['debut_article_langue']) ? $Pile[0]['debut_article_langue'] : null, 10); // Initialise le(s) critère(s) doublons if (!isset($doublons[$d = 'articles' . 'archives'])) { $doublons[$d] = ''; } if (!isset($command['table'])) { $command['table'] = 'articles'; $command['id'] = '_article_langue'; $command['from'] = array('articles' => 'spip_articles'); $command['type'] = array(); $command['groupby'] = array(); $command['select'] = array("articles.id_article", "articles.date_redac", "articles.surtitre", "articles.titre", "articles.soustitre", "articles.descriptif", "articles.chapo", "articles.texte", "articles.lang"); $command['orderby'] = array('articles.date_redac'); $command['join'] = array(); $command['limit'] = ''; $command['having'] = array(); } $command['where'] = array(quete_condition_statut('articles.statut', 'publie,prop,prepa/auteur', 'publie', ''), array('=', 'articles.lang', sql_quote($GLOBALS['spip_lang'], '', 'varchar(10) NOT NULL DEFAULT \'\'')), array('<', 'TIMESTAMPDIFF(HOUR,articles.date_redac,NOW())/24', "1"), array(sql_in('articles.id_article', $doublons[$doublons_index[] = 'articles' . 'archives'], 'NOT'))); if (defined("_BOUCLE_PROFILER")) { $timer = time() + microtime(); } $t0 = ""; // REQUETE $iter = IterFactory::create("SQL", $command, array('squelettes/agenda.html', 'html_76ddbc2b5f1671bea60186a8fa5bb500', '_article_langue', 41, $GLOBALS['spip_lang'])); if (!$iter->err()) { // COMPTEUR $Numrows['_article_langue']['compteur_boucle'] = 0; $Numrows['_article_langue']['total'] = @intval($iter->count()); $debut_boucle = isset($Pile[0]['debut_article_langue']) ? $Pile[0]['debut_article_langue'] : _request('debut_article_langue'); if (substr($debut_boucle, 0, 1) == '@') { $debut_boucle = $Pile[0]['debut_article_langue'] = quete_debut_pagination('id_article', $Pile[0]['@id_article'] = substr($debut_boucle, 1), 10, $iter); $iter->seek(0); } $debut_boucle = intval($debut_boucle); $debut_boucle = ($tout = $debut_boucle == -1) ? 0 : $debut_boucle; $debut_boucle = max(0, min($debut_boucle, floor(($Numrows['_article_langue']['total'] - 1) / 10) * 10)); $debut_boucle = intval($debut_boucle); $fin_boucle = min($tout ? $Numrows['_article_langue']['total'] : $debut_boucle + 9, $Numrows['_article_langue']['total'] - 1); $Numrows['_article_langue']['grand_total'] = $Numrows['_article_langue']['total']; $Numrows['_article_langue']["total"] = max(0, $fin_boucle - $debut_boucle + 1); if ($debut_boucle > 0 and $debut_boucle < $Numrows['_article_langue']['grand_total'] and $iter->seek($debut_boucle, 'continue')) { $Numrows['_article_langue']['compteur_boucle'] = $debut_boucle; } lang_select($GLOBALS['spip_lang']); $SP++; // RESULTATS while ($Pile[$SP] = $iter->fetch()) { $Numrows['_article_langue']['compteur_boucle']++; if ($Numrows['_article_langue']['compteur_boucle'] <= $debut_boucle) { continue; } if ($Numrows['_article_langue']['compteur_boucle'] - 1 > $fin_boucle) { break; } foreach ($doublons_index as $k) { $doublons[$k] .= "," . $Pile[$SP]['id_article']; } // doublons lang_select_public($Pile[$SP]['lang'], '', $Pile[$SP]['titre']); $t0 .= ' <hr /> <h4>' . nom_jour(normaliser_date($Pile[$SP]['date_redac'])) . ' ' . affdate(normaliser_date($Pile[$SP]['date_redac'])) . (($t1 = strval(heures(normaliser_date($Pile[$SP]['date_redac'])) != '0' ? (($t2 = strval(heures(normaliser_date($Pile[$SP]['date_redac'])))) !== '' ? $t2 . ':' : '') . (($t2 = strval(minutes(normaliser_date($Pile[$SP]['date_redac'])))) !== '' ? $t2 . (' ' . _T('public|spip|ecrire:heures')) : '') : '')) !== '' ? ' — ' . $t1 : '') . '</h4> <hr /> ' . (($t1 = strval(filtrer('image_graver', filtrer('image_reduire', !is_array($l = quete_logo('id_article', 'ON', $Pile[$SP]['id_article'], '', 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />', '150', '0')))) !== '' ? '<span style="float:right;">' . $t1 . '</span>' : '') . ' ' . (($t1 = strval(interdire_scripts(typo($Pile[$SP]['surtitre'], "TYPO", $connect, $Pile[0])))) !== '' ? '<div class="surtitre">' . $t1 . '</div>' : '') . ' <h3><a href="' . spip_htmlspecialchars(sinon($GLOBALS['meta']['adresse_site'], '.')) . '/' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '">' . interdire_scripts(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0]))) . '</a></h3> ' . (($t1 = strval(interdire_scripts(typo($Pile[$SP]['soustitre'], "TYPO", $connect, $Pile[0])))) !== '' ? '<div class="sous-titre">' . $t1 . '</div>' : '') . ' <div class="detail"> </div><!-- detail --> ' . (($t1 = strval(interdire_scripts(propre($Pile[$SP]['descriptif'], $connect, $Pile[0]) ? (($t2 = strval(interdire_scripts(propre($Pile[$SP]['descriptif'], $connect, $Pile[0])))) !== '' ? '<div class="">' . $t2 . ('</div> <div class="suite"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '" title="...' . _T('public|spip|ecrire:suite') . ' : ' . interdire_scripts(attribut_html(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) . '" >' . _T('public|spip|ecrire:suite') . '</a></div>') : '') . ' ' : interdire_scripts(propre($Pile[$SP]['chapo'], $connect, $Pile[0]) ? (($t3 = strval(interdire_scripts(propre($Pile[$SP]['chapo'], $connect, $Pile[0])))) !== '' ? '<div class="">' . $t3 . ('</div> <div class="suite"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '" title="...' . _T('public|spip|ecrire:suite') . ' : ' . interdire_scripts(attribut_html(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) . '" >' . _T('public|spip|ecrire:suite') . '</a></div>') : '') . ' ' : (($t3 = strval(interdire_scripts(couper(propre($Pile[$SP]['texte'], $connect, $Pile[0]), '300')))) !== '' ? '<div class="">' . $t3 . ('</div> <div class="suite"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '" title="...' . _T('public|spip|ecrire:suite') . ' : ' . interdire_scripts(attribut_html(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) . '" >' . _T('public|spip|ecrire:suite') . '</a></div>') : '') . ' ') . ' '))) !== '' ? '<div class="texte"> <div class="extrait">' . $t1 . '</div><!-- fin extrait --> </div>' : '') . ' <br /> '; lang_select(); } lang_select(); $iter->free(); } if (defined("_BOUCLE_PROFILER") and 1000 * ($timer = time() + microtime() - $timer) > _BOUCLE_PROFILER) { spip_log(intval(1000 * $timer) . "ms BOUCLE_article_langue @ squelettes/agenda.html", "profiler" . _LOG_AVERTISSEMENT); } return $t0; }
function BOUCLE_secteurshtml_7b757a9211fae3c1871c26ec4415f046(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) { static $command = array(); static $connect; $command['connect'] = $connect = ''; if (!isset($command['table'])) { $command['table'] = 'rubriques'; $command['id'] = '_secteurs'; $command['from'] = array('rubriques' => 'spip_rubriques'); $command['type'] = array(); $command['groupby'] = array(); $command['select'] = array("rubriques.id_rubrique", "rubriques.lang", "0+rubriques.titre AS num1", "rubriques.titre"); $command['orderby'] = array('rubriques.lang DESC', 'num1', 'rubriques.titre'); $command['join'] = array(); $command['limit'] = ''; $command['having'] = array(); } $command['where'] = array(quete_condition_statut('rubriques.statut', '!', 'publie', ''), array('=', 'rubriques.id_parent', 0), array('=', 'rubriques.lang', sql_quote($GLOBALS['spip_lang'], '', 'varchar(10) NOT NULL DEFAULT \'\''))); if (defined("_BOUCLE_PROFILER")) { $timer = time() + microtime(); } $t0 = ""; // REQUETE $iter = IterFactory::create("SQL", $command, array('squelettes/plan.html', 'html_7b757a9211fae3c1871c26ec4415f046', '_secteurs', 39, $GLOBALS['spip_lang'])); if (!$iter->err()) { lang_select($GLOBALS['spip_lang']); $SP++; // RESULTATS while ($Pile[$SP] = $iter->fetch()) { lang_select_public($Pile[$SP]['lang'], '', $Pile[$SP]['titre']); $t0 .= ' ' . (($t1 = strval(traduire_nom_langue(unique(spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang'])), 'langues'))) !== '' ? '<h2>' . $t1 . '</h2>' : '') . ' <div class="plan-archives" style="clear:both;"> ' . filtrer('image_graver', filtrer('image_reduire', !is_array($l = quete_logo('id_rubrique', 'ON', $Pile[$SP]['id_rubrique'], quete_parent($Pile[$SP]['id_rubrique']), 0)) ? '' : "<img class=\"spip_logo spip_logo_right spip_logos\" alt=\"\" style=\"float:right\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />', '120', '0')) . ' <h3><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_rubrique'], 'rubrique', '', '', true))) . '">' . interdire_scripts(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0]))) . '</a></h3> </div> ' . (($t1 = BOUCLE_articles_racinehtml_7b757a9211fae3c1871c26ec4415f046($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? ' <ul> ' . $t1 . ' </ul> ' : '') . ' ' . (($t1 = BOUCLE_rubriqueshtml_7b757a9211fae3c1871c26ec4415f046($Cache, $Pile, $doublons, $Numrows, $SP)) !== '' ? ' <ul> ' . $t1 . ' </ul> ' : '') . ' '; lang_select(); } lang_select(); $iter->free(); } if (defined("_BOUCLE_PROFILER") and 1000 * ($timer = time() + microtime() - $timer) > _BOUCLE_PROFILER) { spip_log(intval(1000 * $timer) . "ms BOUCLE_secteurs @ squelettes/plan.html", "profiler" . _LOG_AVERTISSEMENT); } return $t0; }
function BOUCLE_articles_rubriquehtml_8bf8bdc0aa13e79e11d908f1699ff96f(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) { static $command = array(); static $connect; $command['connect'] = $connect = ''; $command['pagination'] = array(isset($Pile[0]['debut_articles_rubrique']) ? $Pile[0]['debut_articles_rubrique'] : null, 10); if (!isset($command['table'])) { $command['table'] = 'articles'; $command['id'] = '_articles_rubrique'; $command['from'] = array('articles' => 'spip_articles'); $command['type'] = array(); $command['groupby'] = array(); $command['select'] = array("articles.id_rubrique", "0+articles.titre AS num", "articles.date", "articles.id_article", "articles.surtitre", "articles.descriptif", "articles.titre", "articles.soustitre", "articles.chapo", "articles.texte", "articles.lang"); $command['orderby'] = array('num', 'articles.date DESC'); $command['join'] = array(); $command['limit'] = ''; $command['having'] = array(); } $command['where'] = array(quete_condition_statut('articles.statut', 'publie,prop,prepa/auteur', 'publie', ''), sql_in('articles.id_rubrique', calcul_branche_in(sql_quote(@$Pile[0]['id_rubrique'])))); if (defined("_BOUCLE_PROFILER")) { $timer = time() + microtime(); } $t0 = ""; // REQUETE $iter = IterFactory::create("SQL", $command, array('squelettes/inc/inc-rub-articles.html', 'html_8bf8bdc0aa13e79e11d908f1699ff96f', '_articles_rubrique', 1, $GLOBALS['spip_lang'])); if (!$iter->err()) { // COMPTEUR $Numrows['_articles_rubrique']['compteur_boucle'] = 0; $Numrows['_articles_rubrique']['total'] = @intval($iter->count()); $debut_boucle = isset($Pile[0]['debut_articles_rubrique']) ? $Pile[0]['debut_articles_rubrique'] : _request('debut_articles_rubrique'); if (substr($debut_boucle, 0, 1) == '@') { $debut_boucle = $Pile[0]['debut_articles_rubrique'] = quete_debut_pagination('id_article', $Pile[0]['@id_article'] = substr($debut_boucle, 1), 10, $iter); $iter->seek(0); } $debut_boucle = intval($debut_boucle); $debut_boucle = ($tout = $debut_boucle == -1) ? 0 : $debut_boucle; $debut_boucle = max(0, min($debut_boucle, floor(($Numrows['_articles_rubrique']['total'] - 1) / 10) * 10)); $debut_boucle = intval($debut_boucle); $fin_boucle = min($tout ? $Numrows['_articles_rubrique']['total'] : $debut_boucle + 9, $Numrows['_articles_rubrique']['total'] - 1); $Numrows['_articles_rubrique']['grand_total'] = $Numrows['_articles_rubrique']['total']; $Numrows['_articles_rubrique']["total"] = max(0, $fin_boucle - $debut_boucle + 1); if ($debut_boucle > 0 and $debut_boucle < $Numrows['_articles_rubrique']['grand_total'] and $iter->seek($debut_boucle, 'continue')) { $Numrows['_articles_rubrique']['compteur_boucle'] = $debut_boucle; } lang_select($GLOBALS['spip_lang']); $SP++; // RESULTATS while ($Pile[$SP] = $iter->fetch()) { $Numrows['_articles_rubrique']['compteur_boucle']++; if ($Numrows['_articles_rubrique']['compteur_boucle'] <= $debut_boucle) { continue; } if ($Numrows['_articles_rubrique']['compteur_boucle'] - 1 > $fin_boucle) { break; } lang_select_public($Pile[$SP]['lang'], '', $Pile[$SP]['titre']); $t0 .= ' <br class="nettoyeur" /> ' . (($t1 = strval(filtrer('image_graver', filtrer('image_reduire', strlen($logo = !is_array($l = quete_logo('id_article', 'ON', $Pile[$SP]['id_article'], '', 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />') ? '<a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '">' . $logo . '</a>' : '', '120', '0')))) !== '' ? '<div class="logo-liste-art"> ' . $t1 . ' </div>' : '') . ' ' . (($t1 = strval(interdire_scripts(typo($Pile[$SP]['surtitre'], "TYPO", $connect, $Pile[0])))) !== '' ? '<div class="surtitre">' . $t1 . '</div>' : '') . ' <h3> <a href="' . spip_htmlspecialchars(sinon($GLOBALS['meta']['adresse_site'], '.')) . '/' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '" ' . (($t1 = strval(interdire_scripts(entites_html(textebrut(propre($Pile[$SP]['descriptif'], $connect, $Pile[0])))))) !== '' ? 'title="' . $t1 . '"' : '') . '>' . interdire_scripts(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0]))) . '</a> ' . BOUCLE_articles_rubrique_nomhtml_8bf8bdc0aa13e79e11d908f1699ff96f($Cache, $Pile, $doublons, $Numrows, $SP) . ' </h3> ' . (($t1 = strval(interdire_scripts(typo($Pile[$SP]['soustitre'], "TYPO", $connect, $Pile[0])))) !== '' ? '<div class="sous-titre">' . $t1 . '</div>' : '') . ' <div class="detail"> ' . (($t1 = strval(interdire_scripts(nom_jour(normaliser_date($Pile[$SP]['date']))))) !== '' ? '<span class="date">' . $t1 : '') . ' ' . (($t1 = strval(interdire_scripts(affdate(normaliser_date($Pile[$SP]['date']))))) !== '' ? $t1 . '</span>' : '') . ' ' . (($t1 = strval(recuperer_fond('modeles/lesauteurs', array('objet' => 'article', 'id_objet' => $Pile[$SP]['id_article'], 'id_article' => $Pile[$SP]['id_article']), array('trim' => true, 'compil' => array('squelettes/inc/inc-rub-articles.html', 'html_8bf8bdc0aa13e79e11d908f1699ff96f', '_articles_rubrique', 17, $GLOBALS['spip_lang'])), ''))) !== '' ? '<span class="auteurs">' . _T('public|spip|ecrire:par_auteur') . ' ' . $t1 . '</span>' : '') . ' </div><!-- detail --> <div class="texte"> ' . (($t1 = strval(interdire_scripts(filtrer('image_graver', filtrer('image_reduire', propre($Pile[$SP]['descriptif'], $connect, $Pile[0]), '552', '0')) ? (($t2 = strval(interdire_scripts(filtrer('image_graver', filtrer('image_reduire', propre($Pile[$SP]['descriptif'], $connect, $Pile[0]), '552', '0'))))) !== '' ? '<div class="">' . $t2 . ('</div> <div class="suite"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '" title="...' . _T('public|spip|ecrire:suite') . ' : ' . interdire_scripts(attribut_html(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) . '" >' . _T('public|spip|ecrire:suite') . '</a></div>') : '') . ' ' : interdire_scripts(propre($Pile[$SP]['chapo'], $connect, $Pile[0]) ? (($t3 = strval(interdire_scripts(filtrer('image_graver', filtrer('image_reduire', propre($Pile[$SP]['chapo'], $connect, $Pile[0]), '552', '0'))))) !== '' ? '<div class="">' . $t3 . ('</div> <div class="suite"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '" title="...' . _T('public|spip|ecrire:suite') . ' : ' . interdire_scripts(attribut_html(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) . '" >' . _T('public|spip|ecrire:suite') . '</a></div>') : '') . ' ' : (($t3 = strval(interdire_scripts(couper(propre($Pile[$SP]['texte'], $connect, $Pile[0]), '300')))) !== '' ? '<div class="">' . $t3 . ('</div> <div class="suite"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '" title="...' . _T('public|spip|ecrire:suite') . ' : ' . interdire_scripts(attribut_html(supprimer_numero(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) . '" >' . _T('public|spip|ecrire:suite') . '</a></div>') : '') . ' ') . ' '))) !== '' ? '<div class="extrait">' . $t1 . '</div><!-- fin extrait -->' : '') . ' </div><!-- fin texte --> <br class="nettoyeur" /> '; lang_select(); } lang_select(); $iter->free(); } if (defined("_BOUCLE_PROFILER") and 1000 * ($timer = time() + microtime() - $timer) > _BOUCLE_PROFILER) { spip_log(intval(1000 * $timer) . "ms BOUCLE_articles_rubrique @ squelettes/inc/inc-rub-articles.html", "profiler" . _LOG_AVERTISSEMENT); } return $t0; }
function BOUCLE_annonces_arthtml_d7ab7eee0b09f43b71ae8cf8a6406a91(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) { static $command = array(); static $connect; $command['connect'] = $connect = ''; if (!isset($command['table'])) { $command['table'] = 'articles'; $command['id'] = '_annonces_art'; $command['from'] = array('articles' => 'spip_articles', 'L1' => 'spip_mots_liens', 'L2' => 'spip_mots'); $command['type'] = array(); $command['groupby'] = array("articles.id_article"); $command['select'] = array("articles.date", "articles.id_article", "articles.descriptif", "articles.titre", "articles.surtitre", "articles.soustitre", "articles.lang"); $command['orderby'] = array('articles.date DESC'); $command['join'] = array('L1' => array('articles', 'id_objet', 'id_article', 'L1.objet=' . sql_quote('article')), 'L2' => array('L1', 'id_mot')); $command['limit'] = ''; $command['having'] = array(); } $command['where'] = array(quete_condition_statut('articles.statut', 'publie,prop,prepa/auteur', 'publie', ''), array('=', 'articles.lang', sql_quote($GLOBALS['spip_lang'], '', 'varchar(10) NOT NULL DEFAULT \'\'')), array('=', 'L2.titre', "'Annonce'")); if (defined("_BOUCLE_PROFILER")) { $timer = time() + microtime(); } $t0 = ""; // REQUETE $iter = IterFactory::create("SQL", $command, array('squelettes/inc/inc-annonces.html', 'html_d7ab7eee0b09f43b71ae8cf8a6406a91', '_annonces_art', 97, $GLOBALS['spip_lang'])); if (!$iter->err()) { lang_select($GLOBALS['spip_lang']); $SP++; // RESULTATS while ($Pile[$SP] = $iter->fetch()) { lang_select_public($Pile[$SP]['lang'], '', $Pile[$SP]['titre']); $t0 .= ' <li class="annonce"> ' . (!is_array($l = quete_logo('id_article', 'ON', $Pile[$SP]['id_article'], '', 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />' ? '<a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '"' . (($t2 = strval(interdire_scripts(attribut_html(propre($Pile[$SP]['descriptif'], $connect, $Pile[0]))))) !== '' ? ' title="' . $t2 . '"' : '') . ' style="text-align:center;"> ' . inserer_attribut(inserer_attribut(filtrer('image_graver', filtrer('image_reduire', !is_array($l = quete_logo('id_article', 'ON', $Pile[$SP]['id_article'], '', 0)) ? '' : "<img class=\"spip_logo spip_logos\" alt=\"\" src=\"{$l['0']}\"" . $l[2] . ($l[1] ? " onmouseover=\"this.src='{$l['1']}'\" onmouseout=\"this.src='{$l['0']}'\"" : "") . ' />', '150', '0')), 'alt', interdire_scripts(attribut_html(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))), 'title', interdire_scripts(attribut_html(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) . ' </a> ' : '<p> ' . (($t2 = strval(interdire_scripts(typo($Pile[$SP]['surtitre'], "TYPO", $connect, $Pile[0])))) !== '' ? '<small style="text-transform:uppercase">' . $t2 . '</small>' : '') . ' ' . (($t2 = strval(interdire_scripts(typo(supprimer_numero($Pile[$SP]['titre']), "TYPO", $connect, $Pile[0])))) !== '' ? '<big style="text-align:center;"><a href="' . vider_url(urlencode_1738(generer_url_entite($Pile[$SP]['id_article'], 'article', '', '', true))) . '"' . (($t3 = strval(interdire_scripts(attribut_html(propre($Pile[$SP]['descriptif'], $connect, $Pile[0]))))) !== '' ? ' title="' . $t3 . '"' : '') . ' style="text-align:center;">' . $t2 . '</a></big>' : '') . ' ' . (($t2 = strval(interdire_scripts(typo($Pile[$SP]['soustitre'], "TYPO", $connect, $Pile[0])))) !== '' ? '<span>' . $t2 . '</span>' : '') . ' <br /> </p> ') . ' </li> '; lang_select(); } lang_select(); $iter->free(); } if (defined("_BOUCLE_PROFILER") and 1000 * ($timer = time() + microtime() - $timer) > _BOUCLE_PROFILER) { spip_log(intval(1000 * $timer) . "ms BOUCLE_annonces_art @ squelettes/inc/inc-annonces.html", "profiler" . _LOG_AVERTISSEMENT); } return $t0; }
/** * Récupère le contenu d'un média * * Arguments possibles : * -* login * -* pass * -* id_article int (Obligatoire) * -* champs_demandes string (champs que l'on souhaite récupérer, séparés par une virgule, sinon, on retourne l'ensemble) * -* document_largeur int (largeur maximale du document, si c'est une image, défaut largeur du document original) * -* document_hauteur int (hauteur maximale du document, si c'est une image, défaut hauteur du document original) * -* vignette_format string (carre ou autre, autre n'a pas de fonction) * -* vignette_largeur int (largeur de la vignette en px, défaut 100) * -* vignette_hauteur int (hauteur de la vignette en px, défaut 100) */ function geodiv_lire_media($args) { global $spip_xmlrpc_serveur; if (!intval($args['id_article']) > 0) { $erreur = _T('xmlrpc:erreur_identifiant', array('objet' => 'article')); return new IXR_Error(-32601, attribut_html($erreur)); } $champs_demandes = is_array($args['champs_demandes']) ? $args['champs_demandes'] : array(); $format_vignette = $args['vignette_format']; $config = lire_config('geol', array()); $secteur_medias = intval($config['secteur_medias']) > 0 ? $config['secteur_medias'] : 1; $args_media = array_merge($args, array('objet' => 'article', 'id_objet' => $args['id_article'])); $res = $spip_xmlrpc_serveur->read($args_media); if (!$res) { return $spip_xmlrpc_serveur->error; } $id_secteur = $res['result'][0]['id_secteur'] ? $res['result'][0]['id_secteur'] : sql_getfetsel('id_secteur', 'spip_articles', 'id_article=' . intval($args['id_article'])); /** * Sécurité : L'article demandé n'est pas un média */ if ($id_secteur != $secteur_medias) { $erreur = _T('xmlrpc_geodiv:erreur_article_media', array('id_article' => $args['id_article'])); return new IXR_Error(-32601, attribut_html($erreur)); } /** * Si on demande précisément certains champs, on ne fait que les renvoyer */ if (count($champs_demandes) != 0) { foreach ($res['result'][0] as $champ => $valeur) { if (!in_array($champ, array('id_article')) && !in_array($champ, $champs_demandes)) { unset($res['result'][0][$champ]); } } } /** * On ajoute le booléen "modifiable" : * Uniquement si on ne demande pas de champs spécifique ou qu'il soit dedans */ if (count($champs_demandes) == 0 || in_array('modifiable', $champs_demandes)) { if (autoriser('modifier', 'id_article', $args['id_article'], $GLOBALS['visiteur_session'])) { $res['result'][0]['modifiable'] = 1; } else { $res['result'][0]['modifiable'] = 0; } } /** * On ajoute le logo de l'article : * Uniquement si on ne demande pas de champs spécifique ou qu'il soit dedans */ if (count($champs_demandes) == 0 || in_array('logo', $champs_demandes)) { $logo = quete_logo('id_article', 'on', $res['result'][0]['id_article'], '', false); if (is_array($logo)) { $res['result'][0]['logo'] = url_absolue($logo[0]); } } /** * On a les infos de l'article, on récupère maintenant : * (si pas de champs demandés spécifiés ou les champs en question sont demandés) * -* Son document * -* Sa vignette * -* Sa géoloc * -* Ses mots clés * -** tags * -** échelle * -* Ses commentaires */ /** * On commence par le document principal */ if (count($champs_demandes) == 0 || in_array('document', $champs_demandes) || in_array('vignette', $champs_demandes)) { $document = sql_fetsel('*', 'spip_documents as documents LEFT JOIN spip_documents_liens AS lien ON documents.id_document=lien.id_document', 'lien.objet=' . sql_quote('article') . ' AND lien.id_objet=' . intval($args['id_article']), array(), array(), 1); if (is_array($document)) { include_spip('inc/documents'); include_spip('inc/filtres_images_mini'); include_spip('filtres/images_transforme'); if (count($champs_demandes) == 0 || in_array('document', $champs_demandes)) { $largeur_document = $args['document_largeur']; $hauteur_document = $args['document_hauteur']; if (in_array($document['extension'], array('gif', 'png', 'jpg')) && ($largeur_document || $hauteur_document)) { $res['result'][0]['document'] = url_absolue(extraire_attribut(image_reduire(get_spip_doc($document['fichier']), $largeur_document, $hauteur_document), 'src')); } else { $res['result'][0]['document'] = url_absolue(get_spip_doc($document['fichier'])); } $res['result'][0]['media'] = $document['media']; $res['result'][0]['extension'] = $document['extension']; } if (count($champs_demandes) == 0 || in_array('vignette', $champs_demandes)) { $largeur_vignette = $args['vignette_largeur'] ? $args['vignette_largeur'] : 100; $hauteur_vignette = $args['vignette_hauteur'] ? $args['vignette_hauteur'] : 100; if ($format_vignette == 'carre') { $vignette = extraire_attribut(quete_logo_document($document, $lien, $align, $mode_logo, '', '', $connect = NULL), 'src'); $res['result'][0]['vignette'] = url_absolue(extraire_attribut(image_recadre(image_passe_partout($vignette, $largeur_vignette, $hauteur_vignette), $largeur_vignette, $hauteur_vignette), 'src')); } else { $vignette = liens_absolus(quete_logo_document($document, $lien, $align, $mode_logo, $largeur_vignette, $hauteur_vignette, $connect = NULL)); $res['result'][0]['vignette'] = extraire_attribut($vignette, 'src'); } } } } /** * On ajoute les auteurs * On met juste leur id_auteur + nom, si besoin de plus une autre requête sur l'auteur est à effectuer */ if (count($champs_demandes) == 0 || in_array('auteurs', $champs_demandes)) { $auteurs = sql_select('auteurs.nom, auteurs.id_auteur', 'spip_auteurs AS auteurs INNER JOIN spip_auteurs_liens AS L1 ON L1.id_auteur = auteurs.id_auteur INNER JOIN spip_articles AS L2 ON L2.id_article = L1.id_objet', "L1.objet='article' AND auteurs.statut != '5poubelle' AND L2.id_article = " . intval($res['result'][0]['id_article'])); while ($auteur = sql_fetch($auteurs)) { $res['result'][0]['auteurs'][] = $auteur; } } /** * On ajoute les points de géoloc */ if (defined('_DIR_PLUGIN_GIS') && count($champs_demandes) == 0 || in_array('gis', $champs_demandes)) { include_spip('gis_xmlrpc', 'inc'); $tous_gis = sql_select('gis.id_gis', 'spip_gis AS `gis` INNER JOIN spip_gis_liens AS L1 ON L1.id_gis = gis.id_gis', 'L1.id_objet = ' . intval($args['id_article']) . ' AND (L1.objet = ' . sql_quote('article') . ')'); while ($gis = sql_fetch($tous_gis)) { $args['id_gis'] = $gis['id_gis']; $res['result'][0]['gis'][] = spip_lire_gis($args); } } /** * On ajoute les tags * On met juste leur id_mot + titr, si besoin de plus une autre requête sur le mot est à effectuer */ if (count($champs_demandes) == 0 || in_array('tags', $champs_demandes)) { $tags_group = intval($config['groupe_tags']) > 0 ? intval($config['groupe_tags']) : intval(lire_config('spipicious/groupe_mot')); if ($tags_group > 0) { $tous_tags = sql_select('mots.id_mot, mots.titre', 'spip_mots AS `mots` INNER JOIN spip_mots_liens AS L1 ON ( L1.id_mot = mots.id_mot )', 'L1.id_objet = ' . intval($args['id_article']) . ' AND (L1.objet = "article") AND (mots.id_groupe = ' . $tags_group . ')'); while ($tag = sql_fetch($tous_tags)) { $res['result'][0]['tags'][] = $tag; } } } /** * Et on ajoute l'échelle * On met juste son id_mot + titre, si besoin de plus une autre requête sur le mot est à effectuer */ if (count($champs_demandes) == 0 || in_array('echelle', $champs_demandes)) { $echelle_group = intval($config['groupe_echelle']) > 0 ? intval($config['groupe_echelle']) : 0; if ($echelle_group > 0) { $echelle = sql_fetsel('mots.id_mot, mots.titre', 'spip_mots AS `mots` INNER JOIN spip_mots_liens AS L1 ON ( L1.id_mot = mots.id_mot )', 'L1.id_objet = ' . intval($args['id_article']) . ' AND (L1.objet = "article") AND (mots.id_groupe = ' . $echelle_group . ')'); if (is_array($echelle)) { $res['result'][0]['echelle'][] = $echelle; } } } /** * Et on ajoute les forums * On n'affiche que les forums publiés (statut publie) * * On met juste : * -* id_forum * -* id_thread * -* titre * -* auteur * -* id_auteur * Si besoin de plus une autre requête sur le forum est à effectuer */ if (count($champs_demandes) == 0 || in_array('forums', $champs_demandes)) { $forums = sql_select('id_forum, id_thread,titre,auteur,id_auteur', 'spip_forum', 'objet=' . sql_quote('article') . ' AND id_objet = ' . intval($args['id_article']) . ' AND (statut = ' . sql_quote('publie') . ')'); while ($forum = sql_fetch($forums)) { $res['result'][0]['forums'][] = $forum; } } $media_struct = $res['result'][0]; $media_struct = array_filter($media_struct); return $media_struct; }