+ Censorlist was extended - added replacement parametr
+ Fixed bug with DB Size in check_script.php + Deleted a lot of indexes in check_script_data.php + Deleted cache index and forum lastpost section in cache_index.php and cache_forum.php + Fixed other bugs in warnings + Fixed pagination in search.php + Replaced DSF logo to uForum logo + Moved differend elements in skin + Added "WHOIS" option in "Admin/Mod Pool" in view topic + Fixed bug in add warnings: couldn't add warn for admin/mod git-svn-id: https://svn.pioder.pl/uf-svn/uF@29 72ec579a-5ced-4fa4-82f3-afba5d98df2f
@@ -57,7 +57,7 @@ switch($_GET['mode'])
|
|||||||
for($i=0;$i<count($item);$i++)
|
for($i=0;$i<count($item);$i++)
|
||||||
{
|
{
|
||||||
$word = $item[$i];
|
$word = $item[$i];
|
||||||
DataBase::sql_query("INSERT INTO ".CENSORLIST_TABLE." VALUES ('$last','$word')",GENERAL,'Could not add censored word.');
|
DataBase::sql_query("INSERT INTO ".CENSORLIST_TABLE." VALUES ('$last','$word','[censored]')",GENERAL,'Could not add censored word.');
|
||||||
$last = $last +1;
|
$last = $last +1;
|
||||||
}
|
}
|
||||||
admin_message_forum($lng['words_added'],'censorlist.php');
|
admin_message_forum($lng['words_added'],'censorlist.php');
|
||||||
@@ -90,20 +90,23 @@ switch($_GET['mode'])
|
|||||||
if (isset($_POST['word']))
|
if (isset($_POST['word']))
|
||||||
{
|
{
|
||||||
$word = strip_tags($_POST['word']);
|
$word = strip_tags($_POST['word']);
|
||||||
|
$replace = (strlen($_POST['replace']) > 0) ? $_POST['replace'] : '[censored]';
|
||||||
$sql = "SELECT `w_id` FROM ".CENSORLIST_TABLE." ORDER BY `w_id` DESC";
|
$sql = "SELECT `w_id` FROM ".CENSORLIST_TABLE." ORDER BY `w_id` DESC";
|
||||||
$last = DataBase::fetch(DataBase::sql_query($sql,GENERAL,'Could not obtain last word id'));
|
$last = DataBase::fetch(DataBase::sql_query($sql,GENERAL,'Could not obtain last word id'));
|
||||||
$last = $last['w_id'];
|
$last = $last['w_id'];
|
||||||
$last= $last +1;
|
$last= $last +1;
|
||||||
DataBase::sql_query("INSERT INTO ".CENSORLIST_TABLE." VALUES ('$last','$word')",GENERAL,'Could not add censored word.');
|
DataBase::sql_query("INSERT INTO ".CENSORLIST_TABLE." VALUES ('$last','$word','$replace')",GENERAL,'Could not add censored word.');
|
||||||
admin_message_forum($lng['word_added'],'censorlist.php');
|
admin_message_forum($lng['word_added'],'censorlist.php');
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$_POST['word']='';
|
$_POST['word']='';
|
||||||
|
$_POST['replace']='';
|
||||||
$skin = array(
|
$skin = array(
|
||||||
'action'=>'censorlist.php?mode=addword',
|
'action'=>'censorlist.php?mode=addword',
|
||||||
'L.main_beam'=>$lng['add_word'],
|
'L.main_beam'=>$lng['add_word'],
|
||||||
'L.word_name'=>$lng['word_name'],
|
'L.word_name'=>$lng['word_name'],
|
||||||
|
'L.replace_to'=>$lng['replace_to'],
|
||||||
'L.save'=>$lng['submit'],
|
'L.save'=>$lng['submit'],
|
||||||
'L.reset'=>$lng['reset'],
|
'L.reset'=>$lng['reset'],
|
||||||
'L.censorlist'=>$lng['admin_censorlist']
|
'L.censorlist'=>$lng['admin_censorlist']
|
||||||
@@ -120,7 +123,8 @@ switch($_GET['mode'])
|
|||||||
{
|
{
|
||||||
$word = strip_tags(trim($_POST['word']));
|
$word = strip_tags(trim($_POST['word']));
|
||||||
$wid = intval($_GET['w']);
|
$wid = intval($_GET['w']);
|
||||||
DataBase::sql_query("UPDATE ".CENSORLIST_TABLE." SET `word`='$word' WHERE `w_id`='$wid'",GENERAL,'Could not update censored word.');
|
$replace = $_POST['replace'];
|
||||||
|
DataBase::sql_query("UPDATE ".CENSORLIST_TABLE." SET `word`='$word', `replace`='$replace' WHERE `w_id`='$wid'",GENERAL,'Could not update censored word.');
|
||||||
admin_message_forum($lng['word_edited'],'censorlist.php?mode=view');
|
admin_message_forum($lng['word_edited'],'censorlist.php?mode=view');
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -130,10 +134,12 @@ switch($_GET['mode'])
|
|||||||
$query = DataBase::sql_query($sql,CRITICAL,'Could not obtain censorlist words');
|
$query = DataBase::sql_query($sql,CRITICAL,'Could not obtain censorlist words');
|
||||||
$result = DataBase::fetch($query);
|
$result = DataBase::fetch($query);
|
||||||
$_POST['word']=$result['word'];
|
$_POST['word']=$result['word'];
|
||||||
|
$_POST['replace']=$result['replace'];
|
||||||
$skin = array(
|
$skin = array(
|
||||||
'action'=>'censorlist.php?mode=edit&w='.$wid,
|
'action'=>'censorlist.php?mode=edit&w='.$wid,
|
||||||
'L.main_beam'=>$lng['edit_word'],
|
'L.main_beam'=>$lng['edit_word'],
|
||||||
'L.word_name'=>$lng['word_name'],
|
'L.word_name'=>$lng['word_name'],
|
||||||
|
'L.replace_to'=>$lng['replace_to'],
|
||||||
'L.save'=>$lng['submit'],
|
'L.save'=>$lng['submit'],
|
||||||
'L.reset'=>$lng['reset'],
|
'L.reset'=>$lng['reset'],
|
||||||
'L.censorlist'=>$lng['admin_censorlist']
|
'L.censorlist'=>$lng['admin_censorlist']
|
||||||
@@ -171,11 +177,12 @@ switch($_GET['mode'])
|
|||||||
{
|
{
|
||||||
$skin = array(
|
$skin = array(
|
||||||
'L.word_name'=>$item['word'],
|
'L.word_name'=>$item['word'],
|
||||||
|
'L.word_replacement'=>$item['replace'],
|
||||||
'w_id'=>$item['w_id'],
|
'w_id'=>$item['w_id'],
|
||||||
'L.delete'=>$lng['delete'],
|
'L.delete'=>$lng['delete'],
|
||||||
'L.edit'=>$lng['edit'],
|
'L.edit'=>$lng['edit'],
|
||||||
);
|
);
|
||||||
include('./template/censorlist_word_add.tpl');
|
include('./template/censorlist_list_word.tpl');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
include('./template/overall_footer.tpl');
|
include('./template/overall_footer.tpl');
|
||||||
|
|||||||
@@ -66,6 +66,7 @@ function db_size()
|
|||||||
while ($result = DataBase::fetch($query))
|
while ($result = DataBase::fetch($query))
|
||||||
{
|
{
|
||||||
$db_size += $result['Index_length'];
|
$db_size += $result['Index_length'];
|
||||||
|
$db_size += $result['Data_length'];
|
||||||
}
|
}
|
||||||
$db_size = $db_size / 1024;
|
$db_size = $db_size / 1024;
|
||||||
if ($db_size >=1024)
|
if ($db_size >=1024)
|
||||||
|
|||||||
@@ -13,49 +13,22 @@ if ( !defined('IN_uF') )
|
|||||||
}
|
}
|
||||||
//size files in md5
|
//size files in md5
|
||||||
$size_md5['../common.php'] = '426f990b332ef8193a61cc90516c1245';
|
$size_md5['../common.php'] = '426f990b332ef8193a61cc90516c1245';
|
||||||
$size_md5['../eprofile.php'] = '1868f17c2c15b5eafdc3cce2f5ac97d5';
|
|
||||||
$size_md5['../forum.php'] = 'acf666483bc8723fae7feda6f6a9cb7a';
|
|
||||||
$size_md5['../groups.php'] = '6b493230205f780e1bc26945df7481e5';
|
|
||||||
$size_md5['../index.php'] = 'd71f5142463efcf6dc7be216cf4644b5';
|
|
||||||
$size_md5['../login.php'] = 'e275193bc089e9b3ca1aeef3c44be496';
|
$size_md5['../login.php'] = 'e275193bc089e9b3ca1aeef3c44be496';
|
||||||
$size_md5['../moderate.php'] = '6562c5c1f33db6e05a082a88cddab5ea';
|
$size_md5['../moderate.php'] = '6562c5c1f33db6e05a082a88cddab5ea';
|
||||||
$size_md5['../pms.php'] = 'f22e4747da1aa27e363d86d40ff442fe';
|
$size_md5['../pms.php'] = 'f22e4747da1aa27e363d86d40ff442fe';
|
||||||
$size_md5['../posting.php'] = 'f5dffc111454b227fbcdf36178dfe6ac';
|
$size_md5['../posting.php'] = 'f5dffc111454b227fbcdf36178dfe6ac';
|
||||||
$size_md5['../search.php'] = '3016a447172f3045b65f5fc83e04b554';
|
$size_md5['../search.php'] = '3016a447172f3045b65f5fc83e04b554';
|
||||||
$size_md5['../shoutbox.php'] = '102f0bb6efb3a6128a3c750dd16729be';
|
$size_md5['../shoutbox.php'] = '102f0bb6efb3a6128a3c750dd16729be';
|
||||||
$size_md5['../quick_reply.php'] = '7a53928fa4dd31e82c6ef826f341daec';
|
|
||||||
$size_md5['../register.php'] = '14f2ebeab937ca128186e7ba876faef9';
|
$size_md5['../register.php'] = '14f2ebeab937ca128186e7ba876faef9';
|
||||||
$size_md5['../topic.php'] = 'b0bf8b3daf61246d13276dc8dcdfb87d';
|
|
||||||
$size_md5['../user.php'] = 'bf56a1b37b94243486b2034f8479c475';
|
|
||||||
$size_md5['../users.php'] = '7990ec44fcf3d7a0e5a2add28362213c';
|
|
||||||
$size_md5['../warns.php'] = '9570efef719d705326f0ff817ef084e6';
|
$size_md5['../warns.php'] = '9570efef719d705326f0ff817ef084e6';
|
||||||
|
|
||||||
$size_md5['../includes/db.php'] = 'a376033f78e144f494bfc743c0be3330';
|
$size_md5['../includes/db.php'] = 'a376033f78e144f494bfc743c0be3330';
|
||||||
$size_md5['../includes/emailer.php'] = 'e37b08dd3015330dcbb5d6663667b8b8';
|
$size_md5['../includes/emailer.php'] = 'e37b08dd3015330dcbb5d6663667b8b8';
|
||||||
$size_md5['../includes/errors.php'] = '8232e119d8f59aa83050a741631803a6';
|
|
||||||
$size_md5['../includes/classes/class_forum.php'] = '87f7ee4fdb57bdfd52179947211b7ebb';
|
|
||||||
$size_md5['../includes/classes/class_mod.php'] = '4764f37856fc727f70b666b8d0c4ab7a';
|
$size_md5['../includes/classes/class_mod.php'] = '4764f37856fc727f70b666b8d0c4ab7a';
|
||||||
$size_md5['../includes/classes/class_pms.php'] = '850af92f8d9903e7a4e0559a98ecc857';
|
|
||||||
$size_md5['../includes/misc_functions.php'] = '92c3d054835eff3d5a7f7ed731d2a3db';
|
$size_md5['../includes/misc_functions.php'] = '92c3d054835eff3d5a7f7ed731d2a3db';
|
||||||
$size_md5['../includes/classes/class_posting.php'] = '9c72e0c8882794b79d65f14776a0a974';
|
$size_md5['../includes/classes/class_posting.php'] = '9c72e0c8882794b79d65f14776a0a974';
|
||||||
$size_md5['../includes/class_shoutbox.php'] = 'cd14821dab219ea06e2fd1a2df2e3582';
|
|
||||||
$size_md5['../includes/classes/class_topic.php'] = '48f7d3043bc03e6c48a6f0ebc0f258a8';
|
|
||||||
$size_md5['../includes/classes/class_user.php'] = '2d5951d1e3b31dfb7fd2dcc172df17fd';
|
|
||||||
$size_md5['../includes/constants.php'] = 'fc79250f8c5b804390e8da280b4cf06e';
|
|
||||||
$size_md5['../includes/msgs_delete.php'] = '571e0f7e2d992e738adff8b1bd43a521';
|
|
||||||
$size_md5['../includes/msgs_folder.php'] = 'd756d3d2b9dac72449a6a6926534558a';
|
|
||||||
$size_md5['../includes/msgs_view.php'] = '291d43c696d8c3704cdbe0a72ade5f6c';
|
|
||||||
$size_md5['../includes/msgs_write.php'] = 'b0b79da57b95837f14be95aaa4d54cf8';
|
|
||||||
$size_md5['../includes/classes/secure.php'] = 'a084f26f690dbc23a52e67027693f2b2';
|
$size_md5['../includes/classes/secure.php'] = 'a084f26f690dbc23a52e67027693f2b2';
|
||||||
$size_md5['../includes/sessions.php'] = 'e91068fff3d7fa1594dfdf3b4308433a';
|
$size_md5['../includes/sessions.php'] = 'e91068fff3d7fa1594dfdf3b4308433a';
|
||||||
$size_md5['../includes/sql_parse.php'] = '4a1590df1d5968d41b855005bb8b67bf';
|
|
||||||
|
|
||||||
$size_md5['../includes/admin/class_forum.php'] = 'e205ee2a5de471a70c1fd1b46033a75f';
|
|
||||||
$size_md5['../includes/admin/class_main.php'] = '65ae450c5536606c266f49f1c08321f2';
|
|
||||||
|
|
||||||
$size_md5['../includes/cache/cache_index.php'] = '88a839f2f6f1427879fc33ee4acf4f66';
|
|
||||||
$size_md5['../includes/cache/cache_forums.php'] = '6ef80bb237adf4b6f77d0700e1255907';
|
|
||||||
$size_md5['../includes/cache/cache_topic.php'] = '9a11883317fde3aef2e2432a58c86779';
|
|
||||||
|
|
||||||
$script_files = array_keys($size_md5);
|
$script_files = array_keys($size_md5);
|
||||||
|
|
||||||
|
|||||||
@@ -24,6 +24,14 @@
|
|||||||
<input type="text" name="word" style="width: 200px" value="<?= $_POST['word']; ?>">
|
<input type="text" name="word" style="width: 200px" value="<?= $_POST['word']; ?>">
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td align="right" class="fitem">
|
||||||
|
<span class="fstandard"><b><?php echo $skin['L.replace_to']; ?>:</b></span>
|
||||||
|
</td>
|
||||||
|
<td class="fitem" >
|
||||||
|
<textarea name="replace" style="width: 400px; height: 100px"><?= $_POST['replace']; ?></textarea>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td width="738" height="20" class="fitem" align="center" valign="top" colspan="2">
|
<td width="738" height="20" class="fitem" align="center" valign="top" colspan="2">
|
||||||
<input type="submit" class="fbutton" value="<?php echo $skin['L.save']; ?>" />
|
<input type="submit" class="fbutton" value="<?php echo $skin['L.save']; ?>" />
|
||||||
|
|||||||
@@ -1,7 +1,10 @@
|
|||||||
<table class="maintable" width="<?= TABLES_WIDTH; ?>">
|
<table class="maintable" width="<?= TABLES_WIDTH; ?>">
|
||||||
<tr>
|
<tr>
|
||||||
<td width="668" height="7" class="fitem">
|
<td height="7" class="fitem">
|
||||||
<span class="fstandard"><?= $skin['L.word_name']; ?></span>
|
<span class="fstandard"><?= $skin['L.word_name']; ?></span>
|
||||||
|
</td>
|
||||||
|
<td width="500" height="7" class="fitem">
|
||||||
|
<span class="fstandard"><?= $skin['L.word_replacement']; ?></span>
|
||||||
</td>
|
</td>
|
||||||
<td width="40" height="7" class="fitem" align="center">
|
<td width="40" height="7" class="fitem" align="center">
|
||||||
<a href="censorlist.php?mode=edit&w=<?= $skin['w_id']; ?>" class="fstandard">
|
<a href="censorlist.php?mode=edit&w=<?= $skin['w_id']; ?>" class="fstandard">
|
||||||
@@ -47,6 +47,8 @@ else
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
define('TABLES_WIDTH',$forum_config['tables_width']);
|
||||||
|
|
||||||
//check for banned user
|
//check for banned user
|
||||||
if ($_SESSION['uid']>0)
|
if ($_SESSION['uid']>0)
|
||||||
{
|
{
|
||||||
@@ -60,7 +62,7 @@ if ($_SESSION['uid']>0)
|
|||||||
if (($db_ip==$ip) || ($db_uid==$uid))
|
if (($db_ip==$ip) || ($db_uid==$uid))
|
||||||
{
|
{
|
||||||
include('./includes/misc_functions.php');
|
include('./includes/misc_functions.php');
|
||||||
include('./lngs/'.DefaultLang().'/main.php');
|
include('./lngs/'.DefaultLang(true).'/main.php');
|
||||||
SessDelete($_SESSION['uid']);
|
SessDelete($_SESSION['uid']);
|
||||||
$_SESSION['uid']='0';
|
$_SESSION['uid']='0';
|
||||||
message_forum($motive,'index.php', '10');
|
message_forum($motive,'index.php', '10');
|
||||||
@@ -80,7 +82,7 @@ $query = DataBase::sql_query($sql, GENERAL,'Could not obtain loged user informat
|
|||||||
$userdata = DataBase::fetch($query);
|
$userdata = DataBase::fetch($query);
|
||||||
define('RANK', $userdata['rank']);
|
define('RANK', $userdata['rank']);
|
||||||
|
|
||||||
define('TABLES_WIDTH',$forum_config['tables_width']);
|
|
||||||
//protect of database - add the backslashes
|
//protect of database - add the backslashes
|
||||||
/*foreach ($_POST as $name => $value)
|
/*foreach ($_POST as $name => $value)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -13,6 +13,6 @@ define('DB_USER','root');
|
|||||||
define('DB_PASS','');
|
define('DB_PASS','');
|
||||||
define('DB_NAME','uf');
|
define('DB_NAME','uf');
|
||||||
define('DB_PREFIX','uf_');
|
define('DB_PREFIX','uf_');
|
||||||
define('VERSION','9.5.3');
|
define('VERSION','9.5.31');
|
||||||
define('UF_INSTALLED',true);
|
define('UF_INSTALLED',true);
|
||||||
?>
|
?>
|
||||||
|
|||||||
16
includes/cache/cache_forums.php
vendored
@@ -23,22 +23,6 @@ $forum = array(
|
|||||||
'name'=>$result['name'],
|
'name'=>$result['name'],
|
||||||
'lock'=>$result['lock']
|
'lock'=>$result['lock']
|
||||||
);
|
);
|
||||||
/*$sql = "SELECT COUNT(*) as `p_id`, `t_id` FROM ".POSTS_TABLE." GROUP BY `t_id`";
|
|
||||||
$query = DataBase::sql_query($sql,GENERAL, 'Could not obtain amout of posts in forum');
|
|
||||||
while($result = DataBase::fetch($query))
|
|
||||||
{
|
|
||||||
$count_topic[$result['t_id']]=$result['p_id'];
|
|
||||||
}*/
|
|
||||||
/*$sql = "SELECT ".POSTS_TABLE.".*, ".USERS_TABLE.".* FROM ".POSTS_TABLE." LEFT JOIN ".USERS_TABLE." ON ".USERS_TABLE.".u_id = ".POSTS_TABLE.".u_id WHERE `f_id`='$fid' ORDER BY `ptime`";
|
|
||||||
$query = DataBase::sql_query($sql,GENERAL, 'Could not obtain amout of posts in forum');
|
|
||||||
while($result = DataBase::fetch($query))
|
|
||||||
{
|
|
||||||
$lastpost[$result['t_id']]['tp_id']=$result['tp_id'];
|
|
||||||
$lastpost[$result['t_id']]['u_id']=$result['u_id'];
|
|
||||||
$lastpost[$result['t_id']]['time']=$result['ptime'];
|
|
||||||
$lastpost[$result['t_id']]['user_nick']=$result['nick'];
|
|
||||||
$lastpost[$result['t_id']]['user_rank']=$result['rank'];
|
|
||||||
} */
|
|
||||||
//
|
//
|
||||||
//generate output pages
|
//generate output pages
|
||||||
//
|
//
|
||||||
|
|||||||
6
includes/cache/cache_index.php
vendored
@@ -17,7 +17,9 @@ if(!defined('IN_uF'))
|
|||||||
//lastpost in forum cache
|
//lastpost in forum cache
|
||||||
//cache forums --don't modify!!!
|
//cache forums --don't modify!!!
|
||||||
$cache_id=1;
|
$cache_id=1;
|
||||||
$sql = "SELECT ".FORUMS_TABLE.".*, COUNT(".POSTS_TABLE.".p_id) as amout, ".POSTS_TABLE.".f_id AS count FROM ".FORUMS_TABLE." LEFT JOIN ".POSTS_TABLE." ON ".FORUMS_TABLE.".f_id= ".POSTS_TABLE.".f_id GROUP BY `f_id` ORDER BY `c_id`, `sort`";
|
$sql = "SELECT ".FORUMS_TABLE.".*
|
||||||
|
FROM ".FORUMS_TABLE."
|
||||||
|
ORDER BY `c_id`, `sort`";
|
||||||
$query = DataBase::sql_query($sql,CRITICAL,'Could not obtain forum information.');
|
$query = DataBase::sql_query($sql,CRITICAL,'Could not obtain forum information.');
|
||||||
while($result = DataBase::fetch($query))
|
while($result = DataBase::fetch($query))
|
||||||
{
|
{
|
||||||
@@ -27,7 +29,7 @@ while($result = DataBase::fetch($query))
|
|||||||
$forum[$cache_id]['c_id'] = $result['c_id'];
|
$forum[$cache_id]['c_id'] = $result['c_id'];
|
||||||
$forum[$cache_id]['sort'] = $result['sort'];
|
$forum[$cache_id]['sort'] = $result['sort'];
|
||||||
$forum[$cache_id]['lastpost'] = $result['lastpost'];
|
$forum[$cache_id]['lastpost'] = $result['lastpost'];
|
||||||
$count_forum[$result['f_id']] = $result['amout'];
|
$count_forum[$result['f_id']] = $result['posts'];
|
||||||
$cache_id+=1;
|
$cache_id+=1;
|
||||||
}
|
}
|
||||||
$sql = "SELECT `u_id`,`nick`, `regdate` AS count FROM ".USERS_TABLE." ORDER BY `regdate` DESC";
|
$sql = "SELECT `u_id`,`nick`, `regdate` AS count FROM ".USERS_TABLE." ORDER BY `regdate` DESC";
|
||||||
|
|||||||
25
includes/cache/cache_topic.php
vendored
@@ -18,16 +18,23 @@ if ($result['t_id']=='')
|
|||||||
{
|
{
|
||||||
message_forum($lng['no_topic'], 'index.php');
|
message_forum($lng['no_topic'], 'index.php');
|
||||||
}
|
}
|
||||||
$topic['name']=$result['topic_name'];
|
|
||||||
$topic['lock']=$result['topic_lock'];
|
$topic = array(
|
||||||
$topic['sticky']=$result['sticky'];
|
'name' => $result['topic_name'],
|
||||||
$topic['f_id']=$result['f_id'];
|
'lock' => $result['topic_lock'],
|
||||||
|
'sticky' => $result['sticky'],
|
||||||
|
'f_id' => $result['f_id']
|
||||||
|
);
|
||||||
|
|
||||||
|
$forum = array(
|
||||||
|
'name' => $result['name'],
|
||||||
|
'lock' => $result['lock'],
|
||||||
|
'moderate' => $result['moderate']
|
||||||
|
);
|
||||||
|
|
||||||
$fid = $topic['f_id'];
|
$fid = $topic['f_id'];
|
||||||
$forum['name']=$result['name'];
|
|
||||||
$forum['lock']=$result['lock'];
|
|
||||||
$forum['moderate']=$result['moderate'];
|
|
||||||
|
|
||||||
|
|
||||||
|
//user warnings level
|
||||||
$sql = "SELECT `u_id`,`value` FROM `".WARNINGS_TABLE."`";
|
$sql = "SELECT `u_id`,`value` FROM `".WARNINGS_TABLE."`";
|
||||||
$query = DataBase::sql_query($sql,GENERAL,'Could not obtain user warns information');
|
$query = DataBase::sql_query($sql,GENERAL,'Could not obtain user warns information');
|
||||||
$result = DataBase::num_rows($query);
|
$result = DataBase::num_rows($query);
|
||||||
@@ -54,7 +61,9 @@ while($result = DataBase::fetch($query))
|
|||||||
{
|
{
|
||||||
$user[$result['u_id']]['online']='1';
|
$user[$result['u_id']]['online']='1';
|
||||||
}
|
}
|
||||||
|
|
||||||
unset($sql, $query, $result);
|
unset($sql, $query, $result);
|
||||||
|
|
||||||
//
|
//
|
||||||
//generate output pages
|
//generate output pages
|
||||||
//
|
//
|
||||||
|
|||||||
@@ -209,6 +209,7 @@ class User
|
|||||||
|
|
||||||
function UserAddWarn($uid, $value, $motive)
|
function UserAddWarn($uid, $value, $motive)
|
||||||
{
|
{
|
||||||
|
global $lng;
|
||||||
$sql = "INSERT INTO `".WARNINGS_TABLE."` ( `w_id` , `u_id` , `value` , `motive` ) VALUES('','$uid','$value','$motive');";
|
$sql = "INSERT INTO `".WARNINGS_TABLE."` ( `w_id` , `u_id` , `value` , `motive` ) VALUES('','$uid','$value','$motive');";
|
||||||
DataBase::sql_query($sql,GENERAL,'Could not add new warn.');
|
DataBase::sql_query($sql,GENERAL,'Could not add new warn.');
|
||||||
if (User::UserLevelWarns($uid)==100)
|
if (User::UserLevelWarns($uid)==100)
|
||||||
@@ -220,5 +221,31 @@ class User
|
|||||||
DataBase::sql_query($sql,GENERAL,'Could not update add ban.');
|
DataBase::sql_query($sql,GENERAL,'Could not update add ban.');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function UserLevelWarns($uid)
|
||||||
|
{
|
||||||
|
$level =0;
|
||||||
|
$sql = "SELECT `u_id`,`value` FROM `".WARNINGS_TABLE."` WHERE `u_id`='$uid'";
|
||||||
|
$query = DataBase::sql_query($sql,'GENERAL','Could not obtain user warns information');
|
||||||
|
$result = DataBase::num_rows($query);
|
||||||
|
while ($result = @DataBase::fetch($query))
|
||||||
|
{
|
||||||
|
if ($result['value']=='-')
|
||||||
|
{
|
||||||
|
$level = $level -1;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$level = $level +1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
//version 1.0 Alpha 2
|
||||||
|
//delete second query
|
||||||
|
if ($level>0)
|
||||||
|
{
|
||||||
|
$level = $level*10;
|
||||||
|
}
|
||||||
|
return $level;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ class Secure
|
|||||||
$query = DataBase::sql_query($sql,GENERAL,'Could not obtain censorlist information.');
|
$query = DataBase::sql_query($sql,GENERAL,'Could not obtain censorlist information.');
|
||||||
while($word = DataBase::fetch($query))
|
while($word = DataBase::fetch($query))
|
||||||
{
|
{
|
||||||
$text = str_replace($word['word'],'[censored]', $text);
|
$text = str_replace($word['word'],$word['replace'], $text);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return $text;
|
return $text;
|
||||||
|
|||||||
@@ -64,7 +64,6 @@ class DataBase
|
|||||||
|
|
||||||
function num_rows($query)
|
function num_rows($query)
|
||||||
{
|
{
|
||||||
// return $query->num_rows;
|
|
||||||
if ($query===true || $query===false)
|
if ($query===true || $query===false)
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
|
|||||||
@@ -138,7 +138,7 @@ function UserAgent($agent)
|
|||||||
function GenerateTime($request_time)
|
function GenerateTime($request_time)
|
||||||
{
|
{
|
||||||
global $lng;
|
global $lng;
|
||||||
if (date('d-m-Y',$request_time)== date('d-m-Y',time()))
|
if (date('d M Y',$request_time)== date('d M Y',time()))
|
||||||
{
|
{
|
||||||
$date = $lng['today'].', '.date('G:i', $request_time);
|
$date = $lng['today'].', '.date('G:i', $request_time);
|
||||||
}
|
}
|
||||||
@@ -150,7 +150,7 @@ function GenerateTime($request_time)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$date = date('d-m-Y, G:i',$request_time);
|
$date = date('d M Y, G:i',$request_time);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -284,12 +284,12 @@ function TotalPosts()
|
|||||||
return($result);
|
return($result);
|
||||||
}
|
}
|
||||||
|
|
||||||
function DefaultLang()
|
function DefaultLang($active = false)
|
||||||
{
|
{
|
||||||
global $forum_config;
|
global $forum_config;
|
||||||
global $userdata;
|
global $userdata;
|
||||||
|
|
||||||
if ($_SESSION['uid']>0)
|
if ($_SESSION['uid']>0 && !$active)
|
||||||
{
|
{
|
||||||
return $userdata['lang'];
|
return $userdata['lang'];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -120,8 +120,8 @@ $lng['files_is_good']='Wszystkie pliki są poprawne!';
|
|||||||
$lng['files_not_good']='Nie wszystkie pliki są poprawne. Jest ich: ';
|
$lng['files_not_good']='Nie wszystkie pliki są poprawne. Jest ich: ';
|
||||||
$lng['php_version']='Wersja PHP';
|
$lng['php_version']='Wersja PHP';
|
||||||
$lng['mysql_version']='Wersja serwera MySQL';
|
$lng['mysql_version']='Wersja serwera MySQL';
|
||||||
$lng['not_writable']='Katalog nie do zapisu!';
|
$lng['not_writable']='Nie do zapisu!';
|
||||||
$lng['is_writable']='Katalog do zapisu';
|
$lng['is_writable']='Do zapisu';
|
||||||
$lng['catalog']='Katalog';
|
$lng['catalog']='Katalog';
|
||||||
$lng['db_size']='Wielkość bazy';
|
$lng['db_size']='Wielkość bazy';
|
||||||
$lng['forum_size']='Wielkość plików forum';
|
$lng['forum_size']='Wielkość plików forum';
|
||||||
@@ -235,6 +235,7 @@ $lng['no_words']='Cenzura słów jest pusta';
|
|||||||
$lng['word_deleted']='Słowo zostało usunięte. <br> Powrót do cenzury słów.';
|
$lng['word_deleted']='Słowo zostało usunięte. <br> Powrót do cenzury słów.';
|
||||||
$lng['word_edited']='Słowo zostało wyedytowane. <br> Powrót do cenzury słów.';
|
$lng['word_edited']='Słowo zostało wyedytowane. <br> Powrót do cenzury słów.';
|
||||||
$lng['edit_word']='Edytuj słowo';
|
$lng['edit_word']='Edytuj słowo';
|
||||||
|
$lng['replace_to']='Zamień na';
|
||||||
//
|
//
|
||||||
//on banlist... ------------------------------------------------------------
|
//on banlist... ------------------------------------------------------------
|
||||||
//
|
//
|
||||||
|
|||||||
@@ -191,6 +191,7 @@ $lng['warns']='Ostrzeżeń';
|
|||||||
$lng['add']='Dodaj';
|
$lng['add']='Dodaj';
|
||||||
$lng['delete']='Odejmij';
|
$lng['delete']='Odejmij';
|
||||||
$lng['warns_ban']='Zostałeś zbanowany, ponieważ Twój poziom ostrzeżeń wynosi 100%.';
|
$lng['warns_ban']='Zostałeś zbanowany, ponieważ Twój poziom ostrzeżeń wynosi 100%.';
|
||||||
|
$lng['cannot_add_warn_am']='Nie możesz dodać ostrzeżenia Administratorowi/Moderatorowi!';
|
||||||
//
|
//
|
||||||
//messages...-----------------------------------------------------------------
|
//messages...-----------------------------------------------------------------
|
||||||
//
|
//
|
||||||
|
|||||||
@@ -34,13 +34,14 @@ if ($_SESSION['uid']<1)
|
|||||||
{
|
{
|
||||||
message_forum($lng['youarenotlogd'],'login.php?mode=login');
|
message_forum($lng['youarenotlogd'],'login.php?mode=login');
|
||||||
}
|
}
|
||||||
foreach ($_POST as $name => $value)
|
/**foreach ($_POST as $name => $value)
|
||||||
{
|
{
|
||||||
if ($forum_config['use_censorlist'])
|
if ($forum_config['use_censorlist'])
|
||||||
{
|
{
|
||||||
$_POST[$name] = Secure::UseCensorlist($value);
|
$_POST[$name] = Secure::UseCensorlist($value);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
*/
|
||||||
$start = TimeGeneration();
|
$start = TimeGeneration();
|
||||||
//add skin variables
|
//add skin variables
|
||||||
$skin = array(
|
$skin = array(
|
||||||
@@ -209,6 +210,7 @@ switch(trim($_GET['mode']))
|
|||||||
setcookie('antiflood_time',(time() + $forum_config['time_antiflood']));
|
setcookie('antiflood_time',(time() + $forum_config['time_antiflood']));
|
||||||
}
|
}
|
||||||
$_POST['textedit'] = Secure::TagsReplace($_POST['textedit']);
|
$_POST['textedit'] = Secure::TagsReplace($_POST['textedit']);
|
||||||
|
|
||||||
$id = Post::NewPost(intval($_GET['id']),$_POST['textedit'], $_SESSION['uid']);
|
$id = Post::NewPost(intval($_GET['id']),$_POST['textedit'], $_SESSION['uid']);
|
||||||
$count =ceil(($id / 15 ));
|
$count =ceil(($id / 15 ));
|
||||||
if ($count >1)
|
if ($count >1)
|
||||||
|
|||||||
113
search.php
@@ -29,7 +29,7 @@ $default_skin = ViewSkinName();
|
|||||||
SessDelInvalid();
|
SessDelInvalid();
|
||||||
SessRegister();
|
SessRegister();
|
||||||
SessDeleteOld();
|
SessDeleteOld();
|
||||||
$sql = "SELECT ".POSTS_TABLE.".*, ".USERS_TABLE.".* FROM ".POSTS_TABLE." LEFT JOIN ".USERS_TABLE." ON ".USERS_TABLE.".u_id = ".POSTS_TABLE.".u_id ORDER BY `ptime`";
|
/*$sql = "SELECT ".POSTS_TABLE.".*, ".USERS_TABLE.".* FROM ".POSTS_TABLE." LEFT JOIN ".USERS_TABLE." ON ".USERS_TABLE.".u_id = ".POSTS_TABLE.".u_id ORDER BY `ptime`";
|
||||||
$query = DataBase::sql_query($sql,GENERAL, 'Could not obtain amout of posts in forum');
|
$query = DataBase::sql_query($sql,GENERAL, 'Could not obtain amout of posts in forum');
|
||||||
while($result = DataBase::fetch($query))
|
while($result = DataBase::fetch($query))
|
||||||
{
|
{
|
||||||
@@ -44,11 +44,12 @@ $query = DataBase::sql_query($sql,GENERAL, 'Could not obtain amout of posts in f
|
|||||||
while($result = DataBase::fetch($query))
|
while($result = DataBase::fetch($query))
|
||||||
{
|
{
|
||||||
$count_topic[$result['t_id']]=$result['p_id'];
|
$count_topic[$result['t_id']]=$result['p_id'];
|
||||||
}
|
}*/
|
||||||
if (!isset($_GET['content']))
|
if (!isset($_GET['content']))
|
||||||
{
|
{
|
||||||
header('Location: search.php?content=posts');
|
header('Location: search.php?content=posts');
|
||||||
}
|
}
|
||||||
|
|
||||||
//
|
//
|
||||||
//generate output pages
|
//generate output pages
|
||||||
//
|
//
|
||||||
@@ -60,24 +61,48 @@ else
|
|||||||
{
|
{
|
||||||
$limiter = $forum_config['limit_ftid'];
|
$limiter = $forum_config['limit_ftid'];
|
||||||
}
|
}
|
||||||
if (isset($_GET['page'])&&($_GET['page']!=1))
|
if ($_GET['content'] == 'userposts' || $_GET['content'] == 'lastposts')
|
||||||
{
|
{
|
||||||
if (!is_numeric($_GET['page']))
|
if (isset($_GET['page'])&&($_GET['page']!=1))
|
||||||
{
|
{
|
||||||
die('Hacking attempt');
|
if (!is_numeric($_GET['page']))
|
||||||
|
{
|
||||||
|
die('Hacking attempt');
|
||||||
|
}
|
||||||
|
$value = ($_GET['page']-1)*$limiter;
|
||||||
|
$limit = 'LIMIT '.$value . ', '.$limiter;
|
||||||
|
$page = $_GET['page'];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$limit = 'LIMIT 0, '.$limiter;
|
||||||
|
$page=1;
|
||||||
}
|
}
|
||||||
$value = ($_GET['page']-1)*$limiter;
|
|
||||||
$limit = 'LIMIT '.$value . ', '.$limiter;
|
|
||||||
$page = $_GET['page'];
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$limit = 'LIMIT 0, '.$limiter;
|
if (isset($_POST['page'])&&($_POST['page']!=1))
|
||||||
$page=1;
|
{
|
||||||
|
if (!is_numeric($_POST['page']))
|
||||||
|
{
|
||||||
|
die('Hacking attempt');
|
||||||
|
}
|
||||||
|
$value = ($_POST['page']-1)*$limiter;
|
||||||
|
$limit = 'LIMIT '.$value . ', '.$limiter;
|
||||||
|
$page = $_POST['page'];
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$limit = 'LIMIT 0, '.$limiter;
|
||||||
|
$page=1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//
|
//
|
||||||
//end generating pages
|
//end generating pages
|
||||||
//
|
//
|
||||||
|
|
||||||
if ((isset($_POST['keywords'])) || ($_GET['content']=='lastposts') || ($_GET['content']=='userposts'))
|
if ((isset($_POST['keywords'])) || ($_GET['content']=='lastposts') || ($_GET['content']=='userposts'))
|
||||||
{
|
{
|
||||||
$errors = true;
|
$errors = true;
|
||||||
@@ -88,10 +113,26 @@ if ((isset($_POST['keywords'])) || ($_GET['content']=='lastposts') || ($_GET['co
|
|||||||
if ($_SESSION['uid']>0)
|
if ($_SESSION['uid']>0)
|
||||||
{
|
{
|
||||||
$time = time()-129600;
|
$time = time()-129600;
|
||||||
$sql = "SELECT ".TOPICS_TABLE.".*, ".USERS_TABLE.".* FROM ".TOPICS_TABLE." LEFT JOIN ".USERS_TABLE." ON ".TOPICS_TABLE.".author = ".USERS_TABLE.".u_id WHERE lastpost_time>$time ORDER BY `sticky` DESC, `lastpost_time` DESC LIMIT 60;";
|
$sql = "SELECT COUNT(`t_id`) as `cnt` FROM ".TOPICS_TABLE." WHERE lastpost_time>$time";
|
||||||
|
$count = DataBase::fetch(DataBase::sql_query($sql,GENERAL,'Could not obtain count amout of topics'));
|
||||||
|
$count = $count['cnt'];
|
||||||
|
$count = ceil($count / $limiter);
|
||||||
|
if ($count==0)
|
||||||
|
{
|
||||||
|
$count +=1;
|
||||||
|
}
|
||||||
|
if(isset($_GET['page']) && ($_GET['page']>$count))
|
||||||
|
{
|
||||||
|
message_forum($lng['invalidpage'],'index.php');
|
||||||
|
}
|
||||||
|
$sql = "SELECT ".TOPICS_TABLE.".*, ".USERS_TABLE.".*, ".TOPICS_TABLE.".posts AS posts
|
||||||
|
FROM ".TOPICS_TABLE."
|
||||||
|
LEFT JOIN ".USERS_TABLE." ON ".TOPICS_TABLE.".author = ".USERS_TABLE.".u_id
|
||||||
|
WHERE lastpost_time>$time
|
||||||
|
ORDER BY `sticky` DESC, `lastpost_time` DESC $limit";
|
||||||
$errors = false;
|
$errors = false;
|
||||||
$window_title = $lng['showlast30posts'];
|
$window_title = $lng['showlastposts'];
|
||||||
$navigator_title = '</a>> <a href="'.$_SERVER['REQUEST_URI'].'" class="navigator">'.$lng['showlast30posts'];
|
$navigator_title = '</a>> <a href="'.$_SERVER['REQUEST_URI'].'" class="navigator">'.$lng['showlastposts'];
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@@ -138,9 +179,13 @@ if ((isset($_POST['keywords'])) || ($_GET['content']=='lastposts') || ($_GET['co
|
|||||||
{
|
{
|
||||||
$like_where .=' OR `text` LIKE \'%'.$keyword[$i].'%\'';
|
$like_where .=' OR `text` LIKE \'%'.$keyword[$i].'%\'';
|
||||||
}
|
}
|
||||||
$sql = "SELECT COUNT(".TOPICS_TABLE.".t_id) as `count`, ".POSTS_TABLE.".* FROM ".TOPICS_TABLE." LEFT JOIN ".POSTS_TABLE." ON ".POSTS_TABLE.".t_id = ".TOPICS_TABLE.".t_id WHERE $like_where GROUP BY `t_id`";
|
$sql = "SELECT ".POSTS_TABLE.".t_id, ".POSTS_TABLE.".text
|
||||||
$count = DataBase::fetch(DataBase::sql_query($sql,GENERAL,'Could not obtain count amout of topics'));
|
FROM ".TOPICS_TABLE."
|
||||||
$count = $count['count'];
|
LEFT JOIN ".POSTS_TABLE." ON ".POSTS_TABLE.".t_id = ".TOPICS_TABLE.".t_id
|
||||||
|
WHERE $like_where GROUP BY `t_id`";
|
||||||
|
echo $sql;
|
||||||
|
$count = DataBase::sql_query($sql,GENERAL,'Could not obtain count amout of topics');
|
||||||
|
$count = DataBase::num_rows($count);//$count['count'];
|
||||||
$count = ceil($count / $limiter);
|
$count = ceil($count / $limiter);
|
||||||
if ($count==0)
|
if ($count==0)
|
||||||
{
|
{
|
||||||
@@ -150,7 +195,13 @@ if ((isset($_POST['keywords'])) || ($_GET['content']=='lastposts') || ($_GET['co
|
|||||||
{
|
{
|
||||||
message_forum($lng['invalidpage'],'index.php');
|
message_forum($lng['invalidpage'],'index.php');
|
||||||
}
|
}
|
||||||
$sql = "SELECT ".TOPICS_TABLE.".*, ".USERS_TABLE.".*, ".POSTS_TABLE.".* FROM ".TOPICS_TABLE." LEFT JOIN ".USERS_TABLE." ON ".TOPICS_TABLE.".author = ".USERS_TABLE.".u_id LEFT JOIN ".POSTS_TABLE." ON ".POSTS_TABLE.".t_id = ".TOPICS_TABLE.".t_id WHERE $like_where ORDER BY `sticky` DESC, `lastpost_time` DESC $limit;";
|
$sql = "SELECT ".TOPICS_TABLE.".*, ".USERS_TABLE.".*, ".POSTS_TABLE.".*, ".TOPICS_TABLE.".posts AS posts
|
||||||
|
FROM ".TOPICS_TABLE."
|
||||||
|
LEFT JOIN ".USERS_TABLE." ON ".TOPICS_TABLE.".author = ".USERS_TABLE.".u_id
|
||||||
|
LEFT JOIN ".POSTS_TABLE." ON ".POSTS_TABLE.".t_id = ".TOPICS_TABLE.".t_id
|
||||||
|
WHERE $like_where
|
||||||
|
ORDER BY `sticky` DESC, `lastpost_time` DESC $limit;";
|
||||||
|
|
||||||
$window_title = $lng['search_results'];
|
$window_title = $lng['search_results'];
|
||||||
$navigator_title = '</a>> <a href="'.$_SERVER['REQUEST_URI'].'" class="navigator">'.$lng['search_results'];
|
$navigator_title = '</a>> <a href="'.$_SERVER['REQUEST_URI'].'" class="navigator">'.$lng['search_results'];
|
||||||
$errors = false;
|
$errors = false;
|
||||||
@@ -187,12 +238,13 @@ if ((isset($_POST['keywords'])) || ($_GET['content']=='lastposts') || ($_GET['co
|
|||||||
{
|
{
|
||||||
if (!in_array($record['t_id'], $isset_topics))
|
if (!in_array($record['t_id'], $isset_topics))
|
||||||
{
|
{
|
||||||
|
$last_post = explode(':', $record['lastpost']);
|
||||||
$skin = array(
|
$skin = array(
|
||||||
't_id'=>$record['t_id'],
|
't_id'=>$record['t_id'],
|
||||||
'fname'=>($record['sticky']=='1') ? '<b>'.$lng['sticky'].'</b>'.$record['name'] : $record['name'],
|
'fname'=>($record['sticky']=='1') ? '<b>'.$lng['sticky'].'</b>'.$record['name'] : $record['name'],
|
||||||
'author'=>Topic::TopicAuthor($record['author']),
|
'author'=>Topic::TopicAuthor($record['author']),
|
||||||
'new_post'=>Topic::LastPostImg(),
|
'new_post'=>Topic::LastPostImg(),
|
||||||
'tposts'=>$count_topic[$record['t_id']],
|
'tposts'=>$record['posts'],
|
||||||
'lastpost'=>Topic::LastPostInTopic($record['t_id'])
|
'lastpost'=>Topic::LastPostInTopic($record['t_id'])
|
||||||
);
|
);
|
||||||
include('./skins/'.$default_skin.'/forum_forum_add.tpl');
|
include('./skins/'.$default_skin.'/forum_forum_add.tpl');
|
||||||
@@ -204,20 +256,21 @@ if ((isset($_POST['keywords'])) || ($_GET['content']=='lastposts') || ($_GET['co
|
|||||||
{
|
{
|
||||||
echo '<tr><td width="'.TABLES_WIDTH.'" colspan="10" height="19" class="fitem"><p class="fstandard" align="center">'.$lng['nopost'].'!</p></td></tr>';
|
echo '<tr><td width="'.TABLES_WIDTH.'" colspan="10" height="19" class="fitem"><p class="fstandard" align="center">'.$lng['nopost'].'!</p></td></tr>';
|
||||||
}
|
}
|
||||||
if ($_GET['content']=='lastposts')
|
$skin = array(
|
||||||
{
|
'option_pages' => AddPages(),
|
||||||
echo '</table>';
|
'lwith' => $lng['with'],
|
||||||
}
|
'lpage' => $lng['page'],
|
||||||
else
|
'lpages' => $count,
|
||||||
{
|
|
||||||
$skin = array(
|
|
||||||
'option_pages' => AddPages(),
|
|
||||||
'lwith' => $lng['with'],
|
|
||||||
'lpage' => $lng['page'],
|
|
||||||
'lpages' => $count,
|
|
||||||
);
|
);
|
||||||
include('./skins/'.$default_skin.'/search_end_body.tpl');
|
|
||||||
|
if ($_GET['content']=='posts')
|
||||||
|
{
|
||||||
|
$skin['keywords'] = $_POST['keywords'];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
include('./skins/'.$default_skin.'/search_end_body.tpl');
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 9.4 KiB |
|
Before Width: | Height: | Size: 697 B After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 985 B After Width: | Height: | Size: 940 B |
|
Before Width: | Height: | Size: 664 B After Width: | Height: | Size: 942 B |
BIN
skins/subPurple/images/uf_logo.gif
Normal file
|
After Width: | Height: | Size: 7.7 KiB |
@@ -1,9 +1,9 @@
|
|||||||
<span class="fsmall"> <br></span>
|
<span class="fsmall"> <br></span>
|
||||||
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-width: 0px">
|
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-width: 0px">
|
||||||
<tr>
|
<tr>
|
||||||
<td width="14" height="7" style="background-image: url('skins/subPurple/images/td_category_left.gif')" class="category"> </td>
|
<td width="18" height="25" style="background-image: url('skins/subPurple/images/td_category_left.gif')" class="category"> </td>
|
||||||
<td height="7"class="category" style="background-image: url('skins/subPurple/images/td_category.jpg')"><? echo $skin['category']; ?></td>
|
<td height="7"class="category" style="background-image: url('skins/subPurple/images/td_category.jpg')"><? echo $skin['category']; ?></td>
|
||||||
<td width="14" height="7" style="background-image: url('skins/subPurple/images/td_category_right.gif')" class="category"></td>
|
<td width="18" height="7" style="background-image: url('skins/subPurple/images/td_category_right.gif')" class="category"></td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-top: 0px">
|
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-top: 0px">
|
||||||
|
|||||||
@@ -6,7 +6,7 @@
|
|||||||
<meta name="keywords" content="<? echo $skin['keywords']; ?>">
|
<meta name="keywords" content="<? echo $skin['keywords']; ?>">
|
||||||
<meta name="description" content="<? echo $skin['description']; ?>">
|
<meta name="description" content="<? echo $skin['description']; ?>">
|
||||||
<link rel="stylesheet" href="skins/subPurple/skin.css" type="text/css">
|
<link rel="stylesheet" href="skins/subPurple/skin.css" type="text/css">
|
||||||
<title><? echo $skin['forumname']; ?> - <? echo $skin['mainpage']; ?></title>
|
<title><? echo $skin['forumname']; ?> • <? echo $skin['mainpage']; ?></title>
|
||||||
</head>
|
</head>
|
||||||
<body class="body">
|
<body class="body">
|
||||||
<script type="text/javascript" language="JavaScript">
|
<script type="text/javascript" language="JavaScript">
|
||||||
@@ -44,7 +44,7 @@ function unset_color(element)
|
|||||||
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-width: 0px">
|
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-width: 0px">
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<a href="index.php"><img border="0" src="skins/subPurple/images/dsf_logo.gif" alt="DSF logo"></a></td>
|
<a href="index.php"><img border="0" src="skins/subPurple/images/uf_logo.gif" alt="µF logo"></a></td>
|
||||||
<td width="502" height="75" valign="top">
|
<td width="502" height="75" valign="top">
|
||||||
<p align="center"><span class="hforum"><? echo $skin['forumname']; ?></span><br><span class="fstandard"><i><?= $skin['forumdesc']; ?></i></span></p>
|
<p align="center"><span class="hforum"><? echo $skin['forumname']; ?></span><br><span class="fstandard"><i><?= $skin['forumdesc']; ?></i></span></p>
|
||||||
<p align="center">
|
<p align="center">
|
||||||
|
|||||||
@@ -1,4 +1,7 @@
|
|||||||
</table>
|
</table>
|
||||||
|
<?php if ($_GET['content'] == 'userposts' || $_GET['content'] == 'lastposts')
|
||||||
|
{
|
||||||
|
?>
|
||||||
<div style="width: 100%; text-align: right">
|
<div style="width: 100%; text-align: right">
|
||||||
<span class="fsmall"><?=$skin['lpage']; ?>:
|
<span class="fsmall"><?=$skin['lpage']; ?>:
|
||||||
<select name="page" onchange="location='<?= $_SERVER['REQUEST_URI']; ?>&page='+(this.value)">
|
<select name="page" onchange="location='<?= $_SERVER['REQUEST_URI']; ?>&page='+(this.value)">
|
||||||
@@ -7,3 +10,22 @@
|
|||||||
<?= $skin['lwith']; ?> <?= $skin['lpages']; ?>
|
<?= $skin['lwith']; ?> <?= $skin['lpages']; ?>
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
?>
|
||||||
|
<form action="<?= $_SERVER['REQUEST_URI']; ?>" method="post">
|
||||||
|
<input type="hidden" name="keywords" value="<?= $skin['keywords']; ?>">
|
||||||
|
<div style="width: 100%; text-align: right">
|
||||||
|
<span class="fsmall"><?=$skin['lpage']; ?>:
|
||||||
|
<select name="page" onchange="this.form.submit()">
|
||||||
|
<?= $skin['option_pages']; ?>
|
||||||
|
</select>
|
||||||
|
<?= $skin['lwith']; ?> <?= $skin['lpages']; ?>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
<?php
|
||||||
|
}
|
||||||
|
?>
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<td width="17" style="background-image: url('skins/subPurple/images/td_beam_left.gif')"></td>
|
<td width="17" style="background-image: url('skins/subPurple/images/td_beam_left.gif')"></td>
|
||||||
<td width="100" id="p<? echo $skin['tp_id']; ?>" height="14" class="beam" align="center" style="background-image: url('skins/subPurple/images/td_beam_top.gif')"></td>
|
<td width="100" id="p<? echo $skin['tp_id']; ?>" height="14" class="beam" align="center" style="background-image: url('skins/subPurple/images/td_beam_top.gif')"></td>
|
||||||
<td width="<?= (TABLES_WIDTH -244); ?>" height="14" class="beam" align="center" style="background-image: url('skins/subPurple/images/td_beam_top.gif')"><?= $skin['lpost']?></td>
|
<td width="<?= (TABLES_WIDTH -244); ?>" height="14" class="beam" align="center" style="background-image: url('skins/subPurple/images/td_beam_top.gif')"><?= $skin['lpost']?></td>
|
||||||
<td width="110" height="15" class="beam" align="center" style="background-image: url('skins/subPurple/images/td_beam_top.gif')"><? echo $skin['lpinfo']; ?></td>
|
<td width="110" height="15" class="beam" align="center" style="background-image: url('skins/subPurple/images/td_beam_top.gif')"><? echo $skin['L.p_info']; ?></td>
|
||||||
<td width="17" style="background-image: url('skins/subPurple/images/td_beam_right.gif')"></td>
|
<td width="17" style="background-image: url('skins/subPurple/images/td_beam_right.gif')"></td>
|
||||||
</tr>
|
</tr>
|
||||||
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-top: 0px">
|
<table class="maintable" width="<?= TABLES_WIDTH; ?>" style="border-top: 0px">
|
||||||
@@ -17,11 +17,10 @@
|
|||||||
<p align="left"><span class="fstandard"><? echo $skin['posttext']; ?></span><p class="fsmall" align="left"><? echo $skin['sig']; ?></p></p>
|
<p align="left"><span class="fstandard"><? echo $skin['posttext']; ?></span><p class="fsmall" align="left"><? echo $skin['sig']; ?></p></p>
|
||||||
</td>
|
</td>
|
||||||
<td width="148" height="22" class="fitem" align="center" valign="top">
|
<td width="148" height="22" class="fitem" align="center" valign="top">
|
||||||
<span class="fsmall">Post <? echo $skin['lno']; ?> </span>
|
<span class="fsmall">Post <? echo $skin['L.no']; ?> </span>
|
||||||
<a href="#p<? echo $skin['tp_id']; ?>" class="fsmall"><b>#<? echo $skin['tp_id']; ?></b></a><br>
|
<a href="#p<? echo $skin['tp_id']; ?>" class="fsmall"><b>#<? echo $skin['tp_id']; ?></b></a><br>
|
||||||
<span class="fsmall"><? echo $skin['ldate']; ?>: <b><? echo $skin['pdate']; ?></b></span><br>
|
<span class="fsmall"><? echo $skin['L.date']; ?>: <b><? echo $skin['pdate']; ?></b></span><br>
|
||||||
<span class="fsmall"><?= $skin['warns_pool']; ?></span><br>
|
<span class="fsmall"><?= $skin['warns_pool']; ?></span>
|
||||||
<span class="fsmall"><b><?= $skin['lstat']; ?>: </b></span><img src="images/<?= $skin['online']?>" alt="online">
|
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
@@ -42,7 +41,7 @@
|
|||||||
<span class="fsmall"><b><?= $skin['admin'];?></b><br></span>
|
<span class="fsmall"><b><?= $skin['admin'];?></b><br></span>
|
||||||
<span class="fsmall"><?= $skin['L.IP']; ?></span>
|
<span class="fsmall"><?= $skin['L.IP']; ?></span>
|
||||||
<? echo $skin['mode_p_del']; ?>
|
<? echo $skin['mode_p_del']; ?>
|
||||||
<a href="http://localhost/DSF/warns.php?mode=add&id=<?= $skin['u_id']; ?>" class="fsmall" style="color: green"><?= $skin['add_warn']; ?></a><br>
|
<a href="warns.php?mode=add&id=<?= $skin['u_id']; ?>" class="fsmall" style="color: green"><?= $skin['add_warn']; ?></a><br>
|
||||||
<? if (RANK==2) { ?>
|
<? if (RANK==2) { ?>
|
||||||
<a href="admin/admin_users.php?mode=edit&id=<?= $skin['u_id']; ?>" class="fsmall" style="color: red"><?= $skin['edit_profile']; ?></a><br>
|
<a href="admin/admin_users.php?mode=edit&id=<?= $skin['u_id']; ?>" class="fsmall" style="color: red"><?= $skin['edit_profile']; ?></a><br>
|
||||||
<a href="admin/banlist.php?mode=add&submode=all&ip=<?= $skin['IP']; ?>&uid=<?= $skin['u_id']; ?>" class="fsmall" style="color: red"><?= $skin['ban']; ?></a><br>
|
<a href="admin/banlist.php?mode=add&submode=all&ip=<?= $skin['IP']; ?>&uid=<?= $skin['u_id']; ?>" class="fsmall" style="color: red"><?= $skin['ban']; ?></a><br>
|
||||||
@@ -52,11 +51,11 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<? } }?>
|
<? } }?>
|
||||||
<tr>
|
<tr>
|
||||||
<td width="116" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['userrank']; ?></td>
|
<td width="116" height="1" class="fitem" align="center"><span class="fsmall"><?= $skin['lstat']; ?>: </span><img src="images/<?= $skin['online']?>" alt="online"></span></td>
|
||||||
<td width="105" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['lposts']; ?>: <b><? echo $skin['posts']; ?></b></span></td>
|
<td width="105" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['lposts']; ?>: <b><? echo $skin['posts']; ?></b></span></td>
|
||||||
<td width="153" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['lregdate']; ?>: <b><? echo $skin['regdate']; ?></b></span></td>
|
<td width="153" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['lregdate']; ?>: <b><? echo $skin['regdate']; ?></b></span></td>
|
||||||
<td width="228" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['llastvisit']; ?>: <b><? echo $skin['lastvisit']; ?></b></span></td>
|
<td width="228" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['llastvisit']; ?>: <b><? echo $skin['lastvisit']; ?></b></span></td>
|
||||||
<td width="142" height="1" class="fitem" align="center"><span class="fsmall"> </span></td>
|
<td width="142" height="1" class="fitem" align="center"><span class="fsmall"><? echo $skin['userrank']; ?></span></td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<span class="fverysmall"> <br></span>
|
<span class="fverysmall"> <br></span>
|
||||||
|
|||||||
10
topic.php
@@ -87,7 +87,7 @@ while($item=DataBase::fetch($query))
|
|||||||
'warns_pool' => $warn_pool,
|
'warns_pool' => $warn_pool,
|
||||||
'lstat'=>$lng['stat'],
|
'lstat'=>$lng['stat'],
|
||||||
'rowspan'=> ($_SESSION['uid']>0) ? ((RANK>0) ? '3' : '2') : '2',
|
'rowspan'=> ($_SESSION['uid']>0) ? ((RANK>0) ? '3' : '2') : '2',
|
||||||
'L.IP' => ($_SESSION['uid']>0) ? ((($forum_config['ip_post_for_mod'] && (RANK>0)) || (RANK==2) ) ? 'IP: '.$item['post_ip'].'<br>' : '') : '',
|
'L.IP' => ($_SESSION['uid']>0) ? ((($forum_config['ip_post_for_mod'] && (RANK>0)) || (RANK==2) ) ? 'IP: '.$item['post_ip'].' (<a href="http://whois.domaintools.com/'.$item['post_ip'].'" class="fsmall"><i>WHOIS</i></a>)<br>' : '') : '',
|
||||||
'IP'=>$item['post_ip'],
|
'IP'=>$item['post_ip'],
|
||||||
'admin'=>$lng['admin_mod_administration'],
|
'admin'=>$lng['admin_mod_administration'],
|
||||||
'mode_p_del' => ($item['tp_id']!='1') ?
|
'mode_p_del' => ($item['tp_id']!='1') ?
|
||||||
@@ -100,9 +100,9 @@ while($item=DataBase::fetch($query))
|
|||||||
'add_warn'=>$lng['add_warn'],
|
'add_warn'=>$lng['add_warn'],
|
||||||
'online'=>($item['time']!=NULL) ? (($item['time']+1250)>time()) ? 'online.gif' : 'offline.gif' : 'offline.gif',
|
'online'=>($item['time']!=NULL) ? (($item['time']+1250)>time()) ? 'online.gif' : 'offline.gif' : 'offline.gif',
|
||||||
//labels
|
//labels
|
||||||
'lwarns'=>$lng['warns'],
|
'L.warns'=>$lng['warns'],
|
||||||
'lang'=>$default_lang,
|
'lang'=>$default_lang,
|
||||||
'ldate'=>$lng['date'],
|
'L.date'=>$lng['date'],
|
||||||
'llastvisit'=>$lng['lulastvisit'],
|
'llastvisit'=>$lng['lulastvisit'],
|
||||||
'lregdate'=>$lng['regdate2'],
|
'lregdate'=>$lng['regdate2'],
|
||||||
'lposts'=>$lng['posts'],
|
'lposts'=>$lng['posts'],
|
||||||
@@ -110,8 +110,8 @@ while($item=DataBase::fetch($query))
|
|||||||
'ua_system_desc'=>$lng['system'].' '.$ua[2],
|
'ua_system_desc'=>$lng['system'].' '.$ua[2],
|
||||||
'ua_browser'=>$ua[1],
|
'ua_browser'=>$ua[1],
|
||||||
'ua_browser_desc'=>$lng['browser'].' '.$ua[3],
|
'ua_browser_desc'=>$lng['browser'].' '.$ua[3],
|
||||||
'lno'=>$lng['no.'],
|
'L.no'=>$lng['no.'],
|
||||||
'lpinfo'=>$lng['postinfo'],
|
'L.p_info'=>$lng['postinfo'],
|
||||||
'lpost'=>$lng['post'],
|
'lpost'=>$lng['post'],
|
||||||
'C.delete_post'=>$lng['c_delete_post']
|
'C.delete_post'=>$lng['c_delete_post']
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -58,6 +58,13 @@ switch(trim($_GET['mode']))
|
|||||||
{
|
{
|
||||||
if ((strpos($_POST['value'],'+')!==false) or (strpos($_POST['value'],'-')!==false))
|
if ((strpos($_POST['value'],'+')!==false) or (strpos($_POST['value'],'-')!==false))
|
||||||
{
|
{
|
||||||
|
if ($_POST['value'] == '+')
|
||||||
|
{
|
||||||
|
if (User::UserInformation($_GET['id'],'rank')>0)
|
||||||
|
{
|
||||||
|
message_forum($lng['cannot_add_warn_am'],'warns.php?mode=view&id='.$_GET['id']);
|
||||||
|
}
|
||||||
|
}
|
||||||
$_POST['textedit'] = Secure::TagsReplace($_POST['textedit']);
|
$_POST['textedit'] = Secure::TagsReplace($_POST['textedit']);
|
||||||
User::UserAddWarn($_GET['id'],$_POST['value'] ,addslashes(strip_tags($_POST['textedit'])));
|
User::UserAddWarn($_GET['id'],$_POST['value'] ,addslashes(strip_tags($_POST['textedit'])));
|
||||||
$stop = TimeGeneration();
|
$stop = TimeGeneration();
|
||||||
|
|||||||