|
|
@ -4,11 +4,12 @@
|
|
|
|
/* ページのタイトル */
|
|
|
|
/* ページのタイトル */
|
|
|
|
function gettitle (string $str): string {
|
|
|
|
function gettitle (string $str): string {
|
|
|
|
preg_match("/<title>(.*)<\/title>/", $str, $matches);
|
|
|
|
preg_match("/<title>(.*)<\/title>/", $str, $matches);
|
|
|
|
return $matches[1];
|
|
|
|
return isset($matches[1]) ? $matches[1] : "";
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
function getimg (string $str): string {
|
|
|
|
function getimg (string $str): string {
|
|
|
|
preg_match('/<img class="NEWS_tempPhoto__picture" src="(.*)" alt="">/', $str, $matches);
|
|
|
|
preg_match('/<img class="NEWS_tempPhoto__picture" src="(.*)" alt="">/', $str, $matches);
|
|
|
|
|
|
|
|
if (!isset($matches[1])) return "";
|
|
|
|
$res = str_replace("https://", IMGPROXY."/", $matches[1]);
|
|
|
|
$res = str_replace("https://", IMGPROXY."/", $matches[1]);
|
|
|
|
unset($matches);
|
|
|
|
unset($matches);
|
|
|
|
return $res;
|
|
|
|
return $res;
|
|
|
@ -79,6 +80,7 @@
|
|
|
|
$res = preg_replace('/<table>(.*?)<\/table>/s', "", $res);
|
|
|
|
$res = preg_replace('/<table>(.*?)<\/table>/s', "", $res);
|
|
|
|
$res = preg_replace('/<div class="adsense0(.*?)<\/div>/s', "", $res);
|
|
|
|
$res = preg_replace('/<div class="adsense0(.*?)<\/div>/s', "", $res);
|
|
|
|
$res = preg_replace('/<div class="adsense(.*?)<\/div>/s', "", $res);
|
|
|
|
$res = preg_replace('/<div class="adsense(.*?)<\/div>/s', "", $res);
|
|
|
|
|
|
|
|
$res = preg_replace('/(www.?)youtube.com/s', "youtube.owacon.moe", $res);
|
|
|
|
$res = preg_replace('/<div class="subInfo">(.*?)<\/div>/s', "", $res);
|
|
|
|
$res = preg_replace('/<div class="subInfo">(.*?)<\/div>/s', "", $res);
|
|
|
|
$res = preg_replace("/(^[\r\n]*|[\r\n]+)[\s\t]*[\r\n]+/", "\n", $res);
|
|
|
|
$res = preg_replace("/(^[\r\n]*|[\r\n]+)[\s\t]*[\r\n]+/", "\n", $res);
|
|
|
|
$res = str_replace("<!--article_image-->", "", $res);
|
|
|
|
$res = str_replace("<!--article_image-->", "", $res);
|
|
|
@ -150,7 +152,7 @@
|
|
|
|
<body>
|
|
|
|
<body>
|
|
|
|
<?= $out["content"] ?>
|
|
|
|
<?= $out["content"] ?>
|
|
|
|
<p class="footer">
|
|
|
|
<p class="footer">
|
|
|
|
Spliti 1.1.0 |
|
|
|
|
Spliti 1.1.1 |
|
|
|
|
<a href="https://gitler.moe/suwako/spliti"><img src="/git.png" alt="Git"></a> |
|
|
|
|
<a href="https://gitler.moe/suwako/spliti"><img src="/git.png" alt="Git"></a> |
|
|
|
|
<a href="https://076.moe/">076</a>
|
|
|
|
<a href="https://076.moe/">076</a>
|
|
|
|
</p>
|
|
|
|
</p>
|
|
|
|