Skip to content

Commit 113b4a0

Browse files
committed
Add imagesBlacklist options on README
1 parent 8d73f57 commit 113b4a0

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

README.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ The available options for the adapters are:
7474

7575
* minImageWidth (int): Minimal image width used to choose the main image
7676
* minImageHeight (int): Minimal image height used to choose the main image
77+
* imagesBlacklist (array): Images that you don't want to be used. Could be plain text or [Url](https://github.com/oscarotero/Embed/blob/master/src/Url.php) match pattern.
7778
* getBiggerImage (bool): Choose the bigger image as the main image (instead the first found, that usually is the most relevant).
7879
* getBiggerIcon (bool): The same than getBiggerImage but used to choose the main icon
7980
* facebookKey (string): Used only in Facebook adapter, to get info from facebook pages when these pages are not public and a access token is required
@@ -87,6 +88,7 @@ $config = [
8788
'config' => [
8889
'minImageWidth' => 16,
8990
'minImageHeight' => 16,
91+
'imagesBlacklist' => null,
9092
'getBiggerImage' => false,
9193
'getBiggerIcon' => false,
9294
'facebookKey' => null,
@@ -191,6 +193,11 @@ $config = [
191193
'config' => [
192194
'minImageWidth' => 16,
193195
'minImageHeight' => 16,
196+
'imagesBlacklist' => [
197+
'http://example.com/full/path/to/image.jpg',
198+
'http?://test.*/*.png/',
199+
'*/bad_image.gif'
200+
]
194201
]
195202
],
196203
'providers' => [

0 commit comments

Comments
 (0)