<?php
session_start();		 
include "connect.php";
	$cmpmid=$_SESSION['linkarisecmpmid'];
	if (isset($_REQUEST['id'])) {
			
		$id = intval($_REQUEST['id']);
	}
		$eve1 = "select * from res_party_master where partymid=$id";
				$re1 = mysqli_query($conn, $eve1);
				while($rt1 = mysqli_fetch_assoc($re1))
				{
					
					$ipname=$rt1['partystage'];
					$_SESSION['stage']=$ipname;
				}
?>
			
		
		<input type="hidden" name="partymid" value="<?php echo $id;?>">
		
			
								<div class="fv-row mb-7">
													<!--begin::Label-->
													<label class="fs-6 fw-semibold form-label mt-3">
														<span class="required">Inquiry Stage</span>
														
													</label>
									
											<select class="form-select form-select-solid " data-control="select2"   name="istage" id="isname" >
											<?php
											$eve_category1 = "select * from res_inquirystage_master where cmpmid=$cmpmid";
										$re_category1 = mysqli_query($conn, $eve_category1);
												while($rt_category1 = mysqli_fetch_assoc($re_category1))
												{
													if($rt_category1['inquirystagename']==$_SESSION['stage']){
													echo "<option value='$rt_category1[inquirystagename]' selected>$rt_category1[inquirystagename]</option>";
													}
													else{
														echo "<option value='$rt_category1[inquirystagename]'>$rt_category1[inquirystagename]</option>";
													}
												}
											?>
											</select>
										</div>
		
			
	
	