Ir al contenido principal

sendmailSpawnHandler

Callable


  • Creates a sendmail-compatible null transport for the given PHP instance. Every message handed to sendmail – via mail(), proc_open(), etc. – is streamed from stdin, dispatched as a sendmail.spawned event, and never delivered. A listener that wants real delivery must relay the message itself.

    The captured payload is exposed as the raw bytes written to sendmail stdin.

    This stream does not apply backpressure to PHP. Each listener queues unread chunks in JavaScript memory when it reads more slowly than PHP writes. The source accepts at most SENDMAIL_CAPTURE_MAX_SIZE bytes. Cancelling the stream stops delivery through that stream without terminating the sendmail process.


    Parameters

    Returns any