[PHP] Define a string with heredoc syntax

Created on November 30, 2026

Use heredoc syntax to assign a multiline string. In this example, TEXT is the delimiter and the text between the opening and closing markers is assigned to $str.

<?php

$str = <<< TEXT
Hello World.
Good Bye.
TEXT;
PHP