Skip to content

Commit 7bccc1c

Browse files
committed
Simplify quickstart example, note autoload for non-framework users
1 parent 088fb24 commit 7bccc1c

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,14 @@ composer require stechstudio/phpinfo
2222
The simplest way to use this package is the global `prettyphpinfo()` function — a drop-in replacement for `phpinfo()`:
2323

2424
```php
25-
<?php
26-
require __DIR__ . '/../vendor/autoload.php';
27-
2825
prettyphpinfo();
2926
```
3027

3128
That's it. You'll get a pretty, searchable, dark-mode-ready page instead of the default `phpinfo()` output.
3229

33-
<img width="1506" height="990" alt="phpinfo-screenshot" src="https://github.com/user-attachments/assets/7737f2f9-da88-4465-8b25-130af7e3908d" />
30+
> If you're not using a framework with Composer autoloading, you'll need to add `require __DIR__ . '/vendor/autoload.php';` first.
3431
32+
<img width="1506" height="990" alt="phpinfo-screenshot" src="https://github.com/user-attachments/assets/7737f2f9-da88-4465-8b25-130af7e3908d" />
3533

3634

3735
Just like the native `phpinfo()`, you can pass `INFO_*` constants to control which sections are displayed:

0 commit comments

Comments
 (0)