Small update
[iDB.git] / profile.php
blob714eff6ef2371e771451dd9b177dd775659210a5
1 <?php
2 /*
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the Revised BSD License.
6 This program is distributed in the hope that it will be useful,
7 but WITHOUT ANY WARRANTY; without even the implied warranty of
8 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
9 Revised BSD License for more details.
11 Copyright 2004-2024 iDB Support - https://idb.osdn.jp/support/category.php?act=view&id=1
12 Copyright 2004-2024 Game Maker 2k - https://idb.osdn.jp/support/category.php?act=view&id=2
14 $FileInfo: profile.php - Last Update: 8/23/2024 SVN 1023 - Author: cooldude2k $
16 if (ini_get("register_globals")) {
17 require_once('inc/misc/killglobals.php');
19 require('preindex.php');
20 $usefileext = $Settings['file_ext'];
21 if ($ext == "noext" || $ext == "no ext" || $ext == "no+ext") {
22 $usefileext = "";
24 $filewpath = $exfile['profile'].$usefileext.$_SERVER['PATH_INFO'];
25 $idbactcheck = array("view", "signature", "avatar", "settings", "profile", "userinfo");
27 <?php $iWrappers['EXTRALINKS'] = null;
28 ob_start("idb_suboutput_handler");
29 $title_html = htmlentities($Settings['board_name'].$idbpowertitle, ENT_QUOTES, $Settings['charset']);
31 <meta itemprop="title" property="og:title" content="<?php echo $title_html; ?>" />
32 <meta itemprop="sitename" property="og:site_name" content="<?php echo $title_html; ?>" />
33 <meta itemprop="title" property="twitter:title" content="<?php echo $title_html; ?>" />
34 <meta name="title" content="<?php echo $title_html; ?>" />
35 <title> <?php echo $Settings['board_name'].$idbpowertitle; ?> </title>
36 <?php $iWrappers['TITLETAG'] = ob_get_clean();
37 ob_start("idb_suboutput_handler"); ?>
38 </head>
39 <body>
40 <?php $iWrappers['BODYTAG'] = ob_get_clean();
41 ob_start("idb_suboutput_handler");
42 require($SettDir['inc'].'navbar.php');
43 $iWrappers['NAVBAR'] = ob_get_clean();
44 ob_start("idb_suboutput_handler");
45 if ($_SESSION['UserGroup'] == $Settings['GuestGroup'] || $GroupInfo['CanEditProfile'] == "no") {
46 redirect("location", $rbasedir.url_maker($exfile['index'], $Settings['file_ext'], "act=view", $Settings['qstr'], $Settings['qsep'], $prexqstr['index'], $exqstr['index'], false));
47 ob_clean();
48 header("Content-Type: text/plain; charset=".$Settings['charset']);
49 $urlstatus = 302;
50 gzip_page($Settings['use_gzip'], $GZipEncode['Type']);
51 session_write_close();
52 die();
54 if ($_SESSION['UserGroup'] != $Settings['GuestGroup'] ||
55 $GroupInfo['CanEditProfile'] == "yes") {
56 if ($_GET['act'] == null || $_GET['act'] == "notepad") {
57 $_GET['act'] = "view";
59 if (!in_array($_GET['act'], $idbactcheck)) {
60 $_GET['act'] = "view";
62 if ($_GET['act'] == "view" ||
63 $_GET['act'] == "signature" ||
64 $_GET['act'] == "avatar" ||
65 $_GET['act'] == "settings" ||
66 $_GET['act'] == "profile" ||
67 $_GET['act'] == "userinfo") {
68 require($SettDir['inc'].'profilemain.php');
71 $iWrappers['CONTENT'] = ob_get_clean();
72 ob_start("idb_suboutput_handler");
73 require($SettDir['inc'].'endpage.php');
74 $iWrappers['COPYRIGHT'] = ob_get_clean();
75 ob_start("idb_suboutput_handler");
76 if (!isset($profiletitle)) {
77 $profiletitle = null;
80 </body>
81 </html>
82 <?php
83 $iWrappers['HTMLEND'] = ob_get_clean();
84 require($SettDir['inc'].'iwrapper.php');
85 if ($profiletitle == null) {
86 fix_amp($Settings['use_gzip'], $GZipEncode['Type']);
88 if ($profiletitle != null) {
89 change_title($Settings['board_name'].$profiletitle, $Settings['use_gzip'], $GZipEncode['Type']);