<?php if(basename($_SERVER["SCRIPT_FILENAME"]) == 'index.php'){ ?>
<p>test</p>
<?php } ?>