Remove the deprecated profil.css
authorFlorent Bruneau <florent.bruneau@polytechnique.org>
Thu, 20 Sep 2007 21:52:48 +0000 (23:52 +0200)
committerFlorent Bruneau <florent.bruneau@polytechnique.org>
Thu, 20 Sep 2007 21:52:48 +0000 (23:52 +0200)
Signed-off-by: Florent Bruneau <florent.bruneau@polytechnique.org>
htdocs/css/profil.css [deleted file]
modules/platal.php
modules/profile.php

diff --git a/htdocs/css/profil.css b/htdocs/css/profil.css
deleted file mode 100644 (file)
index 645611b..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
-/***************************************************************************
- *  Copyright (C) 2003-2007 Polytechnique.org                              *
- *  http://opensource.polytechnique.org/                                   *
- *                                                                         *
- *  This program is free software; you can redistribute it and/or modify   *
- *  it under the terms of the GNU General Public License as published by   *
- *  the Free Software Foundation; either version 2 of the License, or      *
- *  (at your option) any later version.                                    *
- *                                                                         *
- *  This program is distributed in the hope that it will be useful,        *
- *  but WITHOUT ANY WARRANTY; without even the implied warranty of         *
- *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the          *
- *  GNU General Public License for more details.                           *
- *                                                                         *
- *  You should have received a copy of the GNU General Public License      *
- *  along with this program; if not, write to the Free Software            *
- *  Foundation, Inc.,                                                      *
- *  59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                *
- ***************************************************************************/
-
-div.blocunite {margin: 1em 0em 2em 0em;}
-div.blocunite_tab {margin: 0em 0em 2em 0em;}
-table.bicol td.cold,td.col {padding-right: 0.5em;}
-table.bicol td.colm {}
-table.bicol td.colg,td.col {padding-left: 0.5em;}
-table.bicol td.dcolm, td.dcolg, td.dcold {padding-bottom: 0.5em;}
-table.bicol td.dcolg {padding-left: 0.5em;}
-table.bicol td.dcold {padding-right: 0.5em;}
-table.bicol td.pflags {}
-table.bicol td.flags {padding-top: 0.5em;}
-table.bicol tr.top {vertical-align: top;}
-table.bicol span.titre {font-weight: bold;}
-table.bicol span.comm {font-size: smaller;}
-table.bicol span.nom {}
-table.bicol span.valeur {font-weight: bold;}
-table.bicol span.lien {font-size: smaller;}
index 4ba4740..0489b10 100644 (file)
@@ -39,7 +39,7 @@ class PlatalModule extends PLModule
     {
         return array(
             'index'       => $this->make_hook('index',     AUTH_PUBLIC),
-           'cacert.pem'  => $this->make_hook('cacert',    AUTH_PUBLIC),
+            'cacert.pem'  => $this->make_hook('cacert',    AUTH_PUBLIC),
             'changelog'   => $this->make_hook('changelog', AUTH_PUBLIC),
 
             // Preferences thingies
@@ -55,6 +55,7 @@ class PlatalModule extends PLModule
             'password/smtp' => $this->make_hook('smtppass',  AUTH_MDP),
             'recovery'      => $this->make_hook('recovery',  AUTH_PUBLIC),
             'exit'          => $this->make_hook('exit', AUTH_PUBLIC),
+            'review'        => $this->make_hook('review', AUTH_PUBLIC),
             'deconnexion.php' => $this->make_hook('exit', AUTH_PUBLIC),
         );
     }
@@ -417,6 +418,39 @@ Adresse de secours : " . Post::v('email') : ""));
             $page->changeTpl('platal/exit.tpl');
         }
     }
+
+    function handler_review(&$page, $action = null) 
+    {
+        require_once 'wiki.inc.php';
+        $dir = wiki_work_dir();
+        $dom = 'Review';
+        if (@$GLOBALS['IS_XNET_SITE']) {
+            $dom .= 'Xnet';
+        }
+        if (!is_dir($dir)) {
+            $page->kill("Impossible de trouver le wiki");
+        }
+        if (!file_exists($dir . '/' . $dom . '.Admin')) {
+            $page->kill("Impossible de trouver la page d'administration");
+        }
+        $conf = preg_grep('/^text=/', explode("\n", file_get_contents($dir . '/' . $dom . '.Admin')));
+        $conf = preg_split('/(text\=|\%0a)/', array_shift($conf), -1, PREG_SPLIT_NO_EMPTY);
+        $wiz = new PlWizard('Tour d\'horizon', 'core/plwizard.tpl', true);
+        foreach ($conf as $line) {
+            $list = preg_split('/\s*[*|]\s*/', $line, -1, PREG_SPLIT_NO_EMPTY);
+            $wiz->addPage('ReviewPage', $list[0], $list[1]);
+        }
+        $wiz->apply($page, 'review', $action);
+    }
+}
+
+__autoload('PlWizard');
+class ReviewPage implements PlWizardPage
+{
+    public function __construct(PlWizard &$wiz) { }
+    public function template() { return 'platal/index.tpl'; }
+    public function prepare(PlatalPage &$page) { }
+    public function process() { }
 }
 
 // vim:set et sw=4 sts=4 sws=4 foldmethod=marker enc=utf-8:
index 2a6f148..2fede87 100644 (file)
@@ -340,7 +340,6 @@ class ProfileModule extends PLModule
         $wiz->addPage('ProfileMentor', 'Mentoring', 'mentor');
         $wiz->apply($page, 'profile/edit', $opened_tab);
 
-        $page->addCssLink('profil.css');
         $page->assign('xorg_title', 'Polytechnique.org - Mon Profil');
     }