How do I edit the template files for GLOBAL PHP? I have a global php field in a view and it has a output field. However, I want to add / edit the template file instead which looks like this: 

&lt;?php

/**
 * @file
 * This template is used to print a single field in a view.
 *
 * It is not actually used in default Views, as this is registered as a theme
 * function which has better performance. For single overrides, the template is
 * perfectly okay.
 *
 * Variables available:
 * - $view: The view object
 * - $field: The field handler object that can process the input
 * - $row: The raw SQL result that can be used
 * - $output: The processed output that will normally be used.
 *
 * When fetching output from the $row, this construct should be used:
 * $data = $row-&gt;{$field-&gt;field_alias}
 *
 * The above will guarantee that you'll always get the correct data,
 * regardless of any changes in the aliasing that might happen if
 * the view is modified.
 */
?&gt;


&lt;?php print $output; ?&gt;


However, when I put anything here, like for example: echo "hello world"; nothing gets displayed. 

If I put this php code in the output field on the view, it works just fine, but I am tasked with removing php from fields and putting them in either modules or template files so they do not risk exposure. 

How come my template file will not display whatever php code I insert, but it will on the field itself? I'm confused.
1) Remove Global PHP field from the view

2) Add a new field of type "Global: Custom text"

3) Click on Theme: Information. You will be able to see the suggestion for template file

4)Create the template file with the required name.

5)Invoke the function which was being invoked from your Global: PHP field.