Maintain state with sessions http://www.php.net/manual/en/ref.session.php or have two.php be a popup opened by one.php and use javascript's window.opener to alter the content of one.php, but that can be a real pain.