使用 Curl 函数获取网站标题的 PHP 代码示例
(.*)/i', $response, $title);
$title = str_replace(array("
", "
", "
", ',', ' '), '', $title[1]);
return $title;
}
$t_url = 'http://example.com';
$title = getWebsiteTitle($t_url);
echo $title;
?>
原文地址: https://www.cveoy.top/t/topic/o7R6 著作权归作者所有。请勿转载和采集!