File "html_d7d0602c3fcdafa9aafc39dfaddeeb96.php"

Full path: /home/argothem/www/organecyberpresse/tmp/cache/skel/html_d7d0602c3fcdafa9aafc39dfaddeeb96.php
File size: 6.71 KB
MIME-type: text/x-php
Charset: utf-8

<?php

/*
 * Squelette : squelettes/modeles/article_traductions.html
 * Date :      Tue, 28 Jun 2022 09:29:44 GMT
 * Compile :   Tue, 26 Aug 2025 15:58:18 GMT
 * Boucles :   _traductions, _article
 */ 

function BOUCLE_traductionshtml_d7d0602c3fcdafa9aafc39dfaddeeb96(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) {

	static $command = array();
	static $connect;
	$command['connect'] = $connect = '';
	if (!isset($command['table'])) {
		$command['table'] = 'articles';
		$command['id'] = '_traductions';
		$command['from'] = array('articles' => 'spip_articles');
		$command['type'] = array();
		$command['groupby'] = array();
		$command['select'] = array("articles.lang",
		"articles.id_article",
		"articles.id_rubrique",
		"articles.titre");
		$command['orderby'] = array('articles.lang');
		$command['join'] = array();
		$command['limit'] = '';
		$command['having'] = 
			array();
	}
	$command['where'] = 
			array(
quete_condition_statut('articles.statut','publie,prop,prepa/auteur','publie',''), 
			array('OR', 
			array('AND', 
			array('=', 'articles.id_trad', 0), 
			array('=', 'articles.id_article', sql_quote($Pile[$SP]['id_article'], '', ''))), 
			array('AND', 
			array('>', 'articles.id_trad', 0), 
			array('=', 'articles.id_trad', sql_quote($Pile[$SP]['id_trad'], '', '')))));
	if (defined("_BOUCLE_PROFILER")) $timer = time()+(float)microtime();
	$t0 = "";
	// REQUETE
	$iter = Spip\Compilateur\Iterateur\Factory::create(
		"SQL",
		$command,
		array('squelettes/modeles/article_traductions.html','html_d7d0602c3fcdafa9aafc39dfaddeeb96','_traductions',13,$GLOBALS['spip_lang'])
	);
	if (!$iter->err()) {
	$Numrows['_traductions']['command'] = $command;
	$Numrows['_traductions']['total'] = @intval($iter->count());
	lang_select($GLOBALS['spip_lang']);
	$SP++;
	// RESULTATS
	while ($Pile[$SP]=$iter->fetch()) {

		lang_select_public($Pile[$SP]['lang'], '', $Pile[$SP]['titre']);
		$t0 .= (($t1 = strval(retablir_echappements_modeles(((($Numrows['_traductions']['total'] ?? 0) > '1') ? ' ':''))))!=='' ?
		($t1 . (	'
	<span lang="' .
	retablir_echappements_modeles(spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang'])) .
	'" xml:lang="' .
	retablir_echappements_modeles(spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang'])) .
	'" dir="' .
	retablir_echappements_modeles(lang_dir($Pile[$SP]['lang'], 'ltr','rtl')) .
	'"' .
	(($t2 = strval(retablir_echappements_modeles((calcul_exposer($Pile[$SP]['id_article'], 'id_article', $Pile[0], $Pile[$SP]['id_rubrique'], 'id_article', '') ? 'on' : ''))))!=='' ?
			(' class="' . $t2 . '"') :
			'') .
	'>&#91;' .
	retablir_echappements_modeles((calcul_exposer($Pile[$SP]['id_article'], 'id_article', $Pile[0], $Pile[$SP]['id_rubrique'], 'id_article', '') ? '' : (	'<a href="' .
		(vider_url(urlencode_1738(generer_objet_url($Pile[$SP]['id_article'], 'article', '', '', true)))) .
		'" rel="alternate" hreflang="' .
		(spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang'])) .
		'"' .
		(($t3 = strval((interdire_scripts(couper(attribut_html(supprimer_numero(typo($Pile[$SP]['titre'], "TYPO", $connect, $Pile[0]))),'80')))))!=='' ?
				(' title="' . $t3 . '"') :
				'') .
		'>'))) .
	retablir_echappements_modeles(traduire_nom_langue(spip_htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']))) .
	retablir_echappements_modeles((calcul_exposer($Pile[$SP]['id_article'], 'id_article', $Pile[0], $Pile[$SP]['id_rubrique'], 'id_article', '') ? '' : '</a>')) .
	'&#93;</span>
	')) :
		'');
		lang_select();
	}
	lang_select();
	$iter->free();
	}
	if (defined("_BOUCLE_PROFILER")
	AND 1000*($timer = (time()+(float)microtime())-$timer) > _BOUCLE_PROFILER)
		spip_log(intval(1000*$timer)."ms BOUCLE_traductions @ squelettes/modeles/article_traductions.html","profiler"._LOG_AVERTISSEMENT);
	return $t0;
}


function BOUCLE_articlehtml_d7d0602c3fcdafa9aafc39dfaddeeb96(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) {

	static $command = array();
	static $connect;
	$command['connect'] = $connect = '';
	if (!isset($command['table'])) {
		$command['table'] = 'articles';
		$command['id'] = '_article';
		$command['from'] = array('articles' => 'spip_articles');
		$command['type'] = array();
		$command['groupby'] = array();
		$command['select'] = array("articles.id_trad",
		"articles.id_article",
		"articles.lang",
		"articles.titre");
		$command['orderby'] = array();
		$command['join'] = array();
		$command['limit'] = '';
		$command['having'] = 
			array();
	}
	$command['where'] = 
			array(
quete_condition_statut('articles.statut','publie,prop,prepa/auteur','publie',''), 
			array('=', 'articles.id_article', sql_quote(($Pile[0]['id_article'] ?? null), '','bigint NOT NULL AUTO_INCREMENT')));
	if (defined("_BOUCLE_PROFILER")) $timer = time()+(float)microtime();
	$t0 = "";
	// REQUETE
	$iter = Spip\Compilateur\Iterateur\Factory::create(
		"SQL",
		$command,
		array('squelettes/modeles/article_traductions.html','html_d7d0602c3fcdafa9aafc39dfaddeeb96','_article',9,$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 = BOUCLE_traductionshtml_d7d0602c3fcdafa9aafc39dfaddeeb96($Cache, $Pile, $doublons, $Numrows, $SP))!=='' ?
		((	'
<p class="traductions">
	' .
		_T('public|spip|ecrire:trad_article_traduction') .
		'
	') . $t1 . '
</p>
') :
		'') .
'
');
		lang_select();
	}
	lang_select();
	$iter->free();
	}
	if (defined("_BOUCLE_PROFILER")
	AND 1000*($timer = (time()+(float)microtime())-$timer) > _BOUCLE_PROFILER)
		spip_log(intval(1000*$timer)."ms BOUCLE_article @ squelettes/modeles/article_traductions.html","profiler"._LOG_AVERTISSEMENT);
	return $t0;
}

//
// Fonction principale du squelette squelettes/modeles/article_traductions.html
// Temps de compilation total: 0.280 ms
//

function html_d7d0602c3fcdafa9aafc39dfaddeeb96($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 = (
(($t1 = strval(retablir_echappements_modeles('')))!=='' ?
		($t1 . '
	Affiche les traductions disponibles d\'un article.
	La langue de l\'article courant s\'affiche en gras, sans lien.
') :
		'') .
(($t1 = strval(retablir_echappements_modeles('')))!=='' ?
		($t1 . '

	Note : le lien <a rel="alternate" hreflang="xx" ...> indique qu\'il
	s\'agit d\'une traduction (version alternative dans la langue xx)

') :
		'') .
BOUCLE_articlehtml_d7d0602c3fcdafa9aafc39dfaddeeb96($Cache, $Pile, $doublons, $Numrows, $SP));

	return analyse_resultat_skel('html_d7d0602c3fcdafa9aafc39dfaddeeb96', $Cache, $page, 'squelettes/modeles/article_traductions.html');
}