---
title: "Displaying PHP information"
canonical_url: "https://www.zone.lv/help/kb/displaying-php-information/"
post_type: "ht_kb"
published: "2024-04-17T06:20:27+00:00"
modified: "2024-04-19T07:40:22+00:00"
language: "en"
author: "Hasso"
taxonomies:
  ht_kb_category:
    - name: "PHP"
      url: "https://www.zone.lv/help/kb-categories/php-en/"
  ht_kb_tag:
    - name: "info"
      url: "https://www.zone.lv/help/kb-tags/info/"
    - name: "information"
      url: "https://www.zone.lv/help/kb-tags/information/"
    - name: "php"
      url: "https://www.zone.lv/help/kb-tags/php-eng/"
    - name: "php info"
      url: "https://www.zone.lv/help/kb-tags/php-info/"
    - name: "php information"
      url: "https://www.zone.lv/help/kb-tags/php-information/"
---

# Displaying PHP information

Information about PHP and its settings can be viewed by using the [phpinfo()](https://www.php.net/manual/en/function.phpinfo.php) function in one of your scripts. As an example, you could create an empty **.php** file (with an arbitrary name\*) in the `htdocs/` directory with the following contents:

```
<?php

phpinfo();

?>
```

\* For security reasons, it is not recommended to use phpinfo, info, etc. as filenames.
