Documentation

Mail.php

Table of Contents

Functions

bb_send_mail_template()  : bool
Sends a Mail using the configured Mailer and a template in the current theme
bb_send_mail()  : bool
Sends a Mail using the configured Mailer
bb_register_maildriver()  : void
Registers a Mail Driver
bb_get_maildriver()  : null|IMailDriver
Gets the Mail Driver
bb_register_dbdriver()  : void
Registers a Database Driver
bb_get_dbdriver()  : null|IDatabaseDriver
Gets a Database Driver registered to the type

Functions

bb_send_mail_template()

Sends a Mail using the configured Mailer and a template in the current theme

bb_send_mail_template(string|array<string|int, mixed> $to, string $subject, string $template, array<string|int, mixed> $vars, null|array<string|int, mixed> $attachments[, null|string $from = null ][, null|string $from_name = null ][, bool $isBodyHtml = true ][, string $charset = "UTF-8" ]) : bool
Parameters
$to : string|array<string|int, mixed>

Recipients as array or string (mail1;mail2 or mail1,mail2 or mail1 mail2)

$subject : string

The Mails subject

$template : string

Mail Template name

$vars : array<string|int, mixed>

Vars for the Mail Template

$attachments : null|array<string|int, mixed>

Attachment Files or null

$from : null|string = null

Overwrite the From Mail

$from_name : null|string = null

Overwrite the From Name

$isBodyHtml : bool = true

Is the Body Html

$charset : string = "UTF-8"

Charset for the Body

Return values
bool

True if sent successful or false if failed

bb_send_mail()

Sends a Mail using the configured Mailer

bb_send_mail(string|array<string|int, mixed> $to, string $subject, string $body, null|array<string|int, mixed> $attachments[, null|string $from = null ][, null|string $from_name = null ][, bool $isBodyHtml = true ][, string $charset = "UTF-8" ]) : bool
Parameters
$to : string|array<string|int, mixed>

Recipients as array or string (mail1;mail2 or mail1,mail2 or mail1 mail2)

$subject : string

The Mails subject

$body : string

The Body (HTML or Plain text)

$attachments : null|array<string|int, mixed>

Attachment Files or null

$from : null|string = null

Overwrite the From Mail

$from_name : null|string = null

Overwrite the From Name

$isBodyHtml : bool = true

Is the Body Html

$charset : string = "UTF-8"

Charset for the Body

Return values
bool

True if sent successful or false if failed

bb_register_maildriver()

Registers a Mail Driver

bb_register_maildriver(mixed $type, IMailDriver $driver) : void
Parameters
$type : mixed

Type for configuration

$driver : IMailDriver

Mail Driver Instance

bb_get_maildriver()

Gets the Mail Driver

bb_get_maildriver(mixed $type) : null|IMailDriver
Parameters
$type : mixed

Type for configuration

Return values
null|IMailDriver

null if no driver is registered to this name

bb_register_dbdriver()

Registers a Database Driver

bb_register_dbdriver(mixed $type, IDatabaseDriver $driver) : void
Parameters
$type : mixed

Type for configuration

$driver : IDatabaseDriver

DB Driver Instance

bb_get_dbdriver()

Gets a Database Driver registered to the type

bb_get_dbdriver(mixed $type) : null|IDatabaseDriver
Parameters
$type : mixed

Database Type

Return values
null|IDatabaseDriver

        
On this page

Search results