Código PHP:
<?php
function site_config()
{
require_once('Connections/SCMS.php');
mysql_select_db($database_SCMS, $SCMS);
$query_site_config = "SELECT * FROM site";
$site_config = mysql_query($query_site_config, $SCMS) or die(mysql_error());
$row_site_config = mysql_fetch_assoc($site_config);
$totalRows_site_config = mysql_num_rows($site_config);
/*La variable sitename */
$sitename = $row_site_config['name'];
return $sitename;
}
function close_site_config()
{
mysql_free_result($site_config);
}
?>
La usas asi:
Código PHP:
<?php
include('core.php');
$sitename = site_config();
close_site_config();
?>
<!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 http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title><?php echo $sitename; ?></title>
</head>
<body>
<br /><div style="z-index:3" class="smallfont" align="center">LinkBacks Enabled by <a rel="nofollow" href="http://www.crawlability.com/vbseo/">vBSEO</a> 3.0.0</div></body>
</html>
Saludos.