<?php
/***************************************************************************
- * Copyright (C) 2003-2007 Polytechnique.org *
+ * Copyright (C) 2003-2008 Polytechnique.org *
* http://opensource.polytechnique.org/ *
* *
* This program is free software; you can redistribute it and/or modify *
}
exit;
}
-
+
function handler_index(&$page)
{
$page->nomenu = true;
function handler_admin(&$page)
{
- new_admin_page('xnet/admin.tpl');
+ $page->changeTpl('xnet/admin.tpl');
if (Get::has('del')) {
$res = XDB::query('SELECT id, nom, mail_domain
$page->setType($cat);
}
-
+
function handler_autologin(&$page)
{
+ $allkeys = func_get_args();
+ unset($allkeys[0]);
+ $url = join('/',$allkeys);
header("Content-type: text/javascript; charset=utf-8");
- echo '$.ajax({ url: "index?forceXml=1", dataType: "xml", success: function(xml) { $("body").empty(); $("body",xml).prependTo("body"); }});';
+ echo '$.ajax({ url: "'.$url.'?forceXml=1", dataType: "xml", success: function(xml) { $("body",xml).insertBefore("body"); $("body:eq(1)").remove(); }});';
exit;
}
}