I am trying to insert a footnote in my generated document with phpword. Assume this:
$phpWord = new \PhpOffice\PhpWord\PhpWord();
$content= "Line\r\nAnother Line\r\nYet another [and my footnote] line\r\nfinal line";
$section = $phpWord->addSection();
$textlines = preg_split("/(\r\n|\r|\n)/", $content);
foreach($textlines as $line) {
$section->addText(htmlspecialchars($line));
}
And now I would like to have the text inside the brackets "[]" inserted as a footnote. I have NO idea how to get this handled. Maybe you understand this here: http://phpword.readthedocs.org/en/latest/elements.html#footnotes-endnotes