TEST trying to fix problem with id attributes for links
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Nonimart 2025-06-23 16:53:44 +02:00
parent e4e81ef81c
commit 699ed3dcd9

View File

@ -120,6 +120,7 @@ function apply_footnotes_urls_to_content($content)
$links = $dom->getElementsByTagName('a');
foreach ($links as $key => $link) {
write_log($key);
if ($link->hasAttribute('class') && strpos($link->getAttribute('class'), 'footnote-reference') !== false) {
$link->setAttribute('id', 'footnote-' . $key + 1);
write_log($link->getAttribute('id'));