Download the PHP package oliverkroener/ok-typo3-helper without Composer
On this page you can find all versions of the php package oliverkroener/ok-typo3-helper. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download oliverkroener/ok-typo3-helper
More information about oliverkroener/ok-typo3-helper
Files in oliverkroener/ok-typo3-helper
Package ok-typo3-helper
Short Description A TYPO3 extension with helper traits and utilities.
License GPL-2.0-or-later
Homepage https://www.oliver-kroener.de
Informations about the package ok-typo3-helper
TYPO3 Helpers (ok_typo3_helper)
Reusable helper traits, services, and a Microsoft Graph mail converter that other Oliver Kröner TYPO3 extensions build on.
Features
- Microsoft Graph mail converter (
MSGraphMailApiService) — converts a SymfonySentMessageinto a Microsoft GraphMessageobject ready for the GraphsendMailendpoint. It maps From/To/Cc/Bcc/Reply-To recipients, HTML and plain-text bodies, and file attachments. This is the conversion layer used byok_exchange365_mailer.- Inline images (
cid:) support — attachments markedContent-Disposition: inlineare flagged as inline and their original MIMEContent-IDis carried onto the GraphFileAttachment. Without this, Graph cannot bind an<img src="cid:…">in the HTML body to its attachment and the image renders broken. The Content-ID is read viagetContentId(), which already returns the value without the surrounding<>so it matches thecid:reference in the body verbatim.
- Inline images (
- Site root resolver (
SiteRootService) — a singleton service that returns the site root page UID for any given page UID, resolvingSiteNotFoundExceptiontonull. - Reflection accessor trait (
ReflectionPropertiesTrait) — adds dynamicgetXxx()/setXxx()access to any class's properties (including protected/private) via__call()and reflection.
Requirements
- TYPO3 12.4 LTS, 13.4 LTS, or 14 LTS
- PHP 8.1 or newer
microsoft/microsoft-graph^2(pulled in automatically)zbateson/mail-mime-parser^3(pulled in automatically)
Installation
Install via Composer:
As a local path-repository extension (as used in this project), add the package under packages/ and require it as a dev version:
Then set it up:
Usage
Converting a message for Microsoft Graph
MSGraphMailApiService::convertToGraphMessage() is static and takes a Symfony SentMessage, returning an array with the built Graph message and the resolved from address:
Inline images work automatically: build the mail with Symfony's ->embed() (or a TYPO3 Fluid mail template with an inline image), and the resulting cid: reference in the HTML body is preserved end-to-end into the Graph attachment's contentId.
Resolving the site root
Dynamic property accessors
Architecture
| Component | Class | Role |
|---|---|---|
| Graph mail converter | OliverKroener\Helpers\MSGraphApi\MSGraphMailApiService |
Parses a MIME SentMessage and rebuilds it as a Graph Message |
| Site root resolver | OliverKroener\Helpers\Service\SiteRootService |
Maps a page UID to its site root page UID (singleton, DI-registered) |
| Reflection trait | OliverKroener\Helpers\Traits\ReflectionPropertiesTrait |
Dynamic getters/setters via __call() + reflection |
License
This extension is licensed under the GPL-2.0-or-later. See the LICENSE file for the full text.
Author — Oliver Kroener
Automated. Scaled. Done.
Web3 · Cloud · Automation
Technology is only valuable when it solves a real problem. For over 30 years I've been translating between business and tech — so your investment in digitalisation doesn't stall at proof-of-concept but delivers measurable results.
- Website: oliver-kroener.de
- Web3: web3.oliver-kroener.de
- Email: [email protected]
- Web3 Email: [email protected]
All versions of ok-typo3-helper with dependencies
microsoft/microsoft-graph Version ^2
zbateson/mail-mime-parser Version ^3