__construct()
public function __construct(?string $filename = null)
Description
Constructor for the Image module. Blocks direct URL access and checks for the GD extension. If a filename is provided, loads the image for immediate processing.
Note: The framework automatically instantiates Image via $this->image. You rarely need to call this constructor manually.
Parameters
| Parameter | Type | Description | Default | Required |
|---|---|---|---|---|
| filename | string|null | Path to an image file to load immediately. If null, no image is loaded. | null | No |
Return Value
| Type | Description |
|---|---|
| void | Constructor does not return a value. |