Skip to content

Commit 47866b3

Browse files
committed
[docs]: Updating readme to include basePath
1 parent 0b2d41f commit 47866b3

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,11 @@ Only mime types defined in the `mime_types` array in the `config/multiSizeImage.
6161
The default behavior is to create the resized image versions in the same path as the original's. To send the images to a different location you can provide the output path as a second optional parameter.
6262

6363
```php
64-
$multiSizeImage->processImage($filePath, $outputPath);
64+
$multiSizeImage->processImage($filePath, $outputPath, $basePath);
6565
```
6666

67+
The `basePath` optional parameter can be used to keep the original file path as of the basePath.
68+
6769
**2.3. Resizing**
6870

6971
The resizable values are defined by the `sizes` array in the `config/multiSizeImage.php` file. This array has the keys as the size identification and the value as the size for the image be resized to.
@@ -99,10 +101,10 @@ If the image width and height are lower than the specified resize value, the ima
99101

100102
If you want to keep the original's file name instead of using a auto-generated one, set `keep_original_name` to `true` in the `config/multiSizeImage.php` file.
101103

102-
You can also provide a optional custom name as a third parameter to the `processImage` method.
104+
You can also provide a optional custom name as a forth parameter to the `processImage` method.
103105

104106
```php
105-
$multiSizeImage->processImage($filePath, $outputPath, $fileName);
107+
$multiSizeImage->processImage($filePath, $outputPath, $basePath, $fileName);
106108
```
107109

108110
**2.5. Optimizing**

0 commit comments

Comments
 (0)