How to pass email values from one php page to another

first.php:

<?php
session_start();
$_SESSION['wdm_email'] = '[email protected]';
?>

second.php:

<?php
session_start();
echo 'Hi ' . $_SESSION['wdm_email'];
?>

When you will run second.php(after first.php), output would be:

Hi [email protected]

Do not forget to start the session at the top of the pages.

For more references: How to use session?