Skip to content

Commit

Permalink
Adds trouble shooting section in documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
hollodotme committed Jun 13, 2017
1 parent 2d42a80 commit 339ef21
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -613,6 +613,33 @@ echo $response->getDuration(); # e.g. 0.0016319751739502

---

## Trouble shooting

### "File not found." response

If you're facing a `File not found.` response after issuing a request to PHP-FPM, please make sure
the given path to the script you want to call is an absolute path / realpath.

### Doesn't work

```php
<?php

$request = new PostRequest( __DIR__ . '/../../run/script.php', $content );
$request = new PostRequest( '/var/www/example.com/../../run/script.php', $content );
```

### Does work

```php
<?php

$request = new PostRequest( dirname(__DIR__, 2). '/run/script.php', $content );
$request = new PostRequest( '/var/run/script.php', $content );
```

---

## Run examples

php bin/examples.php
Expand Down

0 comments on commit 339ef21

Please sign in to comment.