<?php

	include "library.php";

		
		// required for session_start();
		
	$cxn = start_code( true );

//	$cxn_common = db_common_login();
	
	$search_id = val( $_POST, "search_id" );
	
	$query = "SELECT id FROM financial_planning_practices WHERE id = ".$search_id;
	
	if (query_has_rows( $query, $cxn ))
	{
    	$_SESSION['id'] = $search_id;
    	
    	$nextpage = url_encode( "edit_fp_practice.php", "newrecord", "false" );
    		
    	header( "Location: ".$nextpage );
	}
	else
	{   
	    echo "<br>ID not found.<br><br>";
	    
	    echo show_home_link();
	}

?>
	