A lightweight forum engine written in PHP. Repository is now obsolete and read-only. http://www.pioder.pl/uforum.html
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

84 lines
1.9 KiB

  1. <?php
  2. /**
  3. * @package Forum
  4. * @file pms.php
  5. * @version 1.0.x, 08-04-2008, 17:34
  6. * @copyright 2008(c) PioDer <pioder@wp.pl>
  7. * @link http://pioder.gim2przemysl.int.pl/dsf.html
  8. * @license GNU GPL v3
  9. **/
  10. define('IN_uF', true);
  11. //include files
  12. include('./config.php');
  13. include('./includes/constants.php');
  14. include('./includes/class_db.php');
  15. include('./includes/class_error.php');
  16. //connect to database
  17. DataBase::db_connect();
  18. include('./includes/sessions.php');
  19. include('./includes/class_user.php');
  20. include('./common.php');
  21. include('./includes/classes/class_pms.php');
  22. include('./includes/class_overall.php');
  23. include('./includes/class_forum.php');
  24. include('./includes/class_posting.php');
  25. include('./includes/class_topic.php');
  26. include('./includes/classes/secure.php');
  27. include('./lngs/'.Over::DefaultLang().'/main.php');
  28. $start = Over::TimeGeneration();
  29. sess_del_invalid($_SESSION['uid']);
  30. sess_register($_SESSION['uid']);
  31. sess_delete_old();
  32. if ($_SESSION['uid']<1)
  33. {
  34. $stop = Over::TimeGeneration();
  35. message_forum($lng['youarenotlogd'],'login.php?mode=login');
  36. }
  37. foreach ($_POST as $name => $value)
  38. {
  39. if ($forum_config['use_censorlist'])
  40. {
  41. $_POST[$name] = Secure::UseCensorlist($value);
  42. }
  43. }
  44. $uid = $_SESSION['uid'];
  45. $default_skin = Over::ViewSkinName();
  46. if (isset($_GET['mode']))
  47. {
  48. switch($_GET['mode'])
  49. {
  50. case 'folder':
  51. {
  52. include ('./includes/pms/pms_folder.php');
  53. break;
  54. }
  55. //delete message
  56. case 'delete':
  57. {
  58. include ('./includes/pms/pms_delete.php');
  59. break;
  60. }
  61. case 'view':
  62. {
  63. include ('./includes/pms/pms_view.php');
  64. break;
  65. }
  66. //write message
  67. case 'write':
  68. {
  69. include ('./includes/pms/pms_write.php');
  70. break;
  71. }
  72. default:
  73. {
  74. $stop = Over::TimeGeneration();
  75. message_forum($lng['invalidmode'],'index.php');
  76. break;
  77. }
  78. }
  79. }
  80. else
  81. {
  82. header('Location: pms.php?mode=folder&submode=inbox');
  83. }
  84. ?>