linea21-core
[ class tree: linea21-core ] [ index: linea21-core ] [ all elements ]

Source for file confirm.php

Documentation is available at confirm.php

  1. <?php
  2. /**
  3.  * @package linea21.core
  4.  * @subpackage admin
  5.  * @author linea21 <info@linea21.com>
  6.  * @version $id SVN
  7.  * @access public
  8.  * @license http://opensource.org/licenses/gpl-3.0.html
  9.  */
  10.  
  11. include_once("../config/define.php"); 
  12. include_once("../config/server.php");
  13. echo '<?xml version="1.0" encoding="'.CHARSET.'" xml:lang="'. LANGUAGE .'">'.END_LINE;
  14.  
  15. if(!isset($_GET['rub']) && !isset($_POST['rub'])) {
  16.     $rub="level";
  17. } else {
  18.     if(isset($_POST['rub']))    $rub=$_POST['rub'];
  19.     if(isset($_GET['rub']))    $rub=$_GET['rub'];
  20. }
  21. if(!isset($_GET['todo']) && !isset($_POST['todo'])) {
  22.     $todo="list";
  23. } else {
  24.     if(isset($_POST['todo']))    $todo=$_POST['todo'];
  25.     if(isset($_GET['todo']))    $todo=$_GET['todo'];
  26. }
  27.  
  28. if(isset($_POST['id']))    $id=$_POST['id'];
  29. if(isset($_GET['id']))    $id=$_GET['id'];
  30.  
  31. /**
  32. * language include
  33. * 
  34. **/
  35.  
  36. include_once('../languages/'.LANGUAGE.'/lang_common.' . CHARSET . '.php');
  37. include_once('../languages/'.LANGUAGE.'/lang_' .$rub. '.' . CHARSET . '.php');
  38. include_once('../lib/lang.php'); 
  39.  
  40. $GLOBALS['lang']=$lang;
  41.  
  42. $backlink="index.php?rub=".$rub;
  43.  
  44. if($rub=='project') {
  45.     if($todo=='add') $message=_t('project','confirm_add');
  46.     if($todo=='mod') $message=_t('project','confirm_mod');
  47.     if($todo=='sup') $message=_t('project','confirm_sup');
  48. }
  49.  
  50. if($rub=='level') {
  51.     if($todo=='mod') $message=_t('level','confirm_mod');
  52. }
  53.  
  54. if($rub=='scale') {
  55.     if($todo=='add') $message=_t('scale','confirm_add');
  56.     if($todo=='mod')  $message=_t('scale','confirm_mod');
  57.     if($todo=='sup') $message=_t('scale','confirm_sup');
  58. }
  59.  
  60. if($rub=='theme') {
  61.     if($todo=='add') $message=_t('theme','confirm_add');
  62.     if($todo=='mod')  $message=_t('theme','confirm_mod');
  63.     if($todo=='sup') $message=_t('theme','confirm_sup');
  64. }
  65.  
  66. if($rub=='user') {
  67.     if($todo=='add') $message=_t('user','confirm_add');
  68.     if($todo=='mod')  $message=_t('user','confirm_mod');
  69.     if($todo=='mod_p')  $message=_t('user','confirm_modpass');
  70.     if($todo=='mod_t')  {
  71.         $message=_t('user','confirm_changetype');
  72.         $backlink="index.php?rub=user&todo=det&id=".$id;
  73.         }
  74.     if($todo=='sup') $message=_t('user','confirm_sup');
  75. }
  76.  
  77. if($rub=='news') {
  78.     if($todo=='add') $message=_t('news','confirm_add');
  79.     if($todo=='mod')  $message=_t('news','confirm_mod');
  80.     if($todo=='sup') $message=_t('news','confirm_sup');
  81. }
  82.  
  83. if($rub=='newsletter') {
  84.     if($todo=='add') $message=_t('newsletter','confirm_add');
  85.     if($todo=='mod')  $message=_t('newsletter','confirm_mod');
  86.     if($todo=='sup') $message=_t('newsletter','confirm_sup');
  87. }
  88.  
  89. if($rub=='yellowpages') {
  90.     if($todo=='add') $message=_t('yp','confirm_add');
  91.     if($todo=='mod')  {
  92.     $message=_t('yp','confirm_mod');
  93.     $backlink="index.php?rub=yellowpages&todo=det&id=".$_GET['id'];
  94.     }
  95.     if($todo=='sup') $message=_t('yp','confirm_sup');
  96. }
  97.  
  98. if($rub=='dashboard') {
  99.     if($todo=='add') $message=_t('dashboard','confirm_add');
  100.     if($todo=='mod')  $message=_t('dashboard','confirm_mod');
  101.     if($todo=='sup') $message=_t('dashboard','confirm_sup');
  102.     $backlink="index.php?rub=dashboard&todo=det&id=".$_GET['id']."&scale_id=".$_GET['scale_id'];
  103. }
  104. if($rub=='sdi') {
  105.     if($todo=='add') $message=_t('sdi','confirm_add');
  106.     if($todo=='mod')  {
  107.     $message=_t('sdi','confirm_mod');
  108.     $backlink="index.php?rub=sdi&todo=det&id=".$_GET['id'];
  109.     }
  110.     if($todo=='mod_e')
  111.     {  $message=_t('sdi','e_confirm_mod');
  112.     $backlink="index.php?rub=sdi&todo=det&id=".$_GET['id'];
  113.     }
  114.     if($todo=='mod_r'){
  115.     $message=_t('sdi','r_confirm_mod');
  116.     $backlink="index.php?rub=sdi&todo=det&id=".$_GET['id'];
  117.     }
  118.     if($todo=='mod_p'){
  119.     $message=_t('sdi','p_confirm_mod');
  120.     $backlink="index.php?rub=sdi&todo=det&id=".$_GET['id'];
  121.     }
  122.     if($todo=='sup') $message=_t('sdi','confirm_sup');
  123. }
  124. if($rub=='publication') {
  125.     if($todo=='add') $message=_t('publication','confirm_add');
  126.     if($todo=='mod')  $message=_t('publication','confirm_mod');
  127.     if($todo=='sup') $message=_t('publication','confirm_sup');
  128. }
  129.  
  130. if($rub=='workshop') {
  131.     if($todo=='add')         $message=_t('workshop','confirm_add');
  132.     if($todo=='sup')        $message=_t('workshop','confirm_sup');
  133.     
  134.     if($todo=='sup_u') {
  135.     $message=_t('workshop','confirm_sup_u');
  136.     $backlink="index.php?rub=workshop&todo=det&id=".$_GET['id'];
  137.     }
  138.     if($todo=='mod')      {
  139.         $message=_t('workshop','confirm_mod');
  140.         $backlink="index.php?rub=workshop&todo=det&id=".$_GET['id'];
  141.     }
  142.     if($todo=='mod_cal'){
  143.         $message=_t('workshop','confirm_mod_cal');
  144.         $backlink="index.php?rub=workshop&todo=list_cal&id=".$_GET['id'];
  145.     }
  146.     if($todo=='mod_com' || $todo=='lock_com'){
  147.         $message=_t('workshop','confirm_mod_com');
  148.         $backlink="index.php?rub=workshop&todo=det_com&id=".$_GET['id']."&com_id=".$_GET['com_id'];
  149.         if(isset($_GET['mes_id'])) $backlink.="#".$_GET['mes_id'];
  150.     }
  151.     if($todo=='add_cal'){
  152.         $message=_t('workshop','confirm_add_cal');
  153.         $backlink="index.php?rub=workshop&todo=list_cal&id=".$_GET['id'];
  154.     }
  155.     if($todo=='add_u'){
  156.         $message=_t('workshop','confirm_add_u');
  157.         $backlink="index.php?rub=workshop&todo=det&id=".$_GET['id'];
  158.     }
  159.     if($todo=='add_com'){
  160.         $message=_t('workshop','confirm_add_com');
  161.         $backlink="index.php?rub=workshop&todo=det_com&id=".$_GET['id']."&com_id=".$_GET['com_id'];
  162.         if(isset($_GET['mes_id'])) $backlink.="#".$_GET['mes_id'];
  163.     }
  164.     if($todo=='sup_cal'){
  165.         $message=_t('workshop','confirm_sup_cal');
  166.         $backlink="index.php?rub=workshop&todo=list_cal&id=".$_GET['id'];
  167.     }
  168.     if($todo=='sup_com'){
  169.         $message=_t('workshop','confirm_sup_com');
  170.         if(isset($_GET['all'])) $backlink="index.php?rub=workshop&todo=list_com&id=".$_GET['id']."&com_id=".$_GET['com_id'];
  171.         else $backlink="index.php?rub=workshop&todo=det_com&id=".$_GET['id']."&com_id=".$_GET['com_id'];
  172.     }
  173. }
  174.  
  175. if($rub=='resources') {
  176.     if($todo=='add_l' || $todo=='add_m' || $todo=='add_b') $message=_t('resources','confirm_add');
  177.     if($todo=='mod_l' || $todo=='mod_m' || $todo=='mod_b') $message=_t('resources','confirm_mod');
  178.     if($todo=='sup') $message=_t('resources','confirm_sup');
  179.     if($_GET['type']=='P') $backlink="index.php?rub=publication&todo=det&id=".$_GET['id'];
  180.     if($_GET['type']=='W') $backlink="index.php?rub=workshoprep&todo=det&id=".$_GET['id'];
  181.     
  182. }
  183.  
  184. if($rub=='contents') {
  185.     if($todo=='add') $message=_t('contents','confirm_add');
  186.     if($todo=='mod') $message=_t('contents','confirm_mod');
  187.     if($todo=='sup') $message=_t('contents','confirm_sup');
  188.     if($_GET['type']=='P') $backlink="index.php?rub=publication&todo=det&id=".$_GET['id'];
  189.     if($_GET['type']=='W') $backlink="index.php?rub=workshoprep&todo=det&id=".$_GET['id'];
  190. }
  191.  
  192. if($rub=='workshoprep') {
  193.     if($todo=='add') $message=_t('workshoprep','confirm_add');
  194.     if($todo=='mod') $message=_t('workshoprep','confirm_mod');
  195.     if($todo=='sup') {
  196.         $message=_t('workshoprep','confirm_sup');
  197.         $backlink="index.php?rub=workshop&todo=det&id=".$_GET['id'];
  198.     } else {
  199.         $backlink="index.php?rub=".$rub."&todo=det&id=".$_GET['id'];
  200.     }
  201.     
  202. }
  203. if($rub=='system') {
  204.     if($todo=='mod')  $message=_t('system','confirm_mod');
  205. }
  206.  
  207. ?>
  208. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
  209.  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  210. <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php echo LANGUAGE; ?>">
  211. <head>
  212. <meta HTTP-EQUIV="Refresh" CONTENT="<?php echo CONFIRM_REFRESH; ?>;URL=<?php echo $backlink; ?>">
  213. <meta http-equiv="content-language" content="<?php echo LANGUAGE; ?>" />
  214. <meta http-equiv="content-type" content="text/html; charset=<?php echo CHARSET; ?>" />
  215. <title><?php echo _t('header','title'); ?></title>
  216. <link type="text/css" rel="StyleSheet" href="<?php echo THEME_ADMIN_PATH; ?>css/actionconfirm.css" />
  217. </head>
  218. <body>
  219. <h1>
  220.     <?php echo $message; ?>
  221. </h1>
  222. </body>
  223. </html>
  224. <?php
  225. ?>

Documentation generated on Fri, 16 Oct 2009 09:30:59 +0200 by phpDocumentor 1.4.1