use php variable in wordpress page

As said by sabbir you have to create a custom template to use php code, other way is to register a shortcode and the use that shortcode on new page. creating shortcode is much easier, you can paste the code below in functions.php and then use [new_form] shortcode on your page. You can modify the code as per your needs…

function form_shortcode() 
    {   
        if (is_user_logged_in()) {
            $current_user = wp_get_current_user ();
            $logado1 = $current_user->user_email;  
            ob_start();         
        ?>
            <div class = "divsearch">
                <form action=" http://localhost/newphp.php" method="post">
                    <label class = "textout"> <b> Port 1 </b> </label>
                    <input type = "text" class = "box1">
                    <label class = "textout"> <b> Port 2 </b> </label>
                    <input type = "text" class = "box1">
                    <input type="hidden" name="user-email" id="user-email" value="<?php echo $logged1 ?>">;
                </form>
                <button type = "submit" class = "buttonacept1"> Save </button>
            </div>
        <?php                               
        }
        $content=ob_get_clean();
        return $content;
    }
    add_shortcode('new_form', 'form_shortcode');