<?php
session_start();
include ('dbf.php');
if ($_SESSION[user]=='استبصار' and $_SESSION[pass]=='110110')
{
if (isset($_POST['sub']))
{
	copy($_FILES[picture][tmp_name],"picture/baner.jpg");
}
if (isset($_GET['soatdel']))
{
	$fg=mysql_query("delete from `soati` where ip={$_GET['soatdel']}");
	echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
}
if (isset($_POST['soti']) and $_POST['soatiname']!=="")
{
	mysql_query("insert into `soati` (name,name1,oulaviat) VALUES ('{$_POST['soatiname']}','{$_POST['soatiname1']}','{$_POST['oulaviat']}')");

	$qu=mysql_query("select max(ip)as p from `soati` order by ip");
	$rows=mysql_fetch_assoc($qu);
	$mptree=$rows['p'];

	copy($_FILES[picture15][tmp_name],"soati/".$mptree.".mp3");
}
if (isset($_GET['childdel']))
{
	$fg=mysql_query("delete from `child` where ip={$_GET['childdel']}");
	echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
}
if (isset($_POST['child']) and $_POST['childname']!=="")
{
	mysql_query("insert into `child` (name,name1,oulaviat) VALUES ('{$_POST['childname']}','{$_POST['childname1']}','{$_POST['oulaviat']}')");

	$qu=mysql_query("select max(ip)as p from `child` order by ip");
	$rows=mysql_fetch_assoc($qu);
	$mptree=$rows['p'];

	copy($_FILES[picture15][tmp_name],"child/".$mptree.".mp3");
}
if (isset($_GET['doadel']))
{
	$fg=mysql_query("delete from `doa` where ip={$_GET['doadel']}");
	echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
}
if (isset($_POST['doa']) and $_POST['doaname']!=="")
{
	mysql_query("insert into `doa` (name,name1,oulaviat) VALUES ('{$_POST['doaname']}','{$_POST['doaname1']}','{$_POST['oulaviat']}')");

	$qu=mysql_query("select max(ip)as p from `doa` order by ip");
	$rows=mysql_fetch_assoc($qu);
	$mptree=$rows['p'];

	copy($_FILES[picture15][tmp_name],"doa/".$mptree.".mp3");
}
if (isset($_GET['ghamindel']))
{
	$fg=mysql_query("delete from `ghamin` where ip={$_GET['ghamindel']}");
	echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
}
if (isset($_POST['ghamin']) and $_POST['ghaminname']!=="")
{
	mysql_query("insert into `ghamin` (name,name1,oulaviat) VALUES ('{$_POST['ghaminname']}','{$_POST['ghaminname1']}','{$_POST['oulaviat']}')");

	$qu=mysql_query("select max(ip)as p from `ghamin` order by ip");
	$rows=mysql_fetch_assoc($qu);
	$mptree=$rows['p'];

	copy($_FILES[picture15][tmp_name],"ghamin/".$mptree.".mp4");
}
if (isset($_GET['neshastdel']))
{
	$fg=mysql_query("delete from `neshast` where ip={$_GET['neshastdel']}");
	echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
}
if (isset($_POST['neshast']) and $_POST['neshastname']!=="")
{
	mysql_query("insert into `neshast` (name,name1,oulaviat) VALUES ('{$_POST['neshastname']}','{$_POST['neshastname1']}','{$_POST['oulaviat']}')");

	$qu=mysql_query("select max(ip)as p from `neshast` order by ip");
	$rows=mysql_fetch_assoc($qu);
	$mptree=$rows['p'];

	copy($_FILES[picture15][tmp_name],"neshast/".$mptree.".mp3");
}
if (isset($_POST['ebo_c']))
mysql_query("update tanzim set iconcolor1='{$_POST['ebo_c']}' ");

if (isset($_POST['ebo_cc']))
mysql_query("update tanzim set iconcolor2='{$_POST['ebo_cc']}' ");

if (isset($_POST['okhom']))
{
	mysql_query("update tanzim set homline1='{$_POST['homline1']}',homline2='{$_POST['homline2']}',homline3='{$_POST['homline3']}',homline4='{$_POST['homline4']}'
	,homline5='{$_POST['homline5']}',homline6='{$_POST['homline6']}',homline7='{$_POST['homline7']}',homline8='{$_POST['homline8']}'
	,homline9='{$_POST['homline9']}',homline10='{$_POST['homline10']}' ");
}
if (isset($_POST['oklink']))
{
	mysql_query("update tanzim set linkname1='{$_POST['linkname1']}',linkname2='{$_POST['linkname2']}',linkname3='{$_POST['linkname3']}'
	,linkname4='{$_POST['linkname4']}',linkname5='{$_POST['linkname5']}',linkname6='{$_POST['linkname6']}',linkname7='{$_POST['linkname7']}'
	,linkname8='{$_POST['linkname8']}',linkname9='{$_POST['linkname9']}',linkname10='{$_POST['linkname10']}'
	,linkaddres1='{$_POST['linkaddres1']}',linkaddres2='{$_POST['linkaddres2']}',linkaddres3='{$_POST['linkaddres3']}'
	,linkaddres4='{$_POST['linkaddres4']}',linkaddres5='{$_POST['linkaddres5']}',linkaddres6='{$_POST['linkaddres6']}'
	,linkaddres7='{$_POST['linkaddres7']}',linkaddres8='{$_POST['linkaddres8']}',linkaddres9='{$_POST['linkaddres9']}'
	,linkaddres10='{$_POST['linkaddres10']}' ");
}
if (isset($_POST['sabtact']))
{
	if ($_POST['ip']==1)	{ $actionname='action1'; $actionpic='actionpic1'; }
	if ($_POST['ip']==2)	{ $actionname='action2'; $actionpic='actionpic2'; }
	if ($_POST['ip']==3)	{ $actionname='action3'; $actionpic='actionpic3'; }
	if ($_POST['ip']==4)	{ $actionname='action4'; $actionpic='actionpic4'; }
	if ($_POST['ip']==5)	{ $actionname='action5'; $actionpic='actionpic5'; }

	$pic=$_POST['ip'];
	//$pic=$_FILES['up']['name'];
	copy($_FILES[up1][tmp_name],"images/action/".$pic.".jpg");
	$address=$_FILES['up1']['name'];

//	if(is_uploaded_file($_FILES['up']['tmp_name']))
//	{
//		    $fmat=$_FILES['up']['name'];
//			$fm=explode('.',$fmat);
//			copy($_FILES['up']['tmp_name'],"images/action/$fmat");
//    		$address="images/action/".$fmat;
//    		$na=$fmat;
//    }
	mysql_query("update tanzim set $actionname='{$_POST['action']}',$actionpic='{$address}' ");
}
$q2=mysql_query("select * from tanzim ");
$cd2=mysql_fetch_assoc($q2);
include ('head1.php');
?>
<script src="sa.js"></script>
	<tr>
		<td align="center" colspan="15" height="420"  background="images/body.jpg">
			<?php
			if (isset($_GET['doa']) or isset($_POST['doa']))
			{
			?>
			<form id="doa" name="form1" method="post" action="managee.php"  onSubmit="return funsu();" enctype="multipart/form-data">
			<input name="soatt" type="hidden" value="1">
			<table width="50%" border="0" >
				<tr>
					<td colspan="3" align="center">
						<table width="80%" border="1"><span style="font-family:tahoma;font-size:10pt;color:black"><b>لیست فایل های مربوط به ادعیه
				<tr align="center" style="font-family:tahoma;font-size:10pt;color:black" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td>حذف</td>
					<td><b>ردیف</td>
					<td><b>نام فایل</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;

				$q3=mysql_query("select * from doa order by ip ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<a  title="حذف" href="managee.php?doa=1&&doadel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $cd3['name']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام:
						<input name="doaname" type="text" size="50" >
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام فرعی:
						<input name="doaname1" type="text" size="50" tabindex="1">
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						اولویت:
						<input name="oulaviat" type="text" size="10" tabindex="1">
					</td>
				</tr>
				<tr>
					<td align="left">
						<span style="font-family:tahoma;font-size:10pt"><b>
						لطفاً فایل مورد نظر را انتخاب فرمایید:
					</td>
					<td align="right">
						<input tabindex="1" name="picture15" type="file" size="15" maxlength="150" />
					</td>
				</tr>
				<tr align="center">
					<td colspan="2" align="center" height="100">
						<button  tabindex="2" name="doa" title="ذخیره اطلاعات"  type="submit" ><img src="images/40.png"  name="Add"  border="0" width="25" height="25" ></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			elseif (isset($_GET['ghamin']) or isset($_POST['ghamin']))
			{
			?>
			<form id="form1" name="form1" method="post" action="managee.php"  onSubmit="return funsu();" enctype="multipart/form-data">
			<input name="ghamin" type="hidden" value="1">
			<table width="50%" border="0" >
				<tr>
					<td colspan="3" align="center">
						<table width="80%" border="1"><span style="font-family:tahoma;font-size:10pt;color:black"><b>لیست فایل های مربوط به غمین
				<tr align="center" style="font-family:tahoma;font-size:10pt;color:black" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td>حذف</td>
					<td><b>ردیف</td>
					<td><b>نام فایل</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;

				$q3=mysql_query("select * from ghamin order by ip ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<a  title="حذف" href="managee.php?ghamin=1&&ghamindel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $cd3['name']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام:
						<input name="ghaminname" type="text" size="50" >
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام فرعی:
						<input name="ghaminname1" type="text" size="50" tabindex="1">
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						اولویت:
						<input name="oulaviat" type="text" size="10" tabindex="1">
					</td>
				</tr>
				<tr>
					<td align="left">
						<span style="font-family:tahoma;font-size:10pt"><b>
						لطفاً فایل مورد نظر را انتخاب فرمایید:
					</td>
					<td align="right">
						<input tabindex="1" name="picture15" type="file" size="15" maxlength="150" />
					</td>
				</tr>
				<tr align="center">
					<td colspan="2" align="center" height="100">
						<button  tabindex="2" name="ghamin" title="ذخیره اطلاعات"  type="submit" ><img src="images/40.png"  name="Add"  border="0" width="25" height="25" ></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			elseif (isset($_GET['neshast']) or isset($_POST['neshast']))
			{
			?>
			<form id="form1" name="form1" method="post" action="managee.php"  onSubmit="return funsu();" enctype="multipart/form-data">
			<input name="neshast" type="hidden" value="1">
			<table width="50%" border="0" >
				<tr>
					<td colspan="3" align="center">
						<table width="80%" border="1"><span style="font-family:tahoma;font-size:10pt;color:black"><b>لیست فایل های مربوط به نشست ها
				<tr align="center" style="font-family:tahoma;font-size:10pt;color:black" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td>حذف</td>
					<td><b>ردیف</td>
					<td><b>نام فایل</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;

				$q3=mysql_query("select * from neshast order by ip ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<a  title="حذف" href="managee.php?neshast=1&&neshastdel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $cd3['name']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام:
						<input name="neshastname" type="text" size="50" >
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام فرعی:
						<input name="neshastname1" type="text" size="50" tabindex="1">
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						اولویت:
						<input name="oulaviat" type="text" size="10" tabindex="1">
					</td>
				</tr>
				<tr>
					<td align="left">
						<span style="font-family:tahoma;font-size:10pt"><b>
						لطفاً فایل مورد نظر را انتخاب فرمایید:
					</td>
					<td align="right">
						<input tabindex="1" name="picture15" type="file" size="15" maxlength="150" />
					</td>
				</tr>
				<tr align="center">
					<td colspan="2" align="center" height="100">
						<button  tabindex="2" name="neshast" title="ذخیره اطلاعات"  type="submit" ><img src="images/40.png"  name="Add"  border="0" width="25" height="25" ></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			elseif (isset($_GET['child']) or isset($_POST['child']))
			{
			?>
			<form id="form1" name="form1" method="post" action="managee.php"  onSubmit="return funsu();" enctype="multipart/form-data">
			<input name="child" type="hidden" value="1">
			<table width="50%" border="0" >
				<tr>
					<td colspan="3" align="center">
						<table width="80%" border="1"><span style="font-family:tahoma;font-size:10pt;color:black"><b>لیست فایل های مربوط به کودک و نوجوان
				<tr align="center" style="font-family:tahoma;font-size:10pt;color:black" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td>حذف</td>
					<td><b>ردیف</td>
					<td><b>نام فایل</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;

				$q3=mysql_query("select * from child order by ip ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<a  title="حذف" href="managee.php?child=1&&childdel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $cd3['name']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام:
						<input name="childname" type="text" size="50" >
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام فرعی:
						<input name="childname1" type="text" size="50" tabindex="1">
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						اولویت:
						<input name="oulaviat" type="text" size="10" tabindex="1">
					</td>
				</tr>
				<tr>
					<td align="left">
						<span style="font-family:tahoma;font-size:10pt"><b>
						لطفاً فایل مورد نظر را انتخاب فرمایید:
					</td>
					<td align="right">
						<input tabindex="1" name="picture15" type="file" size="15" maxlength="150" />
					</td>
				</tr>
				<tr align="center">
					<td colspan="2" align="center" height="100">
						<button  tabindex="2" name="child" title="ذخیره اطلاعات"  type="submit" ><img src="images/40.png"  name="Add"  border="0" width="25" height="25" ></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			elseif (isset($_GET['soat']) or isset($_POST['soatt']))
			{
			?>
			<form id="form1" name="form1" method="post" action="managee.php"  onSubmit="return funsu();" enctype="multipart/form-data">
			<input name="soatt" type="hidden" value="1">
			<table width="50%" border="0" >
				<tr>
					<td colspan="3" align="center">
						<table width="80%" border="1"><span style="font-family:tahoma;font-size:10pt;color:black"><b>لیست فایل های صوتی
				<tr align="center" style="font-family:tahoma;font-size:10pt;color:black" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td>حذف</td>
					<td><b>ردیف</td>
					<td><b>نام فایل صوتی</td>
					<td><b>نام فرعی</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;

				$q3=mysql_query("select * from soati order by ip ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<a  title="حذف" href="managee.php?soat=1&&soatdel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $cd3['name']; ?></td>
					<td><?php echo $cd3['name1']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام:
						<input name="soatiname" type="text" size="50" tabindex="1" >
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						نام فرعی:
						<input name="soatiname1" type="text" size="50" tabindex="1">
					</td>
				</tr>
				<tr>
					<td colspan="2" align="center">
						<span style="font-family:tahoma;font-size:10pt"><b>
						اولویت:
						<input name="oulaviat" type="text" size="10" tabindex="1">
					</td>
				</tr>
				<tr>
					<td align="left">
						<span style="font-family:tahoma;font-size:10pt"><b>
						لطفاً فایل مورد نظر را انتخاب فرمایید:
					</td>
					<td align="right">
						<input tabindex="1" name="picture15" type="file" size="15" maxlength="150" />
					</td>
				</tr>
				<tr align="center">
					<td colspan="2" align="center" height="100">
						<button  tabindex="2" name="soti" title="ذخیره اطلاعات"  type="submit" ><img src="images/40.png"  name="Add"  border="0" width="25" height="25" ></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			elseif (isset($_GET['tan']) AND isset($_GET['baner']))
			{
			?>
			<form id="form1" name="form1" method="post" action="managee.php"  onSubmit="return funsu();" enctype="multipart/form-data">
			<table width="100%">
				<tr>
					<td align="left">
						<span style="font-family:tahoma;font-size:10pt"><b>
						لطفاً تصویر مورد نظر را انتخاب فرمایید:
					</td>
					<td align="right">
						<input tabindex="1" name="picture" type="file" size="15" maxlength="150" />
					</td>
				</tr>
				<tr align="center">
					<td colspan="2" align="center" height="100">
						<button  tabindex="2" name="sub" title="ذخیره اطلاعات"  type="submit" ><img src="images/40.png"  name="Add"  border="0" width="25" height="25" ></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			elseif (isset($_GET['tan']) AND isset($_GET['color']))
			{
			?>
			<form id="form1" name="form1" method="post" action="managee.php"  onSubmit="return funsu();" enctype="multipart/form-data">
			<table width="30%" border="0">
				<tr>
					<td align="left" width="50%">
						<span style="font-family:tahoma;font-size:10pt"><b>
						لطفا رنگ مورد نظر را انتخاب فرمایید:
					</td>
					<td align="right">
						&nbsp;&nbsp;
						<button tabindex="1" type="button" title="رنگ اولیه منوها"  name="bo_c"  onclick="ajaxbo_c('1')" value="1"><img src="images/im2.png"    border="0" height="18" width="18"></button>
						<button tabindex="2" type="button" title="رنگ دوم منوها"  name="bo_cc"  onclick="ajaxbo_cc('1')" value="1"><img src="images/im2.png"    border="0" height="18" width="18"></button>
					</td>
				</tr>
				<tr align="center">
					<td colspan="2" align="center" height="100">
						<div id="am" align="right" style="padding-bottom:10px">
						</div>
						<button  tabindex="3" name="sub1" title="ذخیره اطلاعات"  type="submit" ><img src="images/40.png"  name="Add"  border="0" width="25" height="25" ></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			elseif (isset($_GET['tan']))
			{
			?>
			<table width="20%" border="1">
				<tr >
					<td height="60" align="center"  onmouseover="this.style.backgroundColor='<?php echo $cd2['iconcolor2']; ?>';" onmouseout="this.style.backgroundColor='<?php echo $cd2['iconcolor1']; ?>';" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
						<a href="managee.php?tan=1&baner=1"  style="text-decoration:none;color:black;font-family:tahoma;font-size:10pt;" onmouseover="this.style.Color='red';" >
						<b>
						تصویر بنر فوقانی
						</a>
					</td>
				</tr>
				<tr>
					<td height="60" align="center"  onmouseover="this.style.backgroundColor='<?php echo $cd2['iconcolor2']; ?>';" onmouseout="this.style.backgroundColor='<?php echo $cd2['iconcolor1']; ?>';" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
						<a href="managee.php?tan=1&color=1"  style="text-decoration:none;color:black;font-family:tahoma;font-size:10pt;" onmouseover="this.style.Color='red';" >
						<b>
						رنگ زیرین منو
						</a>
					</td>
				</tr>
			</table>
			<?php
			}
			elseif (isset($_GET['say']))
			{
			if (isset($_GET['saydel']))
			{
			$fg=mysql_query("delete from `site_ask` where ip={$_GET['saydel']}");
			echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
			}
			?>
			<table width="60%" border="1">لیست سوالات/مطالب  دریافتی از سایت
				<tr align="center" style="font-family:tahoma;font-size:10pt;" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td>حذف</td>
					<td><b>ردیف</td>
					<td><b>تاریخ</td>
					<td><b>نام و نام خانوادگی</td>
					<td><b>تلفن</td>
					<td><b>ایمیل</td>
					<td><b>سوال/مطلب</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;
				$q3=mysql_query("select * from site_ask order by date ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<a href="managee.php?say=1&&saydel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $cd3['date']; ?></td>
					<td><?php echo $cd3['name']; ?></td>
					<td><?php echo $cd3['tell']; ?></td>
					<td><?php echo $cd3['mail']; ?></td>
					<td><?php echo $cd3['matn']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
			<?php
			}
			elseif (isset($_GET['ozvmatn']))
			{
			if (isset($_GET['ozvmatnupdate']))
			{
				$q113=mysql_query("select * from matnozv where (ip='{$_GET['ozvmatnupdate']}') order by date ");
				$cd113=mysql_fetch_assoc($q113);
				?>
				<form method="post" action="managee.php?ozvmatn=1&&ozvmatnupdate1=<?php echo $cd113['ip']; ?>">
				<table width="60%" align="center"  border="1">
					<tr  style="font-family:tahoma;font-size:10pt;">
						<td align="right"><b>
							ویرایش مطلب ارسالی:
						</td>
					</tr>
					<tr  align="center" style="font-family:tahoma;font-size:10pt;">
						<td align="center">
							<textarea cols="110" rows="15" name="matn">
							<?php
							echo $cd113['matn'];
							?>
							</textarea>
						</td>
					</tr>
					<tr  align="center" style="font-family:tahoma;font-size:10pt;">
						<td align="center">
							<button  tabindex="11" name="okhom11" title="ذخیره اطلاعات"  type="submit" ><img src="images/b_edit.png"  name="Add"  border="0" width="25" height="25" ></button>
						</td>
					</tr>
				</table>
				</form>
				<?php
			}
			if (isset($_GET['ozvmatnupdate1']))
			{
				$fg=mysql_query("update `matnozv` set matn='{$_POST['matn']}' where ip='{$_GET['ozvmatnupdate1']}' ");
				echo"<script>window.alert('اطلاعات ذخیره شد');</script>";
			}
			if (isset($_GET['ozvmatndel']))
			{
			$fg=mysql_query("delete from `matnozv` where ip='{$_GET['ozvmatndel']}' ");
			echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
			}
			if (isset($_GET['ozvmatnnook']))
			{
			mysql_query("update matnozv set ok_manager='0' where (ip='{$_GET['ozvmatnnook']}') ");
			echo"<script>window.alert('تایید مطلب حذف شد، مطلب برای اعضاء نمایش داده نمی شود');</script>";
			}
			if (isset($_GET['ozvmatnok']))
			{
			mysql_query("update matnozv set ok_manager='1' where (ip='{$_GET['ozvmatnok']}') ");
			echo"<script>window.alert('تاییدیه مطلی ذخیره شد ، مطلب برای اعضاء نمایش داده خواهد شد');</script>";
			}
			?>
			<table width="80%" border="1">لیست مطالب ارسالی توسط اعضاء
				<tr align="center" style="font-family:tahoma;font-size:10pt;color:#FFFFFF" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td>تایید</td>
					<td>حذف</td>
					<td>ویرایش</td>
					<td><b>ردیف</td>
					<td><b>تاریخ</td>
					<td><b>نام و نام خانوادگی</td>
					<td><b>موضوع</td>
					<td><b>متن</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;
				$q3=mysql_query("select * from matnozv order by date ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<?php if ($cd3['ok_manager']==1) {?>
						<a title="حذف تایید" href="managee.php?ozvmatn=1&&ozvmatnnook=<?php echo $cd3['ip']; ?>"><img src="images/r1.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
						<?php } else {?>
						<a title="تایید مطلب" href="managee.php?ozvmatn=1&&ozvmatnok=<?php echo $cd3['ip']; ?>"><img src="images/sabtf2.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
						<?php } ?>
					</td>
					<td>
						<a href="managee.php?ozvmatn=1&&ozvmatndel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td>
						<a href="managee.php?ozvmatn=1&&ozvmatnupdate=<?php echo $cd3['ip']; ?>"><img src="images/b_edit.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $cd3['date']; ?></td>
					<td><?php echo $cd3['ozv_name'].'-'.$cd3['ozv_ip']; ?></td>
					<td><?php echo $cd3['topic']; ?></td>
					<td><?php echo $cd3['matn']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
			<?php
			}
			elseif (isset($_GET['ozvpass']))
			{
			if (isset($_GET['okidozvpass']))
			{
				$fg=mysql_query("update`ozv_passget` set id='{$_GET['okidozv']}' where ip='{$_GET['okidozvpass']}' ");
				echo"<script>window.alert('اطلاعات ذخیره شد');</script>";
			}
			if (isset($_GET['ozvmatnupdate']))
			{
				$q113=mysql_query("select * from matnozv where (ip='{$_GET['ozvmatnupdate']}') order by date ");
				$cd113=mysql_fetch_assoc($q113);
				?>
				<form method="post" action="managee.php?ozvmatn=1&&ozvmatnupdate1=<?php echo $cd113['ip']; ?>">
				<table width="60%" align="center"  border="1">
					<tr  style="font-family:tahoma;font-size:10pt;">
						<td align="right"><b>
							ویرایش مطلب ارسالی:
						</td>
					</tr>
					<tr  align="center" style="font-family:tahoma;font-size:10pt;">
						<td align="center">
							<textarea cols="110" rows="15" name="matn">
							<?php
							echo $cd113['matn'];
							?>
							</textarea>
						</td>
					</tr>
					<tr  align="center" style="font-family:tahoma;font-size:10pt;">
						<td align="center">
							<button  tabindex="11" name="okhom11" title="ذخیره اطلاعات"  type="submit" ><img src="images/b_edit.png"  name="Add"  border="0" width="25" height="25" ></button>
						</td>
					</tr>
				</table>
				</form>
				<?php
			}
			if (isset($_GET['editpass']))
			{
				$q311=mysql_query("select * from ozv_passget  where ip='{$_GET['ozvnewpass']}' order by ip ");
				$cd311=mysql_fetch_assoc($q311);
				if ($cd311['id']>0)
				{
					$fg=mysql_query("update`ozv` set pass='{$cd311['pass']}' where id='{$cd311['id']}' ");
					$fg=mysql_query("delete from `ozv_passget` where ip='{$_GET['ozvnewpass']}' ");
					echo"<script>window.alert('رمز جدید ذخیره شد');</script>";
				}
			}
			if (isset($_GET['ozvpassdel']))
			{
				$fg=mysql_query("delete from `ozv_passget` where ip='{$_GET['ozvpassdel']}' ");
				echo"<script>window.alert('فیلد مورد نظر حذف شد');</script>";
			}
			if (isset($_GET['ozvnewpass']) and !isset($_GET['editpass']))
			{
				$q21=mysql_query("select * from ozv order by id  DESC  ");
				$cd21=mysql_fetch_assoc($q21);

				$idd=$cd21['id']+1;

				$q222=mysql_query("select * from ozv  order by id ");
				$cd222=mysql_fetch_assoc($q222);

				$q3=mysql_query("select * from ozv_passget  where ip='{$_GET['ozvnewpass']}' order by ip ");
				$cd3=mysql_fetch_assoc($q3);

				mysql_query(" insert into `ozv` (id,fname,lname,faname,jen,bearthdate,sh_t,code_melli,onvan,date,date_e,pass,user,city)
				VALUES ('{$idd}','{$cd3['fname']}','{$cd3['lname']}','{$cd3['faname']}','{$cd3['jen']}','{$cd3['bearthdate']}','{$cd3['sh_t']}'
				,'{$cd3['code_melli']}','عضو','{$cd3['date']}','{$cd222['date_e']}','{$cd3['pass']}','novin','{$cd222['city']}')");

				$fg=mysql_query("delete from `ozv_passget` where ip='{$_GET['ozvnewpass']}' ");

				echo"<script>window.alert('عضویت جدید صادر شد');</script>";
			}

			?>
			<table width="80%" border="1">لیست درخواست عضویت / رمز
				<tr align="center" style="font-family:tahoma;font-size:10pt;color:black" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
					<td colspan="2" align="center">تایید</td>
					<td>حذف</td>
					<td><b>ردیف</td>
					<td><b>نوع</td>
					<td><b>تاریخ</td>
					<td><b>کد عضویت</td>
					<td><b>نام و نام خانوادگی</td>
					<td><b>نام پدر</td>
					<td><b>جنسیت</td>
					<td><b>شماره تماس</td>
					<td><b>کد ملی</td>
					<td><b>پسورد</td>
				</tr>
				<?php
				$color=array("#FFFFFF","#CCCCCC"); $a=0;
				$rad=1;

				$q3=mysql_query("select * from ozv_passget order by ip ");
				while($cd3=mysql_fetch_assoc($q3))
				{
				$andd='';
				$kiiind='';
				$picc=0;
				if ($cd3['kind']==1)
				{
					$kiiind='فراموشی رمز';
					if ($cd3['id']>0)
					{
					$tittle="تایید";
					$picc='b_edit.png';
					}
					else
					{
					$tittle="جستجوی شماره عضویت";
					$picc='12.png';
					}
					$andd="&editpass=1";
				}
				elseif ($cd3['kind']==2)
				{
					$kiiind='درخواست عضویت';
					$picc='sabtf2.png';
					$tittle="تایید";
				}
				?>
				<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
					<td>
						<a title="ارسال SMS" href="smstahvil.php?idmem1=<?php echo $cd3['ip']; ?>&&kind=2&&smsmatn=2&&pageback=managee.php?ozvpass=<?php echo $_GET['ozvpass']; ?>"><img src="images/sms.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td>
						<a title="<?php echo $tittle; ?>" href="managee.php?ozvpass=1&&ozvnewpass=<?php echo $cd3['ip'].$andd; ?>"><img src="images/<?php echo $picc; ?>"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td>
						<a  title="حذف" href="managee.php?ozvpass=1&&ozvpassdel=<?php echo $cd3['ip']; ?>"><img src="images/b_drop.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
					</td>
					<td><?php echo $rad; ?></td>
					<td><?php echo $kiiind; ?></td>
					<td><?php echo $cd3['date']; ?></td>
					<td><?php echo $cd3['id']; ?></td>
					<td><?php echo $cd3['fname'].'-'.$cd3['lname']; ?></td>
					<td><?php echo $cd3['faname']; ?></td>
					<td><?php echo $cd3['jen']; ?></td>
					<td><?php echo $cd3['sh_t']; ?></td>
					<td><?php echo $cd3['code_melli']; ?></td>
					<td><?php echo $cd3['pass']; ?></td>
				</tr>
				<?php
				if($a==1) $a=0;  else $a=1;
				$rad++;
				}
				?>
			</table>
			<?php
				if (isset($_GET['editpass']) and !$cd311['id']>0)
				{
				?>
					<table width="100%" border="0" align="center">
						<tr>
							<td height="70" align="center" valign="bottom">
								لیست اعضای مشابه
							</td>
						</tr>
						<tr>
							<td align="center">
								<table width="80%" border="1">
									<tr align="center" style="font-family:tahoma;font-size:10pt;color:black" bgcolor="<?php echo $cd2['iconcolor1']; ?>#">
										<td>تایید</td>
										<td><b>ردیف</td>
										<td><b>کد عضویت</td>
										<td><b>نام و نام خانوادگی</td>
										<td><b>نام پدر</td>
										<td><b>جنسیت</td>
										<td><b>شماره تماس</td>
										<td><b>کد ملی</td>
										<td><b>پسورد</td>
									</tr>
									<?php
									$rad1=1;
									$q30=mysql_query("select * from ozv where (jen='{$cd311['jen']}' and (fname='{$cd311['fname']}' and lname='{$cd311['lname']}' and faname='{$cd311['faname']}') or (sh_t='{$cd311['sh_t']}')  or (code_melli='{$cd311['code_melli']}')) order by ip ");
									while($cd30=mysql_fetch_assoc($q30))
									{
										?>
										<tr align="center"  style="font-family:tahoma;font-size:11pt;" onmouseover="this.style.backgroundColor='#CCCCCC';" onmouseout="this.style.backgroundColor='#FFFFFF';"  bgcolor=<?php echo $color[$a]; ?>>
											<td>
												<a title="<?php echo $tittle; ?>" href="managee.php?ozvpass=1&&okidozvpass=<?php echo $_GET['ozvnewpass']; ?>&&okidozv=<?php echo $cd30['id']; ?>"><img src="images/sabtf2.png"  height="20" alt="نرم افزار کتابداری" width="20"></a>
											</td>
											<td><?php echo $rad1; ?></td>
											<td><?php echo $cd30['id']; ?></td>
											<td><?php echo $cd30['fname'].'-'.$cd30['lname']; ?></td>
											<td><?php echo $cd30['faname']; ?></td>
											<td><?php echo $cd30['jen']; ?></td>
											<td><?php echo $cd30['sh_t']; ?></td>
											<td><?php echo $cd30['code_melli']; ?></td>
											<td><?php echo $cd30['pass']; ?></td>
										</tr>
										<?php
										$rad1++;
									}
									?>
								</table>
							</td>
						</tr>
					</table>
				<?php
				}
			}
			elseif (isset($_GET['hom']))
			{
			?>
			<table width="80%" border="0">
				<tr  align="right">
					<td height="60" align="right"  >
						<table width="100%" border="1">
						<form action="" method="post">
							<tr>
								<td width="100%" colspan="2" align="right">
									<span  style="font-family:tahoma;font-size:10pt;"><b>لطفاً مطالب مربوط به صفحه اول را تایپ فرمایید:</b></span><br/><br/>
								</td>
							</tr>
							<tr>
								<td width="10%">
									<span style="font-family:tahoma;font-size:10pt;">خط اول :&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="1" size="110" name="homline1" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['homline1']; ?> ">
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط دوم :&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="2" size="110" name="homline2" style="font-family:tahoma;font-size:10pt;"  value="<?php echo $cd2['homline2']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط سوم  :&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="3" size="110" name="homline3" style="font-family:tahoma;font-size:10pt;"  value="<?php echo $cd2['homline3']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط چهارم :&nbsp;&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="4" size="110" name="homline4" style="font-family:tahoma;font-size:10pt;"  value="<?php echo $cd2['homline4']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط پنجم :&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="5" size="110" name="homline5" style="font-family:tahoma;font-size:10pt;"  value="<?php echo $cd2['homline5']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط ششم :&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="6" size="110" name="homline6" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['homline6']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط هفتم :&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="7" size="110" name="homline7" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['homline7']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط هشتم :&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="8" size="110" name="homline8" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['homline8']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط نهم :&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="9" size="110" name="homline9" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['homline9']; ?>" >
								</td>
							</tr>
							<tr>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">خط دهم :&nbsp;&nbsp;&nbsp;</span>
								</td>
								<td>
									<input type="text" tabindex="10" size="110" name="homline10" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['homline10']; ?>" >
								</td>
							</tr>
							<tr>
								<td align="center" colspan="2">
									<button  tabindex="11" name="okhom" title="ذخیره اطلاعات"  type="submit" ><img src="images/b_edit.png"  name="Add"  border="0" width="25" height="25" ></button>
								</td>
							</tr>
							</form>
						</table>
					</td>
				</tr>
			</table>
			<?php
			}
			elseif (isset($_GET['link']))
			{
			?>
			<table width="80%" border="0">
				<tr  align="right">
					<td height="60" align="right"  >
						<table width="100%" border="1" align="center">
						<form action="" method="post">
							<tr >
								<td width="100%" colspan="2" align="right">
									<span  style="font-family:tahoma;font-size:10pt;"><b>لطفاً لینک های مورد نظر را درج فرمایید</b></span><br/><br/>
								</td>
							</tr>
							<tr align="center">
								<td width="4%">
									<span style="font-family:tahoma;font-size:10pt;">1 </span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="1" size="50" name="linkname1" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname1']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="1" size="60" name="linkaddres1" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres1']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">2 </span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="2" size="50" name="linkname2" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname2']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="2" size="60" name="linkaddres2" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres2']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">3</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="3" size="50" name="linkname3" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname3']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="3" size="60" name="linkaddres3" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres3']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">4</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="4" size="50" name="linkname4" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname4']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="4" size="60" name="linkaddres4" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres4']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">5</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="5" size="50" name="linkname5" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname5']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="5" size="60" name="linkaddres5" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres5']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">6</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="6" size="50" name="linkname6" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname6']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="6" size="60" name="linkaddres6" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres6']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">7</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="7" size="50" name="linkname7" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname7']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="7" size="60" name="linkaddres7" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres7']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">8</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="8" size="50" name="linkname8" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname8']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="8" size="60" name="linkaddres8" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres8']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">9</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="9" size="50" name="linkname9" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname9']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="9" size="60" name="linkaddres9" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres9']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td>
									<span style="font-family:tahoma;font-size:10pt;">10</span>
								</td>
								<td>
									<span style="font-family:tahoma;font-size:10pt;">نام لینک :</span>
									<input type="text" tabindex="10" size="50" name="linkname10" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkname10']; ?> ">
									&nbsp;&nbsp;&nbsp;
									<span style="font-family:tahoma;font-size:10pt;">آدرس لینک :</span>
									<input type="text" tabindex="10" size="60" name="linkaddres10" style="font-family:tahoma;font-size:10pt;" value="<?php echo $cd2['linkaddres10']; ?> ">
								</td>
							</tr>
							<tr align="center">
								<td align="center" colspan="2">
									<button  tabindex="11" name="oklink" title="ذخیره اطلاعات"  type="submit" ><img src="images/b_edit.png"  name="Add"  border="0" width="25" height="25" ></button>
								</td>
							</tr>
							</form>
						</table>
					</td>
				</tr>
			</table>
			<?php
			}
			elseif (isset($_GET['action']))
			{
			?>
			<table align="center" border="1" width="40%">
				<tr align="center" style="font-family:tahoma;font-size:10pt;" bgcolor="#FFFFFF">
					<td valign="middle" width="8%">ویرایش</td>
					<td valign="middle" width="8%"><b>ردیف</td>
					<td valign="middle"><b>نام فعالیت</td>
				</tr>
				<tr align="center" style="font-family:tahoma;font-size:10pt;" bgcolor="#FFFFFF">
					<td valign="middle" width="8%">
						<a href="managee.php?action=1&&ip=1"  title="ویرایش"><img src="images/b_edit.png"	 height="15" width="15" border="0"></a>
					</td>
					<td valign="middle" width="8%">1</td>
					<td valign="middle"><?php echo $cd2['action1']; ?></td>
				</tr>
				<tr align="center" style="font-family:tahoma;font-size:10pt;" bgcolor="#FFFFFF">
					<td valign="middle" width="8%">
						<a href="managee.php?action=1&&ip=2"  title="ویرایش"><img src="images/b_edit.png"	 height="15" width="15" border="0"></a>
					</td>
					<td valign="middle" width="8%">2</td>
					<td valign="middle"><?php echo $cd2['action2']; ?></td>
				</tr>
				<tr align="center" style="font-family:tahoma;font-size:10pt;" bgcolor="#FFFFFF">
					<td valign="middle" width="8%">
						<a href="managee.php?action=1&&ip=3"  title="ویرایش"><img src="images/b_edit.png"	 height="15" width="15" border="0"></a>
					</td>
					<td valign="middle" width="8%">3</td>
					<td valign="middle"><?php echo $cd2['action3']; ?></td>
				</tr>
				<tr align="center" style="font-family:tahoma;font-size:10pt;" bgcolor="#FFFFFF">
					<td valign="middle" width="8%">
						<a href="managee.php?action=1&&ip=4"  title="ویرایش"><img src="images/b_edit.png"	 height="15" width="15" border="0"></a>
					</td>
					<td valign="middle" width="8%">4</td>
					<td valign="middle"><?php echo $cd2['action4']; ?></td>
				</tr>
				<tr align="center" style="font-family:tahoma;font-size:10pt;" bgcolor="#FFFFFF">
					<td valign="middle" width="8%">
						<a href="managee.php?action=1&&ip=5"  title="ویرایش"><img src="images/b_edit.png"	 height="15" width="15" border="0"></a>
					</td>
					<td valign="middle" width="8%">5</td>
					<td valign="middle"><?php echo $cd2['action5']; ?></td>
				</tr>
			</table>
			<?php
			if (isset($_GET['ip']))
			{
			if ($_GET['ip']==1)	{ $actionname=$cd2['action1']; }
			if ($_GET['ip']==2)	{ $actionname=$cd2['action2']; }
			if ($_GET['ip']==3)	{ $actionname=$cd2['action3']; }
			if ($_GET['ip']==4)	{ $actionname=$cd2['action4']; }
			if ($_GET['ip']==5)	{ $actionname=$cd2['action5']; }
			?>
			<br/><br/><br/>
			<form name="aa" action="" method="post"  enctype="multipart/form-data">
			<input name="ip" type="hidden" value="<?php  echo $_GET['ip']; ?>">
			<table align="center" border="1" width="30%">
				<tr align="right" style="font-family:tahoma;font-size:10pt;" bgcolor="#FFFFFF">
					<td colspan="2" valign="middle" >ویرایش اطلاعات:</td>
				</tr>
				<tr align="center" style="font-family:tahoma;font-size:10pt;">
					<td valign="middle" width="20%"><b>نام فعالیت</td>
					<td><input name="action" type="text" size="40" value="<?php echo $actionname; ?>"></td>
				</tr>
				<tr align="center" style="font-family:tahoma;font-size:10pt;">
					<td valign="middle" width="20%"><b>انتخاب تصویر</td>
					<td><input name="up1" type="file" id="up1" ></td>
				</tr>
				<tr>
					<td align="center" colspan="3" style="font-family:tahoma;font-size:10pt;">
						<button type="submit" tabindex="1" name="sabtact" value="ثبت" title="ثبت"><img src="images/b_edit.png" height="20" width="20"></button>
					</td>
				</tr>
			</table>
			</form>
			<?php
			}
			}
			?>
		</td>
	</tr>
<?php
}
else
{
include ('index1.php');
}
?>
</table>
</body>
</html>