Come posso fare per inserire l`echo che ho nella funzione di php, nella tabella della pagina in html?
codice PHP:
Codice PHP:
<?php
foreach(glob("*.html") as $file) {
$code = file_get_contents($file);
$titolo = '';
$descrizione = '';
if(preg_match('@<title>([^<]*?)</title>@', $code, $match)){
$titolo = $match[1];
}
if(preg_match('@<meta name="description" content="([^"]*?)">@', $code, $match)){
$descrizione = $match[1];
}
echo "$titolo"
echo "$descrizione"
}
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta content="en-us" http-equiv="Content-Language">
<meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
<title>Senza nome 1</title>
<style type="text/css">
.style1 {
border-width: 0px;
}
.style2 {
border-style: solid;
border-width: 1px;
}
</style>
</head>
<body>
<table style="width: 100%" class="style1">
<tr>
<td class="style2" style="width: 138px"></td>
</tr>
<tr>
<td class="style2" style="width: 138px"></td>
</tr>
</table>
</body>
</html>