Skip to content
Extraits de code Groupes Projets
Valider 2fd29829 rédigé par Fil's avatar Fil
Parcourir les fichiers

simplifications diverses et jquerysiation du JS du bandeau, et correction du...

simplifications diverses et jquerysiation du JS du bandeau, et correction du bug #559; note: j'ai laisse la fonction sous le nom changestyle() car elle est compatible ascendante, mais son vrai nom serait fermer_menu() ou qq chose comme ca...
parent 2055f048
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
......@@ -2,59 +2,34 @@ var init_gauche = true;
function changestyle(id_couche, element, style) {
if (admin) {
hide_obj("bandeauaccueil");
hide_obj("bandeaunaviguer");
hide_obj("bandeauforum");
hide_obj("bandeauauteurs");
if (stat) { hide_obj("bandeaustatistiques_visites"); }
hide_obj("bandeauconfiguration");
}
hide_obj("bandeaudeconnecter");
hide_obj("bandeautoutsite");
hide_obj("bandeaunavrapide");
hide_obj("bandeauagenda");
hide_obj("bandeaumessagerie");
hide_obj("bandeausynchro");
//hide_obj("nav-recherche");
hide_obj("bandeaurecherche");
hide_obj("bandeauinfoperso");
hide_obj("bandeaudisplay");
hide_obj("bandeauecran");
hide_obj("bandeauinterface");
// La premiere fois, regler l'emplacement des sous-menus
if (init_gauche) {
if (admin) {
decalerCouche('bandeauaccueil');
decalerCouche('bandeaunaviguer');
decalerCouche('bandeauforum');
decalerCouche('bandeauauteurs');
if (stat) decalerCouche('bandeaustatistiques_visites');
decalerCouche('bandeauconfiguration');
}
init_gauche = false;
if (bug_offsetwidth) {
$('#haut-page').find('div.sous-menu').each(function(){
if (parseInt(this.style.left) > 0) {
demilargeur = Math.floor( this.offsetWidth / 2 );
if (demilargeur == 0) demilargeur = 100; // bug offsetwidth MSIE, on fixe une valeur arbitraire
gauche = parseInt(this.style.left)
- demilargeur
+ Math.floor(largeur_icone / 2);
if (gauche < 0) gauche = 0;
this.style.left = gauche+"px";
}
});
}
}
if (!(layer = findObj(id_couche))) return;
// Masquer les elements du bandeau
var select = $('#haut-page').find('div.bandeau').not('#'+id_couche);
// sauf eventuellement la boite de recherche si la souris passe en-dessous
if (id_couche=='garder-recherche') select = select.not('#bandeaurecherche');
select.css('visibility','hidden');
layer.style[element] = style;
// Afficher, le cas echeant, celui qui est demande
$('#'+id_couche).css(element||'visibility',style||'visible');
}
function decalerCouche(id_couche) {
if (!(layer = findObj(id_couche))) return;
if (bug_offsetwidth && ( parseInt(layer.style.left) > 0)) {
demilargeur = Math.floor( layer.offsetWidth / 2 );
if (demilargeur == 0) demilargeur = 100; // bug offsetwidth MSIE, on fixe une valeur arbitraire
gauche = parseInt(layer.style.left)
- demilargeur
+ Math.floor(largeur_icone / 2);
if (gauche < 0) gauche = 0;
layer.style.left = gauche+"px";
}
}
var accepter_change_statut = false;
......@@ -187,14 +162,3 @@ function puce_statut(selection){
return "puce-poubelle.gif";
}
}
// Pour ne pas fermer le formulaire de recherche pendant qu'on l'edite
function recherche_desesperement()
{
if (findObj('bandeaurecherche') && findObj('bandeaurecherche').style.visibility == 'visible')
{ ouvrir_recherche = true; }
else { ouvrir_recherche = false; }
changestyle('bandeauvide', 'visibility', 'hidden');
if (ouvrir_recherche == true)
{ changestyle('bandeaurecherche','visibility','visible'); }
}
......@@ -42,7 +42,7 @@ function exec_articles_dist()
}
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page("&laquo; ". $row['titre'] ." &raquo;", "naviguer", "articles", "", $row['id_rubrique']);
echo $commencer_page("&laquo; ". $row['titre'] ." &raquo;", "naviguer", "articles", $row['id_rubrique']);
echo debut_grand_cadre(true),
afficher_hierarchie($row['id_rubrique']),
......
......@@ -55,7 +55,7 @@ function exec_articles_forum_dist()
pipeline('exec_init',array('args'=>array('exec'=>'articles_forum','id_article'=>$id_article),'data'=>''));
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page($titre, "naviguer", "articles", "", $id_rubrique);
echo $commencer_page($titre, "naviguer", "articles", $id_rubrique);
articles_forum_cadres($id_rubrique, $id_article, $titre, 'articles', "id_article=$id_article");
......
......@@ -127,7 +127,7 @@ foreach ($textes as $var => $t) $$var = $t;
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page(_T('info_historique')." &laquo; $titre &raquo;", "naviguer", "articles", "", $id_rubrique);
echo $commencer_page(_T('info_historique')." &laquo; $titre &raquo;", "naviguer", "articles", $id_rubrique);
debut_grand_cadre();
......
......@@ -63,7 +63,7 @@ else {
pipeline('exec_init',array('args'=>array('exec'=>'breves_edit','id_breve'=>$id_breve),'data'=>''));
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page(_T('titre_page_breves_edit', array('titre' => $titre)), "naviguer", "breves", "", $id_rubrique);
echo $commencer_page(_T('titre_page_breves_edit', array('titre' => $titre)), "naviguer", "breves", $id_rubrique);
debut_grand_cadre();
......
......@@ -59,7 +59,7 @@ function afficher_breves_voir($id_breve, $changer_lang, $cherche_mot, $select_gr
);
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page("&laquo; $titre_breve &raquo;", "naviguer", "breves", "", $id_rubrique);
echo $commencer_page("&laquo; $titre_breve &raquo;", "naviguer", "breves", $id_rubrique);
debut_grand_cadre();
......
......@@ -59,7 +59,7 @@ function exec_rubriques_edit_dist()
pipeline('exec_init',array('args'=>array('exec'=>'rubriques_edit','id_rubrique'=>$id_rubrique),'data'=>''));
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page(_T('info_modifier_titre', array('titre' => $titre)), "naviguer", "rubriques", '', $id_rubrique);
echo $commencer_page(_T('info_modifier_titre', array('titre' => $titre)), "naviguer", "rubriques", $id_rubrique);
if ($id_parent == 0) $ze_logo = "secteur-24.gif";
else $ze_logo = "rubrique-24.gif";
......
......@@ -222,7 +222,7 @@ pipeline('exec_init',array('args'=>array('exec'=>'sites','id_syndic'=>$id_syndic
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page("$titre_page","naviguer","sites", "", $id_rubrique);
echo $commencer_page("$titre_page","naviguer","sites", $id_rubrique);
//////// parents
......
......@@ -43,7 +43,7 @@ else {
pipeline('exec_init',array('args'=>array('exec'=>'sites_edit','id_syndic'=>$id_syndic),'data'=>''));
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page(_T('info_site_reference_2'), "naviguer", "sites", "", $id_rubrique);
echo $commencer_page(_T('info_site_reference_2'), "naviguer", "sites", $id_rubrique);
debut_grand_cadre();
......
......@@ -418,7 +418,7 @@ function bandeau_principal2($rubrique, $sous_rubrique, $largeur) {
if($sousmenu) {
$offset = (int)round($decal-$coeff_decalage*max(0,($decal+count($sousmenu)*$largitem_moy-$largeur_maxi_menu)));
if ($offset<0){ $offset = 0; }
$res .= "<div class='$class' id='bandeau$page' style='position: absolute; $spip_lang_left: ".$offset."px;'><div class='bandeau_sec'><table class='gauche'><tr>\n";
$res .= "<div class='$class bandeau' id='bandeau$page' style='position: absolute; $spip_lang_left: ".$offset."px;'><div class='bandeau_sec'><table class='gauche'><tr>\n";
$width=0;
foreach($sousmenu as $souspage => $sousdetail) {
if ($width+1.25*$largitem_moy>$largeur_maxi_menu){$res .= "</tr><tr>\n";$width=0;}
......
......@@ -17,15 +17,15 @@ if (!defined("_ECRIRE_INC_VERSION")) return;
//
// http://doc.spip.org/@inc_commencer_page_dist
function inc_commencer_page_dist($titre = "", $rubrique = "accueil", $sous_rubrique = "accueil", $onLoad = "", $id_rubrique = "") {
function inc_commencer_page_dist($titre = "", $rubrique = "accueil", $sous_rubrique = "accueil", $id_rubrique = "") {
include_spip('inc/headers');
http_no_cache();
return init_entete($titre, $id_rubrique)
. init_body($rubrique, $sous_rubrique, $onLoad, $id_rubrique)
. "<center onmouseover='recherche_desesperement()'>" // ????
. init_body($rubrique, $sous_rubrique, $id_rubrique)
. "<div id='page' align='center'>"
. avertissement_messagerie()
. ((($rubrique == "messagerie") OR (_request('changer_config')!="oui"))
? auteurs_recemment_connectes() : '');
......@@ -53,6 +53,10 @@ function init_entete($titre='', $id_rubrique=0) {
<script type="text/javascript"><!--
$(document).ready(function(){
verifForm();
$("#page")
.mouseover(function(){
changestyle("garder-recherche");
});
'
.
repercuter_gadgets($id_rubrique)
......@@ -70,7 +74,7 @@ function init_entete($titre='', $id_rubrique=0) {
// fonction envoyant la double serie d'icones de redac
// http://doc.spip.org/@init_body
function init_body($rubrique='accueil', $sous_rubrique='accueil', $load='', $id_rubrique='') {
function init_body($rubrique='accueil', $sous_rubrique='accueil', $id_rubrique='') {
global $couleur_foncee, $couleur_claire;
global $connect_id_auteur, $connect_toutes_rubriques;
global $auth_can_disconnect;
......@@ -79,13 +83,11 @@ function init_body($rubrique='accueil', $sous_rubrique='accueil', $load='', $id_
if ($spip_ecran == "large") $largeur = 974; else $largeur = 750;
if ($load) $load = " onload=\"$load\"";
$res = pipeline('body_prive',"<body ". _ATTRIBUTES_BODY .$load . '>')
$res = pipeline('body_prive',"<body ". _ATTRIBUTES_BODY . '>')
. "\n<map name='map_layout'>"
. lien_change_var (self(), 'set_disp', 1, '1,0,18,15', _T('lien_afficher_texte_seul'), "onmouseover=\"changestyle('bandeauvide','visibility', 'visible');\"")
. lien_change_var (self(), 'set_disp', 2, '19,0,40,15', _T('lien_afficher_texte_icones'), "onmouseover=\"changestyle('bandeauvide','visibility', 'visible');\"")
. lien_change_var (self(), 'set_disp', 3, '41,0,59,15', _T('lien_afficher_icones_seuls'), "onmouseover=\"changestyle('bandeauvide','visibility', 'visible');\"")
. lien_change_var (self(), 'set_disp', 1, '1,0,18,15', _T('lien_afficher_texte_seul'), "onmouseover=\"changestyle('bandeauvide');\"")
. lien_change_var (self(), 'set_disp', 2, '19,0,40,15', _T('lien_afficher_texte_icones'), "onmouseover=\"changestyle('bandeauvide');\"")
. lien_change_var (self(), 'set_disp', 3, '41,0,59,15', _T('lien_afficher_icones_seuls'), "onmouseover=\"changestyle('bandeauvide');\"")
. "\n</map>";
if ($spip_display == "4") {
......@@ -111,31 +113,31 @@ function init_body($rubrique='accueil', $sous_rubrique='accueil', $load='', $id_
$res .= "\n<div style=\"max-height: 40px; width: 100%; border-bottom: solid 1px white;$style\">"
. "<table align='center' cellpadding='0' style='background: none;' width='$largeur'><tr>"
. "<td valign='middle' class='bandeau_couleur' style='text-align: $spip_lang_left;'>"
. "<a href='" . generer_url_ecrire("articles_tous") . "' class='icone26' onmouseover=\"changestyle('bandeautoutsite','visibility','visible');\">"
. "<a href='" . generer_url_ecrire("articles_tous") . "' class='icone26' onmouseover=\"changestyle('bandeautoutsite');\">"
. http_img_pack("tout-site.png", "", "width='26' height='20'") . "</a>";
if ($id_rubrique > 0)
$res .= "<a href='" . generer_url_ecrire("brouteur","id_rubrique=$id_rubrique") . "' class='icone26' onmouseover=\"changestyle('bandeaunavrapide','visibility','visible');\">" .
$res .= "<a href='" . generer_url_ecrire("brouteur","id_rubrique=$id_rubrique") . "' class='icone26' onmouseover=\"changestyle('bandeaunavrapide');\">" .
http_img_pack("naviguer-site.png", "", "width='26' height='20'") ."</a>";
else $res .= "<a href='" . generer_url_ecrire("brouteur") . "' class='icone26' onmouseover=\"changestyle('bandeaunavrapide','visibility','visible');\" >" .
else $res .= "<a href='" . generer_url_ecrire("brouteur") . "' class='icone26' onmouseover=\"changestyle('bandeaunavrapide');\" >" .
http_img_pack("naviguer-site.png", "", "width='26' height='20'") . "</a>";
$res .= "<a href='" . generer_url_ecrire("recherche") . "' class='icone26' onmouseover=\"changestyle('bandeaurecherche','visibility','visible'); findObj('form_recherche').focus();\" >" .
$res .= "<a href='" . generer_url_ecrire("recherche") . "' class='icone26' onmouseover=\"changestyle('bandeaurecherche'); findObj('form_recherche').focus();\" >" .
http_img_pack("loupe.png", "", "width='26' height='20'") ."</a>";
$res .= http_img_pack("rien.gif", " ", "width='10'");
$res .= "<a href='" . generer_url_ecrire("calendrier","type=semaine") . "' class='icone26' onmouseover=\"changestyle('bandeauagenda','visibility','visible');\">" .
$res .= "<a href='" . generer_url_ecrire("calendrier","type=semaine") . "' class='icone26' onmouseover=\"changestyle('bandeauagenda');\">" .
http_img_pack("cal-rv.png", "", "width='26' height='20'") ."</a>"
. "<a href='" . generer_url_ecrire("messagerie") . "' class='icone26' onmouseover=\"changestyle('bandeaumessagerie','visibility','visible');\">" .
. "<a href='" . generer_url_ecrire("messagerie") . "' class='icone26' onmouseover=\"changestyle('bandeaumessagerie');\">" .
http_img_pack("cal-messagerie.png", "", "width='26' height='20'") ."</a>"
. "<a href='" . generer_url_ecrire("synchro") . "' class='icone26' onmouseover=\"changestyle('bandeausynchro','visibility','visible');\">" .
. "<a href='" . generer_url_ecrire("synchro") . "' class='icone26' onmouseover=\"changestyle('bandeausynchro');\">" .
http_img_pack("cal-suivi.png", "", "width='26' height='20'") . "</a>";
if (!($connect_toutes_rubriques)) {
$res .= http_img_pack("rien.gif", " ", "width='10'");
$res .= "<a href='" . generer_url_ecrire("auteur_infos","id_auteur=$connect_id_auteur&initial=-1") . "' class='icone26' onmouseover=\"changestyle('bandeauinfoperso','visibility','visible');\">" .
http_img_pack("fiche-perso.png", "", "onmouseover=\"changestyle('bandeauvide','visibility', 'visible');\"");
$res .= "<a href='" . generer_url_ecrire("auteur_infos","id_auteur=$connect_id_auteur&initial=-1") . "' class='icone26' onmouseover=\"changestyle('bandeauinfoperso');\">" .
http_img_pack("fiche-perso.png", "", "onmouseover=\"changestyle();\"");
$res .= "</a>";
}
......@@ -166,7 +168,7 @@ function init_body($rubrique='accueil', $sous_rubrique='accueil', $load='', $id_
$lien = parametre_url(self(), 'set_options', 'basiques');
$icone = "interface-display.png";
}
$res .= "<a href='$lien' class='icone26' onmouseover=\"changestyle('bandeaudisplay','visibility', 'visible');\">"
$res .= "<a href='$lien' class='icone26' onmouseover=\"changestyle('bandeaudisplay');\">"
. http_img_pack($icone, "", "width='26' height='20'")."</a>"
. http_img_pack("rien.gif", " ", "width='10' height='1'")
......@@ -175,12 +177,12 @@ function init_body($rubrique='accueil', $sous_rubrique='accueil', $load='', $id_
// grand ecran
if ($spip_ecran == "large") {
$i = _T('info_petit_ecran');
$res .= "<a href='". parametre_url(self(),'set_ecran', 'etroit') ."' class='icone26' onmouseover=\"changestyle('bandeauecran','visibility', 'visible');\" title=\"$i\">" .
$res .= "<a href='". parametre_url(self(),'set_ecran', 'etroit') ."' class='icone26' onmouseover=\"changestyle('bandeauecran');\" title=\"$i\">" .
http_img_pack("set-ecran-etroit.png", $i, "width='26' height='20'") . "</a>";
$ecran = "<div><a href='".parametre_url(self(),'set_ecran', 'etroit')."' class='lien_sous'>"._T('info_petit_ecran')."</a>/<b>"._T('info_grand_ecran')."</b></div>";
} else {
$i = _T('info_grand_ecran');
$res .= "<a href='".parametre_url(self(),'set_ecran', 'large')."' class='icone26' onmouseover=\"changestyle('bandeauecran','visibility', 'visible');\" title=\"$i\">" .
$res .= "<a href='".parametre_url(self(),'set_ecran', 'large')."' class='icone26' onmouseover=\"changestyle('bandeauecran');\" title=\"$i\">" .
http_img_pack("set-ecran.png", $i, "width='26' height='20'") ."</a>";
$ecran = "<div><b>"._T('info_petit_ecran')."</b>/<a href='".parametre_url(self(),'set_ecran', 'large')."' class='lien_sous'>"._T('info_grand_ecran')."</a></div>";
}
......@@ -203,7 +205,7 @@ function init_body($rubrique='accueil', $sous_rubrique='accueil', $load='', $id_
if ($auth_can_disconnect) {
$res .= "<a href='".
generer_url_action("logout","logout=prive") .
"' class='icone26' onmouseover=\"changestyle('bandeaudeconnecter','visibility', 'visible');\">" .
"' class='icone26' onmouseover=\"changestyle('bandeaudeconnecter');\">" .
http_img_pack("deconnecter-24.gif", "", "") .
"</a>";
}
......
......@@ -1755,7 +1755,8 @@ function env_to_attributs ($texte){
// Inserer jQuery
// http://doc.spip.org/@f_jQuery
function f_jQuery ($texte) {
if (!_request('jquery_debug'))
if (!_request('jquery_debug')
AND _DIR_RESTREINT)
$js = "<script src=\""._DIR_JAVASCRIPT."jquery-1.0.2-forms.pack.js\" type=\"text/javascript\"></script>\n";
else
$js = "<script src=\""._DIR_JAVASCRIPT."jquery-1.0.2-forms.js\" type=\"text/javascript\"></script>\n";
......@@ -1763,15 +1764,11 @@ function f_jQuery ($texte) {
return $js.$texte;
}
// Concatenet des chaines
// Concatener des chaines
// #TEXTE|concat{texte1,texte2,...}
// http://doc.spip.org/@concat
function concat(){
$tous = func_get_args();
$texte = "";
foreach($tous as $arg)
$texte.=$arg;
return $texte;
return join('', func_get_args());
}
?>
\ No newline at end of file
......@@ -99,7 +99,7 @@ function gadget_rubriques() {
if ($count_lignes == $max_lignes) {
$count_lignes = 0;
$ret .= "</div></td><td valign='top' width='200'><div>&nbsp;</div><div class='bandeau_rubriques' style='z-index: 1;'>";
$ret .= "</div></td><td valign='top' width='200'><div>&nbsp;</div><div class='bandeau bandeau_rubriques' style='z-index: 1;'>";
}
$count_lignes ++;
......@@ -293,7 +293,7 @@ function bandeau_gadgets($largeur, $options, $id_rubrique) {
"\n<table width='$largeur' cellpadding='0' cellspacing='0' align='center'><tr><td>\n<div style='position: relative; z-index: 1000;'>"
// GADGET Menu rubriques
. "\n<div id='bandeautoutsite' class='bandeau_couleur_sous' style='$spip_lang_left: 0px;'>"
. "\n<div id='bandeautoutsite' class='bandeau bandeau_couleur_sous' style='$spip_lang_left: 0px;'>"
. "<a href='"
. generer_url_ecrire("articles_tous")
. "' class='lien_sous'"
......@@ -309,7 +309,7 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
// GADGET Navigation rapide
$bandeau .= "<div id='bandeaunavrapide' class='bandeau_couleur_sous' style='$spip_lang_left: 30px;'>"
$bandeau .= "<div id='bandeaunavrapide' class='bandeau bandeau_couleur_sous' style='$spip_lang_left: 30px;'>"
. "<a href='" . generer_url_ecrire("brouteur", ($id_rubrique ? "id_rubrique=$id_rubrique" : '')) . "' class='lien_sous'>" . _T('icone_brouteur') . "</a>"
. "<div id='gadget-navigation'></div>\n"
. "</div>\n";
......@@ -318,7 +318,7 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
// GADGET Recherche
// attribut non conforme ==> le generer dynamiquement
$js = 'this.setAttribute(\'autocomplete\', \'off\')';
$bandeau .= "<div id='bandeaurecherche' class='bandeau_couleur_sous' style='$spip_lang_left: 60px;'>"
$bandeau .= "<div id='bandeaurecherche' class='bandeau bandeau_couleur_sous' style='$spip_lang_left: 60px;'>"
. "<form method='get' style='margin: 0px; position: relative;' action='"
. generer_url_ecrire("recherche")
. "'>"
......@@ -331,7 +331,7 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
// FIN GADGET recherche
// GADGET Agenda
$bandeau .= "<div id='bandeauagenda' class='bandeau_couleur_sous' style='$spip_lang_left: 100px;'>"
$bandeau .= "<div id='bandeauagenda' class='bandeau bandeau_couleur_sous' style='$spip_lang_left: 100px;'>"
. "<a href='" . generer_url_ecrire("calendrier","type=semaine") . "' class='lien_sous'>"
. _T('icone_agenda')
. "</a>"
......@@ -342,7 +342,7 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
// GADGET Messagerie
$gadget = '';
$gadget .= "<div id='bandeaumessagerie' class='bandeau_couleur_sous' style='$spip_lang_left: 130px;'>";
$gadget .= "<div id='bandeaumessagerie' class='bandeau bandeau_couleur_sous' style='$spip_lang_left: 130px;'>";
$gadget .= "<a href='" . generer_url_ecrire("messagerie") . "' class='lien_sous'>";
$gadget .= _T('icone_messagerie_personnelle');
$gadget .= "</a>";
......@@ -355,7 +355,7 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
// Suivi activite
$bandeau .= "<div id='bandeausynchro' class='bandeau_couleur_sous' style='$spip_lang_left: 160px;'>";
$bandeau .= "<div id='bandeausynchro' class='bandeau bandeau_couleur_sous' style='$spip_lang_left: 160px;'>";
$bandeau .= "<a href='" . generer_url_ecrire("synchro") . "' class='lien_sous'>";
$bandeau .= _T('icone_suivi_activite');
$bandeau .= "</a>";
......@@ -363,7 +363,7 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
$bandeau .= "</div>";
// Infos perso
$bandeau .= "<div id='bandeauinfoperso' class='bandeau_couleur_sous' style='$spip_lang_left: 200px;'>";
$bandeau .= "<div id='bandeauinfoperso' class='bandeau bandeau_couleur_sous' style='$spip_lang_left: 200px;'>";
$bandeau .= "<a href='" . generer_url_ecrire("auteurs_edit","id_auteur=$connect_id_auteur") . "' class='lien_sous'>";
$bandeau .= _T('icone_informations_personnelles');
$bandeau .= "</a>";
......@@ -374,20 +374,20 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
// -------- Affichage de droite ----------
// Deconnection
$bandeau .= "<div class='bandeau_couleur_sous' id='bandeaudeconnecter' style='$spip_lang_right: 0px;'>";
$bandeau .= "<div class='bandeau bandeau_couleur_sous' id='bandeaudeconnecter' style='$spip_lang_right: 0px;'>";
$bandeau .= "<a href='" . generer_url_action("logout","logout=prive") . "' class='lien_sous'>"._T('icone_deconnecter')."</a>".aide("deconnect");
$bandeau .= "</div>";
$decal = 0;
$decal = $decal + 150;
$bandeau .= "<div id='bandeauinterface' class='bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right;'>";
$bandeau .= "<div id='bandeauinterface' class='bandeau bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right;'>";
$bandeau .= _T('titre_changer_couleur_interface');
$bandeau .= "</div>";
$decal = $decal + 70;
$bandeau .= "<div id='bandeauecran' class='bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right;'>";
$bandeau .= "<div id='bandeauecran' class='bandeau bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right;'>";
if ($spip_ecran == "large")
$bandeau .= "<div><a href='".parametre_url(self(),'set_ecran', 'etroit')."' class='lien_sous'>"._T('info_petit_ecran')."</a>/<b>"._T('info_grand_ecran')."</b></div>";
else
......@@ -398,11 +398,11 @@ onmouseover=\"findObj_forcer('bandeautoutsite').style.visibility='visible'; char
// En interface simplifiee, afficher en permanence l'indication de l'interface
if ($options != "avancees") {
$bandeau .= "<div id='displayfond' class='bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right; visibility: visible; background-color: white; color: $couleur_foncee; z-index: -1000; border: 1px solid $couleur_claire; border-top: 0px;'>";
$bandeau .= "<div id='displayfond' class='bandeau bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right; visibility: visible; background-color: white; color: $couleur_foncee; z-index: -1000; border: 1px solid $couleur_claire; border-top: 0px;'>";
$bandeau .= "<b>"._T('icone_interface_simple')."</b>";
$bandeau .= "</div>";
}
$bandeau .= "<div id='bandeaudisplay' class='bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right;'>";
$bandeau .= "<div id='bandeaudisplay' class='bandeau bandeau_couleur_sous' style='$spip_lang_right: ".$decal."px; text-align: $spip_lang_right;'>";
if ($options != 'avancees') {
$bandeau .= "<b>"._T('icone_interface_simple')."</b>/<a href='".parametre_url(self(),'set_options', 'avancees')."' class='lien_sous'>"._T('icone_interface_complet')."</a>";
......
......@@ -24,8 +24,8 @@ function choix_couleur() {
$res = '';
if ($couleurs_spip) {
foreach ($couleurs_spip as $key => $val) {
$res = "<a href=\"".parametre_url(self(), 'set_couleur', $key)."\">" .
http_img_pack("rien.gif", " ", "width='8' height='8' style='margin: 1px; background-color: ".$val['couleur_claire'].";' onmouseover=\"changestyle('bandeauinterface','visibility', 'visible');\""). "</a>";
$res .= "<a href=\"".parametre_url(self(), 'set_couleur', $key)."\">" .
http_img_pack("rien.gif", " ", "width='8' height='8' style='margin: 1px; background-color: ".$val['couleur_claire'].";' onmouseover=\"changestyle('bandeauinterface');\""). "</a>";
}
}
return $res;
......@@ -1357,7 +1357,6 @@ function debut_javascript($admin, $stat)
http_script(
$tester_javascript .
"\nvar ajax_image_searching = '<div style=\"float: ".$GLOBALS['spip_lang_right'].";\"><img src=\"".url_absolue(_DIR_IMG_PACK."searching.gif")."\" /></div>';" .
"\nvar admin = " . ($admin ? 1 : 0) .
"\nvar stat = " . ($stat ? 1 : 0) .
"\nvar largeur_icone = " .
intval(_LARGEUR_ICONES_BANDEAU) .
......@@ -1795,7 +1794,7 @@ function fin_page() {
. '</div>'))
. fin_grand_cadre(true)
. "</center>"
. "</div>" // cf. <div center> ouverte dans conmmencer_page()
. $GLOBALS['rejoue_session']
. generer_spip_cron()
. (defined('_TESTER_NOSCRIPT') ? _TESTER_NOSCRIPT : '')
......
......@@ -145,9 +145,10 @@ function bandeau_titre_boite($titre, $afficher_auteurs, $boite_importante = true
}
// http://doc.spip.org/@debut_page
function debut_page($titre = "", $rubrique = "accueil", $sous_rubrique = "accueil", $onLoad = "", $id_rubrique = "") {
function debut_page($titre = "", $rubrique = "accueil", $sous_rubrique = "accueil", $onLoad = "" /* ignore */, $id_rubrique = "") {
$commencer_page = charger_fonction('commencer_page', 'inc');
echo $commencer_page($titre, $rubrique, $sous_rubrique, $onLoad, $id_rubrique);
echo $commencer_page($titre, $rubrique, $sous_rubrique, $id_rubrique);
if ($onLoad) spip_log("parametre obsolete onLoad=$onLoad");
}
?>
\ No newline at end of file
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter