⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 addblock_popup.php

📁 通达OA部分源代码
💻 PHP
字号:
<?
//include_once("logincheck.php");
include_once("myconnect.php");
include_once "styles.php";
if (!isset($_SESSION["sbbleads_userid"]) )
{
   $msg1="You must be logged-in to perform this operation";
}
else
{	//main else
if (!isset($_REQUEST["username"]) || $_REQUEST["username"]=="" )
{
   $msg1="Please fill in the username of the user to add him/her to the block list";
}
else
{
if ($_REQUEST["username"]==$_SESSION["sbbleads_username"])
{
		$msg1="You cannot add yourself to your block list"	;
}
else
{
	$rs=mysql_query("Select * from sbbleads_members  where sb_username ='" . $_REQUEST["username"]. "'" );
	if ($rs=mysql_fetch_array($rs))
	{
	  $rs1=mysql_query("Select * from sbbleads_blocked  where sb_uid =" .$_SESSION["sbbleads_userid"] ." and sb_blocked_id=" . $rs["sb_id"] );
	   if ($rs1=mysql_fetch_array($rs1))
	   {
		$msg1="User is already in your block list"	;
	   }
       else
	   {	
	    mysql_query("insert into sbbleads_blocked (sb_uid,sb_blocked_id) VALUES(" . $_SESSION["sbbleads_userid"] ."," . $rs["sb_id"] .")");
		$msg1="User has been added to your block list"	;
	   } ///User already in contact list
	
	} 
	else
	{
		$msg1="No user with username ".$_REQUEST["username"]." exists"	;
	
	}	//Username cannot be found

} //Cannot Add yourself to contact list


}
}	//end else main

?><strong><font class='red'><?php echo $msg1; ?></font></strong><br>
<font class="normal">
Click <a href="#" onClick="window.close()">here</a> to close this window
</font>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -