<?php

	include "library.php";

	$cxn = start_code();

	$cxn_common = db_common_login();


	
			/* get variables */

	$id = val( $_SESSION, "id" );

	$block_id = val( $_GET, "blockid" );


		/* if the user is not logged in them direct them to the login page then back to here */

	if ($id == "")
	{
		$_SESSION['nextpage'] = url_encode( "block.php", "blockid", $block_id );

	    jump_to_page( val( $_SESSION, "login_page" ) );		/* must happen before print output */

		exit();
	}

	page_header( "", $cxn, $cxn_common );

		/* check parameters */

	crash_if_missing( $id, "id not set in 'block'", $cxn );

	crash_if_missing( $block_id, "block id not set in block", $cxn );


		/* prompt the user */

	echo red( "<br>Are you sure you want to block contact with this member?<br><br><br>" );


		/* yes */

	echo sp(2);

//	show_button_h( "yes", "block_go.php", "block", "yes", "blockid", $block_id );

	show_green_button( "Yes", 70, "block_go.php", "block", "yes", "blockid", $block_id );


		/* no */

	echo sp(2);

//	show_button_h( "no", "block_go.php", "block", "no", "blockid", $block_id );

	show_green_button( "No", 70, "block_go.php", "block", "no", "blockid", $block_id );

?>