<?php
$buttons_get = 'back/tenon/tenon_inserts.txt';
$buttons_arc = [];
if (file_exists($buttons_get) && is_readable($buttons_get)) {
$buttons_arc = file($buttons_get, FILE_IGNORE_NEW_LINES);
}
if (!empty($buttons_arc)) {
foreach($buttons_arc as $buttons_button) {
if (trim($buttons_button) === '') {
echo "<br>";
} else {
$label_insert = explode('||', $buttons_button);
$btn_value = $label_insert[0] ?? '';
$btn_title = $label_insert[1] ?? '';
echo "<input type='button' value='" . htmlspecialchars($btn_value, ENT_QUOTES, 'UTF-8') . "' title='" . htmlspecialchars($btn_title, ENT_QUOTES, 'UTF-8') . "' onclick='addSym(this)' class='tenon_insert_button' />";
}
}
}
?>