Here’s a sample of php file and document
php file is file with .php (dot php) extension
see the php file in the image below

we’ve created a php file called testing.php
php document is a document that consist most importantly of php open tag <?php
and sometimes including the php close tag ?>
when needful to escape html tags.
below is an example of php document structure
<?php echo 'an output'; //.... logic & statements goes ?>