Rename xorg_ constants to pl_
authorFlorent Bruneau <florent.bruneau@polytechnique.org>
Sun, 22 Jun 2008 13:01:04 +0000 (15:01 +0200)
committerFlorent Bruneau <florent.bruneau@polytechnique.org>
Sun, 22 Jun 2008 13:01:04 +0000 (15:01 +0200)
Signed-off-by: Florent Bruneau <florent.bruneau@polytechnique.org>
26 files changed:
core/classes/plpage.php
core/classes/plwizard.php
include/wiki/engine.php
modules/admin.php
modules/auth.php
modules/axletter.php
modules/carnet.php
modules/email.php
modules/events.php
modules/forums.php
modules/geoloc.php
modules/googleapps.php
modules/lists.php
modules/marketing.php
modules/newsletter.php
modules/payment.php
modules/platal.php
modules/profile.php
modules/search.php
modules/search/classes.inc.php
templates/payment/index.tpl
templates/search/index.tpl
templates/skin/common.content.tpl
templates/skin/common.header.tpl
templates/skin/common.triggers.tpl
templates/xnet/skin.tpl

index 7b0161e..5230036 100644 (file)
@@ -55,7 +55,7 @@ abstract class PlPage extends Smarty
 
         if ($globals->mode != 'rw') {
             $this->trigError("En raison d'une maintenance, une partie des fonctionnalités du site sont"
-                      . " actuellement désactivée, en particuliers aucune donnée ne sera sauvegardée");
+                             . " actuellement désactivée, en particuliers aucune donnée ne sera sauvegardée");
         }
         $this->register_prefilter('at_to_globals');
         $this->addJsLink('xorg.js');
@@ -67,9 +67,9 @@ abstract class PlPage extends Smarty
 
     public function changeTpl($tpl, $type = SKINNED)
     {
-      $this->_tpl       = $tpl;
-      $this->_page_type = $type;
-      $this->assign('xorg_tpl', $tpl);
+        $this->_tpl       = $tpl;
+        $this->_page_type = $type;
+        $this->assign('pl_tpl', $tpl);
     }
 
     // }}}
@@ -95,9 +95,9 @@ abstract class PlPage extends Smarty
         $this->register_prefilter('form_force_encodings');
         $this->register_prefilter('wiki_include');
         $this->register_prefilter('if_has_perms');
-        $this->assign('xorg_triggers', $this->_errors);
-        $this->assign('xorg_errors', $this->nb_errs());
-        $this->assign('xorg_failure', $this->_failure);
+        $this->assign('pl_triggers', $this->_errors);
+        $this->assign('pl_errors', $this->nb_errs());
+        $this->assign('pl_failure', $this->_failure);
         $this->assign_by_ref('globals', $globals);
 
         if (Env::has('json') && count($this->_jsonVars)) {
@@ -236,7 +236,7 @@ abstract class PlPage extends Smarty
 
     public function addJsLink($path)
     {
-        $this->append('xorg_js', $path);
+        $this->append('pl_js', $path);
     }
 
     // }}}
@@ -244,7 +244,7 @@ abstract class PlPage extends Smarty
 
     public function addCssLink($path)
     {
-        $this->append('xorg_css', $path);
+        $this->append('pl_css', $path);
     }
 
     // }}}
@@ -253,7 +253,7 @@ abstract class PlPage extends Smarty
     public function addCssInline($css)
     {
         if (!empty($css)) {
-            $this->append('xorg_inline_css', $css);
+            $this->append('pl_inline_css', $css);
         }
     }
 
@@ -262,7 +262,7 @@ abstract class PlPage extends Smarty
 
     public function setRssLink($title, $path)
     {
-        $this->assign('xorg_rss', array('title' => $title, 'href' => $path));
+        $this->assign('pl_rss', array('title' => $title, 'href' => $path));
     }
 
     // }}}
@@ -347,27 +347,27 @@ function _to_globals($s) {
 function at_to_globals($tpl_source, &$smarty)
 {
     return preg_replace('/#globals\.([a-zA-Z0-9_.]+?)#/e', '_to_globals(\'\\1\')', $tpl_source);
-}
+                        }
 
-// }}}
-// {{{  function trimwhitespace
+                        // }}}
+                        // {{{  function trimwhitespace
 
-function trimwhitespace($source, &$smarty)
-{
-    $tags = '(script|pre|textarea)';
-    preg_match_all("!<$tags.*?>.*?</(\\1)>!ius", $source, $tagsmatches);
-    $source = preg_replace("!<$tags.*?>.*?</(\\1)>!ius", "&&&tags&&&", $source);
+                        function trimwhitespace($source, &$smarty)
+                        {
+                        $tags = '(script|pre|textarea)';
+                        preg_match_all("!<$tags.*?>.*?</(\\1)>!ius", $source, $tagsmatches);
+                        $source = preg_replace("!<$tags.*?>.*?</(\\1)>!ius", "&&&tags&&&", $source);
 
-    // remove all leading spaces, tabs and carriage returns NOT
-    // preceeded by a php close tag.
-    $source = preg_replace('/((?<!\?>)\n)[\s]+/m', '\1', $source);
-    $source = preg_replace("!&&&tags&&&!e",  'array_shift($tagsmatches[0])', $source);
+                        // remove all leading spaces, tabs and carriage returns NOT
+                        // preceeded by a php close tag.
+                        $source = preg_replace('/((?<!\?>)\n)[\s]+/m', '\1', $source);
+                        $source = preg_replace("!&&&tags&&&!e",  'array_shift($tagsmatches[0])', $source);
 
-    return $source;
-}
+                        return $source;
+                        }
 
-// }}}
-// {{{ function wiki_include
+                        // }}}
+                        // {{{ function wiki_include
 
 function wiki_include($source, &$smarty)
 {
@@ -382,11 +382,11 @@ function wiki_include($source, &$smarty)
 function if_has_perms($source, &$smarty)
 {
     $source = preg_replace('/\{if([^}]*) (\!?)hasPerms\(([^)]+)\)([^}]*)\}/',
-                           '{if\1 \2$smarty.session.perms->hasFlagCombination(\3)\4}',
-                           $source);
-    return preg_replace('/\{if([^}]*) (\!?)hasPerm\(([^)]+)\)([^}]*)\}/',
-                        '{if\1 \2($smarty.session.perms && $smarty.session.perms->hasFlag(\3))\4}',
-                        $source);
+    '{if\1 \2$smarty.session.perms->hasFlagCombination(\3)\4}',
+    $source);
+return preg_replace('/\{if([^}]*) (\!?)hasPerm\(([^)]+)\)([^}]*)\}/',
+       '{if\1 \2($smarty.session.perms && $smarty.session.perms->hasFlag(\3))\4}',
+       $source);
 }
 
 // }}}
@@ -406,8 +406,8 @@ function _hide_email($source)
 {
     $source = str_replace("\n", '', $source);
     return '<script type="text/javascript">//<![CDATA[' . "\n" .
-           'Nix.decode("' . addslashes(str_rot13($source)) . '");' . "\n" .
-           '//]]></script>';
+        'Nix.decode("' . addslashes(str_rot13($source)) . '");' . "\n" .
+        '//]]></script>';
 }
 
 function hide_emails($source, &$smarty)
index 48117d5..e12eec7 100644 (file)
@@ -210,7 +210,7 @@ class PlWizard
         $smarty->assign('wiz_ajax', $this->ajax);
         $smarty->assign('tab_width', (int)(99 / count($this->pages)));
         $smarty->assign('wiz_page', $page->template());
-        $smarty->assign('xorg_no_errors', true);
+        $smarty->assign('pl_no_errors', true);
         $page->prepare($smarty, isset($this->inv_lookup[$curpage]) ? $this->inv_lookup[$curpage] : $curpage);
     }
 }
index f8c01fc..fb3a61e 100644 (file)
@@ -97,7 +97,7 @@ if ($feed) {
     pl_clear_errors();
     exit;
 } elseif (Env::v('action')) {
-    $page->assign('xorg_extra_header', substr($wikiAll, 0, $i));
+    $page->assign('pl_extra_header', substr($wikiAll, 0, $i));
     $wikiAll = substr($wikiAll, $j);
 } else {
     if (!$cache_exists && $wiki_exists) {
index e9159d9..f6ef19d 100644 (file)
@@ -59,13 +59,13 @@ class AdminModule extends PLModule
     function handler_default(&$page)
     {
         $page->changeTpl('admin/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration');
+        $page->assign('pl_title','Polytechnique.org - Administration');
     }
 
     function handler_postfix_delayed(&$page)
     {
         $page->changeTpl('admin/postfix_delayed.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Postfix : Retardés');
+        $page->assign('pl_title','Polytechnique.org - Administration - Postfix : Retardés');
 
         if (Env::has('del')) {
             $crc = Env::v('crc');
@@ -90,7 +90,7 @@ class AdminModule extends PLModule
 
     function handler_postfix_regexpsbounces(&$page, $new = null) {
         $page->changeTpl('admin/emails_bounces_re.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Postfix : Regexps Bounces');
+        $page->assign('pl_title','Polytechnique.org - Administration - Postfix : Regexps Bounces');
         $page->assign('new', $new);
 
         if (Post::has('submit')) {
@@ -347,14 +347,14 @@ class AdminModule extends PLModule
 
         $page->changeTpl('admin/logger-view.tpl');
 
-        $page->assign('xorg_title','Polytechnique.org - Administration - Logs des sessions');
+        $page->assign('pl_title','Polytechnique.org - Administration - Logs des sessions');
     }
 
     function handler_user(&$page, $login = false)
     {
         global $globals;
         $page->changeTpl('admin/utilisateurs.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Edit/Su/Log');
+        $page->assign('pl_title','Polytechnique.org - Administration - Edit/Su/Log');
         require_once("emails.inc.php");
         require_once("user.func.inc.php");
 
@@ -733,7 +733,7 @@ class AdminModule extends PLModule
 
     function handler_homonyms(&$page, $op = 'list', $target = null) {
         $page->changeTpl('admin/homonymes.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Homonymes');
+        $page->assign('pl_title','Polytechnique.org - Administration - Homonymes');
         require_once("homonymes.inc.php");
 
         if ($target) {
@@ -796,7 +796,7 @@ class AdminModule extends PLModule
 
     function handler_ax_xorg(&$page) {
         $page->changeTpl('admin/ax-xorg.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - AX/X.org');
+        $page->assign('pl_title','Polytechnique.org - Administration - AX/X.org');
 
         // liste des différences
         $res = XDB::query(
@@ -824,7 +824,7 @@ class AdminModule extends PLModule
 
     function handler_deaths(&$page, $promo = 0, $validate = false) {
         $page->changeTpl('admin/deces_promo.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Deces');
+        $page->assign('pl_title','Polytechnique.org - Administration - Deces');
 
         if (!$promo)
             $promo = Env::i('promo');
@@ -864,7 +864,7 @@ class AdminModule extends PLModule
 
     function handler_dead_but_active(&$page) {
         $page->changeTpl('admin/dead_but_active.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Décédés');
+        $page->assign('pl_title','Polytechnique.org - Administration - Décédés');
 
         $res = XDB::iterator(
                 "SELECT  u.promo, u.nom, u.prenom, u.deces, u.matricule_ax, a.alias, DATE(MAX(s.start)) AS last
@@ -879,7 +879,7 @@ class AdminModule extends PLModule
 
     function handler_synchro_ax(&$page, $user = null, $action = null) {
         $page->changeTpl('admin/synchro_ax.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Synchro AX');
+        $page->assign('pl_title','Polytechnique.org - Administration - Synchro AX');
 
         require_once('synchro_ax.inc.php');
 
@@ -927,7 +927,7 @@ class AdminModule extends PLModule
     function handler_validate(&$page, $action = 'list', $id = null)
     {
         $page->changeTpl('admin/valider.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Valider une demande');
+        $page->assign('pl_title','Polytechnique.org - Administration - Valider une demande');
                 $page->addCssLink('nl.css');
         $page->addJsLink('ajax.js');
         require_once("validations.inc.php");
@@ -974,7 +974,7 @@ class AdminModule extends PLModule
     }
 
     function handler_validate_answers(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Réponses automatiques de validation');
+        $page->assign('pl_title','Polytechnique.org - Administration - Réponses automatiques de validation');
         $page->assign('title', 'Gestion des réponses automatiques');
         $table_editor = new PLTableEditor('admin/validate/answers','requests_answers','id');
         $table_editor->describe('category','catégorie',true);
@@ -983,7 +983,7 @@ class AdminModule extends PLModule
         $table_editor->apply($page, $action, $id);
     }
     function handler_skins(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Skins');
+        $page->assign('pl_title','Polytechnique.org - Administration - Skins');
         $page->assign('title', 'Gestion des skins');
         $table_editor = new PLTableEditor('admin/skins','skins','id');
         $table_editor->describe('name','nom',true);
@@ -996,7 +996,7 @@ class AdminModule extends PLModule
     }
 
     function handler_postfix_blacklist(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Postfix : Blacklist');
+        $page->assign('pl_title','Polytechnique.org - Administration - Postfix : Blacklist');
         $page->assign('title', 'Blacklist de postfix');
         $table_editor = new PLTableEditor('admin/postfix/blacklist','postfix_blacklist','email', true);
         $table_editor->describe('reject_text','Texte de rejet',true);
@@ -1004,14 +1004,14 @@ class AdminModule extends PLModule
         $table_editor->apply($page, $action, $id);
     }
     function handler_postfix_whitelist(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Postfix : Whitelist');
+        $page->assign('pl_title','Polytechnique.org - Administration - Postfix : Whitelist');
         $page->assign('title', 'Whitelist de postfix');
         $table_editor = new PLTableEditor('admin/postfix/whitelist','postfix_whitelist','email', true);
         $table_editor->describe('email','email',true);
         $table_editor->apply($page, $action, $id);
     }
     function handler_mx_broken(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title', 'Polytechnique.org - Administration - MX Défaillants');
+        $page->assign('pl_title', 'Polytechnique.org - Administration - MX Défaillants');
         $page->assign('title', 'MX Défaillant');
         $table_editor = new PLTableEditor('admin/mx/broken', 'mx_watch', 'host', true);
         $table_editor->describe('host', 'Masque', true);
@@ -1020,7 +1020,7 @@ class AdminModule extends PLModule
         $table_editor->apply($page, $action, $id);
     }
     function handler_logger_actions(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Actions');
+        $page->assign('pl_title','Polytechnique.org - Administration - Actions');
         $page->assign('title', 'Gestion des actions de logger');
         $table_editor = new PLTableEditor('admin/logger/actions','logger.actions','id');
         $table_editor->describe('text','intitulé',true);
@@ -1028,7 +1028,7 @@ class AdminModule extends PLModule
         $table_editor->apply($page, $action, $id);
     }
     function handler_downtime(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Coupures');
+        $page->assign('pl_title','Polytechnique.org - Administration - Coupures');
         $page->assign('title', 'Gestion des coupures');
         $table_editor = new PLTableEditor('admin/downtime','coupures','id');
         $table_editor->describe('debut','date',true);
index 885d5a9..d6521e1 100644 (file)
@@ -174,7 +174,7 @@ class AuthModule extends PLModule
 
     function handler_admin_authgroupesx(&$page, $action = 'list', $id = null)
     {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Auth groupes X');
+        $page->assign('pl_title','Polytechnique.org - Administration - Auth groupes X');
         $page->assign('title', 'Gestion de l\'authentification centralisée');
         $table_editor = new PLTableEditor('admin/auth-groupes-x','groupesx_auth','id');
         $table_editor->describe('name','nom',true);
index 270e2ca..caad25c 100644 (file)
@@ -53,7 +53,7 @@ class AXLetterModule extends PLModule
         require_once dirname(__FILE__) . '/axletter/axletter.inc.php';
 
         $page->changeTpl('axletter/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Envois de l\'AX');
+        $page->assign('pl_title','Polytechnique.org - Envois de l\'AX');
 
         switch ($action) {
           case 'in':  AXLetter::subscribe(); break;
index 417c983..18ec3dd 100644 (file)
@@ -56,7 +56,7 @@ class CarnetModule extends PLModule
     function handler_index(&$page)
     {
         $page->changeTpl('carnet/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Mon carnet');
+        $page->assign('pl_title','Polytechnique.org - Mon carnet');
         $this->_add_rss_link($page);
     }
 
@@ -202,7 +202,7 @@ class CarnetModule extends PLModule
 
     function handler_contacts(&$page, $action = null, $subaction = null, $ssaction = null)
     {
-        $page->assign('xorg_title','Polytechnique.org - Mes contacts');
+        $page->assign('pl_title','Polytechnique.org - Mes contacts');
         $this->_add_rss_link($page);
 
         $uid  = S::v('uid');
index f3fc4f4..a992963 100644 (file)
@@ -47,7 +47,7 @@ class EmailModule extends PLModule
         require_once 'emails.inc.php';
 
         $page->changeTpl('emails/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Mes emails');
+        $page->assign('pl_title','Polytechnique.org - Mes emails');
 
         $uid = S::v('uid');
 
@@ -98,7 +98,7 @@ class EmailModule extends PLModule
         global $globals;
 
         $page->changeTpl('emails/alias.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Alias melix.net');
+        $page->assign('pl_title','Polytechnique.org - Alias melix.net');
 
         $uid     = S::v('uid');
         $forlife = S::v('forlife');
@@ -328,7 +328,7 @@ class EmailModule extends PLModule
         $page->changeTpl('emails/send.tpl');
         $page->addJsLink('ajax.js');
 
-        $page->assign('xorg_title','Polytechnique.org - Envoyer un email');
+        $page->assign('pl_title','Polytechnique.org - Envoyer un email');
 
         // action si on recoit un formulaire
         if (Post::has('save')) {
index 29c74e9..5587ac3 100644 (file)
@@ -327,7 +327,7 @@ class EventsModule extends PLModule
 
     function handler_admin_tips(&$page, $action = 'list', $id = null)
     {
-        $page->assign('xorg_title', 'Polytechnique.org - Administration - Astuces');
+        $page->assign('pl_title', 'Polytechnique.org - Administration - Astuces');
         $page->assign('title', 'Gestion des Astuces');
         $table_editor = new PLTableEditor('admin/tips', 'tips', 'id');
         $table_editor->describe('peremption', 'date de péremption', true);
@@ -348,7 +348,7 @@ class EventsModule extends PLModule
     {
         $page->changeTpl('events/admin.tpl');
         $page->addJsLink('ajax.js');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Evenements');
+        $page->assign('pl_title','Polytechnique.org - Administration - Evenements');
         $page->register_modifier('hde', 'html_entity_decode');
 
         $arch = $action == 'archives';
index c9538c9..284ce84 100644 (file)
@@ -59,7 +59,7 @@ class ForumsModule extends PLModule
     function handler_banana(&$page, $group = null, $action = null, $artid = null)
     {
         $page->changeTpl('banana/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Forums & PA');
+        $page->assign('pl_title','Polytechnique.org - Forums & PA');
 
         $get = Array();
         if (Post::has('updateall')) {
@@ -97,7 +97,7 @@ class ForumsModule extends PLModule
 
     function handler_forums_bans(&$page, $action = 'list', $id = null)
     {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Bannissements des forums');
+        $page->assign('pl_title','Polytechnique.org - Administration - Bannissements des forums');
         $page->assign('title', 'Gestion des mises au ban');
         $table_editor = new PLTableEditor('admin/forums','forums.innd','id_innd');
         $table_editor->add_sort_field('priority', true, true);
@@ -113,7 +113,7 @@ class ForumsModule extends PLModule
     static function run_banana(&$page, $params = null)
     {
         $page->changeTpl('banana/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Forums & PA');
+        $page->assign('pl_title','Polytechnique.org - Forums & PA');
 
         require_once 'banana/forum.inc.php';
         run_banana($page, 'ForumsBanana', $params);
index 895c5f4..08b42fa 100644 (file)
@@ -42,7 +42,7 @@ class GeolocModule extends PLModule
     function handler_admin(&$page, $action = false) {
         $page->changeTpl('geoloc/admin.tpl');
         require_once("geoloc.inc.php");
-        $page->assign('xorg_title','Polytechnique.org - Administration - Geolocalisation');
+        $page->assign('pl_title','Polytechnique.org - Administration - Geolocalisation');
 
         $nb_synchro = 0;
 
@@ -100,7 +100,7 @@ class GeolocModule extends PLModule
         $noCoordinates = $countNoCoordinates->fetchOneCell();
 
         if (isset($refresh) && $missing) {
-            $page->assign("xorg_extra_header", "<meta http-equiv='Refresh' content='3'/>");
+            $page->assign("pl_extra_header", "<meta http-equiv='Refresh' content='3'/>");
         }
         $page->assign("nb_cities_not_on_map", $missing);
         $page->assign("no_smallest", $noSmallest);
index fcfb153..eeaffb6 100644 (file)
@@ -42,7 +42,7 @@ class GoogleAppsModule extends PLModule
         require_once("googleapps.inc.php");
         $page->changeTpl('googleapps/index.tpl');
         $page->addJsLink('motdepasse.js');
-        $page->assign('xorg_title', 'Polytechnique.org - Compte Google Apps');
+        $page->assign('pl_title', 'Polytechnique.org - Compte Google Apps');
 
         $account = new GoogleAppsAccount(S::v('uid'), S::v('forlife'));
 
@@ -117,7 +117,7 @@ class GoogleAppsModule extends PLModule
     function handler_admin(&$page, $action = null) {
         require_once("googleapps.inc.php");
         $page->changeTpl('googleapps/admin.tpl');
-        $page->assign('xorg_title', 'Polytechnique.org - Administration Google Apps');
+        $page->assign('pl_title', 'Polytechnique.org - Administration Google Apps');
         $page->assign('googleapps_admin', GoogleAppsAccount::is_administrator(S::v('uid')));
 
         if ($action == 'ack') {
@@ -163,7 +163,7 @@ class GoogleAppsModule extends PLModule
     function handler_admin_job(&$page, $job = null) {
         require_once("googleapps.inc.php");
         $page->changeTpl('googleapps/admin.job.tpl');
-        $page->assign('xorg_title', 'Polytechnique.org - Administration Google Apps');
+        $page->assign('pl_title', 'Polytechnique.org - Administration Google Apps');
         $page->assign('googleapps_admin', GoogleAppsAccount::is_administrator(S::v('uid')));
 
         if ($job) {
@@ -183,7 +183,7 @@ class GoogleAppsModule extends PLModule
         require_once("emails.inc.php");
         require_once("googleapps.inc.php");
         $page->changeTpl('googleapps/admin.user.tpl');
-        $page->assign('xorg_title', 'Polytechnique.org - Administration Google Apps');
+        $page->assign('pl_title', 'Polytechnique.org - Administration Google Apps');
         $page->assign('googleapps_admin', GoogleAppsAccount::is_administrator(S::v('uid')));
 
         if (!$user && Post::has('login')) {
index 4012711..9bdba57 100644 (file)
@@ -94,7 +94,7 @@ class ListsModule extends PLModule
 
         $page->changeTpl('lists/index.tpl');
         $page->addJsLink('ajax.js');
-        $page->assign('xorg_title','Polytechnique.org - Listes de diffusion');
+        $page->assign('pl_title','Polytechnique.org - Listes de diffusion');
 
 
         if (Get::has('del')) {
@@ -805,7 +805,7 @@ class ListsModule extends PLModule
 
     function handler_admin_all(&$page) {
         $page->changeTpl('lists/admin_all.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Mailing lists');
+        $page->assign('pl_title','Polytechnique.org - Administration - Mailing lists');
 
         $client = new MMList(S::v('uid'), S::v('password'));
         $listes = $client->get_all_lists();
index 83dcd89..0500fe1 100644 (file)
@@ -40,7 +40,7 @@ class MarketingModule extends PLModule
     {
         $page->changeTpl('marketing/index.tpl');
 
-        $page->assign('xorg_title','Polytechnique.org - Marketing');
+        $page->assign('pl_title','Polytechnique.org - Marketing');
 
         // Quelques statistiques
 
index 5a41e9a..46cc935 100644 (file)
@@ -38,7 +38,7 @@ class NewsletterModule extends PLModule
         require_once 'newsletter.inc.php';
 
         $page->changeTpl('newsletter/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Lettres mensuelles');
+        $page->assign('pl_title','Polytechnique.org - Lettres mensuelles');
 
         switch ($action) {
           case 'out': Newsletter::unsubscribe(); break;
@@ -97,7 +97,7 @@ class NewsletterModule extends PLModule
 
     function handler_admin_nl(&$page, $new = false) {
         $page->changeTpl('newsletter/admin.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Newsletter : liste');
+        $page->assign('pl_title','Polytechnique.org - Administration - Newsletter : liste');
         require_once("newsletter.inc.php");
 
         if($new) {
@@ -111,7 +111,7 @@ class NewsletterModule extends PLModule
     function handler_admin_nl_edit(&$page, $nid = 'last', $aid = null, $action = 'edit') {
         $page->changeTpl('newsletter/edit.tpl');
         $page->addCssLink('nl.css');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Newsletter : Edition');
+        $page->assign('pl_title','Polytechnique.org - Administration - Newsletter : Edition');
         require_once("newsletter.inc.php");
 
         $nl  = new NewsLetter($nid);
@@ -157,7 +157,7 @@ class NewsletterModule extends PLModule
     }
 
     function handler_admin_nl_cat(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Newsletter : Catégories');
+        $page->assign('pl_title','Polytechnique.org - Administration - Newsletter : Catégories');
         $page->assign('title', 'Gestion des catégories de la newsletter');
         $table_editor = new PLTableEditor('admin/newsletter/categories','newsletter_cat','cid');
         $table_editor->describe('titre','intitulé',true);
index f3fcbcf..38c34f5 100644 (file)
@@ -120,7 +120,7 @@ class PaymentModule extends PLModule
             }
         }
         $page->changeTpl('payment/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Télépaiements');
+        $page->assign('pl_title','Polytechnique.org - Télépaiements');
 
         // initialisation
         $op   = Env::v('op', 'select');
@@ -467,7 +467,7 @@ class PaymentModule extends PLModule
     }
 
     function handler_admin(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Paiements');
+        $page->assign('pl_title','Polytechnique.org - Administration - Paiements');
         $page->assign('title', 'Gestion des télépaiements');
         $table_editor = new PLTableEditor('admin/payments','paiement.paiements','id');
         $table_editor->add_join_table('paiement.transactions','ref',true);
index e4e7aa0..092d63e 100644 (file)
@@ -122,7 +122,7 @@ class PlatalModule extends PLModule
     function handler_prefs(&$page)
     {
         $page->changeTpl('platal/preferences.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Mes préférences');
+        $page->assign('pl_title','Polytechnique.org - Mes préférences');
 
         if (Post::has('mail_fmt')) {
             $fmt = Post::v('mail_fmt');
@@ -143,7 +143,7 @@ class PlatalModule extends PLModule
     {
         $page->changeTpl('platal/webredirect.tpl');
 
-        $page->assign('xorg_title','Polytechnique.org - Redirection de page WEB');
+        $page->assign('pl_title','Polytechnique.org - Redirection de page WEB');
 
         $log =& S::v('log');
         $url = Env::v('url');
@@ -221,13 +221,13 @@ class PlatalModule extends PLModule
 
         $page->changeTpl('platal/motdepasse.tpl');
         $page->addJsLink('motdepasse.js');
-        $page->assign('xorg_title','Polytechnique.org - Mon mot de passe');
+        $page->assign('pl_title','Polytechnique.org - Mon mot de passe');
     }
 
     function handler_smtppass(&$page)
     {
         $page->changeTpl('platal/acces_smtp.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Acces SMTP/NNTP');
+        $page->assign('pl_title','Polytechnique.org - Acces SMTP/NNTP');
 
         require_once 'wiki.inc.php';
         wiki_require_page('Xorg.SMTPSécurisé');
@@ -387,7 +387,7 @@ Adresse de secours : " . Post::v('email') : ""));
         global $globals;
 
         $page->changeTpl('platal/skins.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Skins');
+        $page->assign('pl_title','Polytechnique.org - Skins');
 
         if (Env::has('newskin'))  {  // formulaire soumis, traitons les données envoyées
             XDB::execute('UPDATE auth_user_quick
index b503016..f8bf90c 100644 (file)
@@ -221,7 +221,7 @@ class ProfileModule extends PLModule
         }
 
         $title = $user['prenom'] . ' ' . ( empty($user['nom_usage']) ? $user['nom'] : $user['nom_usage'] );
-        $page->assign('xorg_title', $title);
+        $page->assign('pl_title', $title);
 
         // photo
 
@@ -328,7 +328,7 @@ class ProfileModule extends PLModule
                       . " la procédure de récupération de mot de passe si un jour tu le perdais");
         }
 
-       $page->assign('xorg_title', 'Polytechnique.org - Mon Profil');
+       $page->assign('pl_title', 'Polytechnique.org - Mon Profil');
     }
 
     function handler_applis_js(&$page)
@@ -560,7 +560,7 @@ class ProfileModule extends PLModule
     {
         require_once 'wiki.inc.php';
         wiki_require_page('Docs.Emploi');
-        $page->assign('xorg_title', 'Polytechnique.org - Conseil Pro');
+        $page->assign('pl_title', 'Polytechnique.org - Conseil Pro');
 
         //recuperation des noms de secteurs
         $res = XDB::iterRow("SELECT id, label FROM emploi_secteur");
@@ -682,7 +682,7 @@ class ProfileModule extends PLModule
     function handler_xnet(&$page)
     {
         $page->changeTpl('profile/groupesx.tpl');
-        $page->assign('xorg_title', 'Polytechnique.org - Promo, Groupes X, Binets');
+        $page->assign('pl_title', 'Polytechnique.org - Promo, Groupes X, Binets');
 
         $req = XDB::query('
             SELECT m.asso_id, a.nom, diminutif, a.logo IS NOT NULL AS has_logo,
@@ -712,7 +712,7 @@ class ProfileModule extends PLModule
 
     function handler_admin_trombino(&$page, $uid = null, $action = null) {
         $page->changeTpl('profile/admin_trombino.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Administration - Trombino');
+        $page->assign('pl_title','Polytechnique.org - Administration - Trombino');
         $page->assign('uid', $uid);
 
         $q   = XDB::query(
@@ -748,7 +748,7 @@ class ProfileModule extends PLModule
         $page->assign('forlife', $forlife);
     }
     function handler_admin_binets(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Binets');
+        $page->assign('pl_title','Polytechnique.org - Administration - Binets');
         $page->assign('title', 'Gestion des binets');
         $table_editor = new PLTableEditor('admin/binets', 'binets_def', 'id');
         $table_editor->add_join_table('binets_ins','binet_id',true);
@@ -756,7 +756,7 @@ class ProfileModule extends PLModule
         $table_editor->apply($page, $action, $id);
     }
     function handler_admin_formations(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Formations');
+        $page->assign('pl_title','Polytechnique.org - Administration - Formations');
         $page->assign('title', 'Gestion des formations');
         $table_editor = new PLTableEditor('admin/formations','applis_def','id');
         $table_editor->add_join_table('applis_ins','aid',true);
@@ -765,21 +765,21 @@ class ProfileModule extends PLModule
         $table_editor->apply($page, $action, $id);
     }
     function handler_admin_sections(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Sections');
+        $page->assign('pl_title','Polytechnique.org - Administration - Sections');
         $page->assign('title', 'Gestion des sections');
         $table_editor = new PLTableEditor('admin/sections','sections','id');
         $table_editor->describe('text','intitulé',true);
         $table_editor->apply($page, $action, $id);
     }
     function handler_admin_ss_secteurs(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title', 'Polytechnique.org - Administration - Sous-secteurs');
+        $page->assign('pl_title', 'Polytechnique.org - Administration - Sous-secteurs');
         $page->assign('title', 'Gestion des sous-secteurs');
         $table_editor = new PLTableEditor('admin/ss_secteurs', 'emploi_ss_secteur', 'id', true);
         $table_editor->describe('label', 'intitulé', true);
         $table_editor->apply($page, $action, $id);
     }
     function handler_admin_fonctions(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title', 'Polytechnique.org - Administration - Fonctions');
+        $page->assign('pl_title', 'Polytechnique.org - Administration - Fonctions');
         $page->assign('title', 'Gestion des fonctions');
         $table_editor = new PLTableEditor('admin/fonctions', 'fonctions_def', 'id', true);
         $table_editor->describe('fonction_fr', 'intitulé', true);
@@ -788,14 +788,14 @@ class ProfileModule extends PLModule
         $table_editor->apply($page, $action, $id);
     }
     function handler_admin_secteurs(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title', 'Polytechnique.org - Administration - Secteurs');
+        $page->assign('pl_title', 'Polytechnique.org - Administration - Secteurs');
         $page->assign('title', 'Gestion des secteurs');
         $table_editor = new PLTableEditor('admin/secteurs', 'emploi_secteur', 'id', true);
         $table_editor->describe('label', 'intitulé', true);
         $table_editor->apply($page, $action, $id);
     }
     function handler_admin_medals(&$page, $action = 'list', $id = null) {
-        $page->assign('xorg_title','Polytechnique.org - Administration - Distinctions');
+        $page->assign('pl_title','Polytechnique.org - Administration - Distinctions');
         $page->assign('title', 'Gestion des Distinctions');
         $table_editor = new PLTableEditor('admin/medals','profile_medals','id');
         $table_editor->describe('text', 'intitulé',  true);
index b5ac4dd..7e2dfea 100644 (file)
@@ -154,7 +154,7 @@ class SearchModule extends PLModule
 
         require_once dirname(__FILE__) . '/search/search.inc.php';
         $page->changeTpl('search/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Annuaire');
+        $page->assign('pl_title','Polytechnique.org - Annuaire');
     }
 
     function handler_advanced(&$page, $action = null, $subaction = null)
index 406664e..429d09b 100644 (file)
@@ -95,7 +95,7 @@ class ThrowError
         global $globals;
         $page =& Platal::page();
         $page->changeTpl('search/index.tpl');
-        $page->assign('xorg_title','Polytechnique.org - Annuaire');
+        $page->assign('pl_title','Polytechnique.org - Annuaire');
         $page->assign('baseurl', $globals->baseurl);
         $page->trigError($explain);
         $page->run();
index 156a1eb..e7b0a49 100644 (file)
@@ -23,7 +23,7 @@
 
 <h1>Télépaiements</h1>
 
-{if $smarty.request.op eq "submit" and !$xorg_errors}
+{if $smarty.request.op eq "submit" and !$pl_errors}
 
 <table class="bicol">
   <tr>
index 0f6d2c9..99471bd 100644 (file)
@@ -21,7 +21,7 @@
 {**************************************************************************}
 
 
-{if $formulaire eq 0 and !$xorg_errors}
+{if $formulaire eq 0 and !$pl_errors}
   {if !$simple}
     {if !$advanced}
     {include file=search/quick.form.tpl show_js=1}
index fdd8ddb..4781db6 100644 (file)
@@ -37,10 +37,10 @@ Nous conseillons très vivement d'utiliser des navigateurs récents, tels
 <br />
 {/if}
 
-{if !$xorg_no_errors || $xorg_failure}
+{if !$pl_no_errors || $pl_failure}
 {include file="skin/common.triggers.tpl"}
 {/if}
 
-{if !$xorg_failure && $xorg_tpl}{include file=$xorg_tpl}{/if}
+{if !$pl_failure && $pl_tpl}{include file=$pl_tpl}{/if}
 
 {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}
index da39c5e..568297d 100644 (file)
     <link rel="bookmark" href="http://www.polytechnique.fr/eleves/" title="| Site d'élèves" />
 
     <link rel="stylesheet" type="text/css" href="css/base.css" media="all"/>
-    {foreach from=$xorg_css item=css}
+    {foreach from=$pl_css item=css}
     <link rel="stylesheet" type="text/css" href="css/{$css}" media="all"/>
     {/foreach}
-    {foreach from=$xorg_inline_css item=css}
+    {foreach from=$pl_inline_css item=css}
     <style type="text/css">
     {$css|smarty:nodefaults}
     </style>
@@ -53,7 +53,7 @@
     <script type="text/javascript">
       var platal_baseurl = "{$globals->baseurl}/";
     </script>
-    {foreach from=$xorg_js item=js}
+    {foreach from=$pl_js item=js}
     <script type="text/javascript" src="javascript/{$js}"></script>
     {/foreach}
     {javascript name=overlib}
     {javascript name=sha1}
     {javascript name=secure_hash}
 
-    {if $xorg_rss}
-    <link rel="alternate" type="application/rss+xml" title="{$xorg_rss.title}" href="{$xorg_rss.href}" />
+    {if $pl_rss}
+    <link rel="alternate" type="application/rss+xml" title="{$pl_rss.title}" href="{$pl_rss.href}" />
     {/if}
 
-    {if $xorg_extra_header}
-    {$xorg_extra_header|smarty:nodefaults}
+    {if $pl_extra_header}
+    {$pl_extra_header|smarty:nodefaults}
     {/if}
 
-    <title>{$xorg_title|default:"Polytechnique.org&nbsp;: le site des élèves et anciens élèves de l'École polytechnique"}</title>
+    <title>{$pl_title|default:"Polytechnique.org&nbsp;: le site des élèves et anciens élèves de l'École polytechnique"}</title>
 
 {* vim:set et sw=2 sts=2 sws=2 enc=utf-8: *}
index 5a310a3..9a507a2 100644 (file)
@@ -20,7 +20,7 @@
 {*                                                                        *}
 {**************************************************************************}
 
-{foreach from=$xorg_triggers key=type item=triggers}
+{foreach from=$pl_triggers key=type item=triggers}
 {if $triggers|@count}
 <div class="{$type}">
   <ul>
index a62d9d4..da0beba 100644 (file)
     <link rel="bookmark" href="http://www.polytechnique.org/"       title="| Polytechnique.org" />
     <link rel="bookmark" href="http://www.polytechnique.fr/eleves/" title="| Site d'élèves" />
 
-    {foreach from=$xorg_css item=css}
+    {foreach from=$pl_css item=css}
     <link rel="stylesheet" type="text/css" href="css/{$css}" />
     {/foreach}
-    {foreach from=$xorg_inline_css item=css} 
+    {foreach from=$pl_inline_css item=css} 
     <style type="text/css"> 
     {$css|smarty:nodefaults} 
     </style> 
     if (window.top != window)
       document.write('<link rel="stylesheet" type="text/css" href="css/onlycontent.css" media="all"/>');
     </script>
-    {foreach from=$xorg_js item=js}
+    {foreach from=$pl_js item=js}
     <script type="text/javascript" src="javascript/{$js}"></script>
     {/foreach}
     {javascript name=overlib}
 
-    {if $xorg_rss}
-    <link rel="alternate" type="application/rss+xml" title="{$xorg_rss.title}" href="{$xorg_rss.href}" />
+    {if $pl_rss}
+    <link rel="alternate" type="application/rss+xml" title="{$pl_rss.title}" href="{$pl_rss.href}" />
     {/if}
 
-    {if $xorg_extra_header}
-    {$xorg_extra_header|smarty:nodefaults}
+    {if $pl_extra_header}
+    {$pl_extra_header|smarty:nodefaults}
     {/if}
 
     <title>Les associations polytechniciennes</title>