File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -658,16 +658,18 @@ images inside the HTML contents::
658
658
->html('... <div background="cid:footer-signature"> ... </div> ...')
659
659
;
660
660
661
+ The actual Content-ID value present in the e-mail source will be randomly generated by Symfony.
662
+
661
663
You can also use the :method: `DataPart::setContentId() <Symfony\\ Component\\ Mime\\ Part\\ DataPart::setContentId> `
662
664
method to define a custom Content-ID for the image and use it as its ``cid `` reference::
663
665
664
666
$part = new DataPart(new File('/path/to/images/signature.gif'));
665
- $part->setContentId('footer-signature');
667
+ $part->setContentId('footer-signature@my-app ');
666
668
667
669
$email = (new Email())
668
670
// ...
669
671
->addPart($part->asInline())
670
- ->html('... <img src="cid:footer-signature"> ...')
672
+ ->html('... <img src="cid:footer-signature@my-app "> ...')
671
673
;
672
674
673
675
.. versionadded :: 6.1
You can’t perform that action at this time.
0 commit comments