<?php

include("session_start.php");

include("session_check.php");include("database.php");

extract($_GET);

	if($_POST['submit']!="")

	{

		

		//for($i=1;$i<=3;$i++)

		//{

		 //$x=$_POST["tree_name"."$i"];

		extract($_POST);

		$query1 =mysql_fetch_array( mysql_query("select count(*) as num from master_scientific_name where svalue='$scientific_name1' "));

		if($query1['num']==0)

		//if($x!="")

		{

		$query=mysql_query("insert into master_scientific_name(svalue)values('$scientific_name1')");

		}

		//}

		if($query)

		{

		?>

		<script language="javascript" type="text/javascript">

		alert("Inserted Successfully");

		window.location="master_scientific.php";

		</script>

		<?php

		}

		else

		{

			?>

		<script language="javascript" type="text/javascript">

		alert("Please Do Not Enter Duplicate Values");

		window.location="master_scientific_insert.php";

		</script>

		<?php

		}

		

		}

		?>





<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>Survey Application</title>

<link rel="stylesheet" type="text/css" href="css/style.css" />

<link rel="stylesheet" type="text/css" href="css/page.css">

<script src="js/menuscript.js" language="javascript" type="text/javascript"></script>

<link rel="stylesheet" type="text/css" href="css/menustyle.css" media="screen, print" />

<link href="css/admincss.css" rel="stylesheet" type="text/css">



<script type="text/javascript">

function showcomponent(id1)

{

	document.getElementById(id1).style.display="block";

}

</script>

<script type="text/javascript">

function validate(){

 if((document.master_scientific.scientific_name1.value) == "")

 {

	 	alert("Fill Up Empty Fields");

		document.master_scientific.scientific_name1.focus();

		return false;



 }

 return true;

}

</script>

</head>



<body class="body">



<div id="wrap" >

  

  

  <div id="top">

    <?php include("header.php"); ?>

    <!--<div id="ban"><table width="1004" align="left"  >

  <tr>

    <td width="234"  align="left"  valign="top" ><img src="images/logoss.jpg" border="0" /></td>

    <td  valign="top" style="padding-top:5px;" width="758"  align="right" ><table align="left" width="707">

  <tr>

    <td width="386" align="left"><div ><a href="#" id="bantext1">REQUEST A DEMO</a></div></td>

    <td width="167" align="left"><div ><a href="#" id="bantext2">DOWNLOADS</a></div></td>

    <td width="138" align="left"><div ><a href="#" id="bantext2">DOWNLOADS</a></div></td>

  </tr>

  <tr>

    <td colspan="3" align="center" class="banquot">Be Smart and Survey Smartly </td>

  </tr>

</table></td>

    

    

  </tr>

</table>

    </div>-->

    

    </div>

    </div>

   <div id="menuholder"><?php include("adminmenu.php"); ?></div>

   <div id="contholder">

   

    

    <!--<div id="nav">

     <ul>

     <li><a href="adminhome.php" id="home_on">HOME</a></li>

        <li><a href="adminproducts.php" id="products_on">PRODUCTS</a></li>

		<li><a href="adminfeatures.php" id="features_on">FEATURES</a></li>

        <li><a href="adminadvantages.php" id="advantages_on">ADVANTAGES</a></li>

        <li><a href="adminhowitworks.php" id="howitworks_on">HOW IT WORKS</a></li>

        <li><a href="adminhelp.php" id="help_on">HELP</a></li>

        <li><a href="admincontactus.php" id="contactus_on">CONTACT US</a></li>

    

    </ul>

    

    </div>-->

    

    

    	<div id="contdata">

    <?php //include("header.php"); ?><br />

<form name="master_scientific" method="post" action="">

<table border="1" align="center" width="60%"  bordercolor="#2a4a73">

		<tr>

			<td bgcolor="#a9c1de" class="f"> View Master Scientific Tree Details </td>

		</tr>

        <tr>

        	<td>

            	<table width="100%">

                <tr>

                	<td> <br /></td>

                </tr>

                <tr>

        			<td>

						<table border="1" cellpadding="2" cellspacing="2" width="80%" align="center" bordercolor="#bcd5e7" bgcolor="#f4f8fb





">

						<tr>

    						<td colspan="3" align="center" ><font class="font4"><b>Insert Scientific Tree Name</b> </font></td>

  						</tr>

						<tr>

							<td>

                                <table  class="margin1" border="0">

                                    <tr>

                                        <td align="center"><font class="font4"><b>Enter scientific tree name</b> </font> </td>

                                        <td><input type="text" name="scientific_name1" id="scientific_name1" />

                                

                                    </tr>

                                    

                                </table>

                            </td>

        				</tr>

    					

						</table>

            		</td>

				</tr>

                

        		</table>

            </td>

        </tr>

		

	</table>

    <br />

    <table border="1"  align="center" width="60%"  bordercolor="#2a4a73">

    	<tr>

			<td bgcolor="#a9c1de" class="f"align="right"><input type="submit"  name="submit" id="submit" value="Submit" onClick="return validate(); " style="text-decoration:none" class="button_c"> <input type="reset" name="reset" id="reset" value="Cancel" style="text-decoration:none" class="button_c"></td>

            

		</tr>

    </table>

</form>

<?php include("footer.php"); ?>

		</div>

    

   

    



    	

   </div> 



<!--<div id="footer">Copyright © 2012.Smart Survey All Rights Reserved.Website Designed & Developed by Kalpak Solutions</div>-->











</body>

</html>