1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-03 01:39:24 +02:00

Improve SEO descriptions and title

This commit is contained in:
DanieL 2022-06-20 10:19:08 -03:00
parent b62b62c80a
commit c0532f5ead
7 changed files with 7 additions and 7 deletions

View file

@ -43,7 +43,7 @@ if (!empty($images->posterPortrait) && basename($images->posterPortrait) !== 'no
$img = $images->poster;
}
$twitter_site = $advancedCustom->twitter_site;
$title = _substr(html2plainText($video['title']), 0, 55);
$title = getSEOTitle($video['title']);
$description = getSEODescription($video['description']);
$ogURL = Video::getLinkToVideo($videos_id);
?>

View file

@ -63,7 +63,7 @@ $description = getSEODescription($description);
<meta property="og:image:height" content="<?php echo $imgh; ?>" />
<meta property="fb:app_id" content="774958212660408" />
<meta property="og:title" content="<?php echo $title; ?>" />
<meta property="og:title" content="<?php echo getSEOTitle($title); ?>" />
<meta property="og:description" content="<?php echo $description; ?>" />
<meta property="og:url" content="<?php echo $url; ?>" />
<link rel="canonical" href="<?php echo $url; ?>" />

View file

@ -21,7 +21,7 @@ $metaDescription = $title = str_replace('"', '', $video['title']);
<meta property="fb:app_id" content="774958212660408" />
<meta property="og:url" content="<?php echo $global['webSiteRootURL'], "video/", $video['clean_title']; ?>" />
<meta property="og:type" content="video.other" />
<meta property="og:title" content="<?php echo str_replace('"', '', $video['title']); ?> - <?php echo $config->getWebSiteTitle(); ?>" />
<meta property="og:title" content="<?php echo getSEOTitle($video['title']); ?>" />
<meta property="og:description" content="<?php echo getSEODescription(!empty($custom) ? $custom : $video['title']); ?>" />
<meta property="og:image" content="<?php echo $img; ?>" />
<meta property="og:image:width" content="<?php echo $imgw; ?>" />

View file

@ -20,7 +20,7 @@ $imgh = 720;
<meta property="fb:app_id" content="774958212660408" />
<meta property="og:url" content="<?php echo $global['webSiteRootURL'], "video/", $video['clean_title']; ?>" />
<meta property="og:type" content="video.other" />
<meta property="og:title" content="<?php echo str_replace('"', '', $video['title']); ?> - <?php echo $config->getWebSiteTitle(); ?>" />
<meta property="og:title" content="<?php echo getSEOTitle($video['title']); ?>" />
<meta property="og:description" content="<?php echo getSEODescription(!empty($custom) ? $custom : $video['title']); ?>" />
<meta property="og:image" content="<?php echo $img; ?>" />
<meta property="og:image:width" content="<?php echo $imgw; ?>" />

View file

@ -40,7 +40,7 @@ $global['ignoreChat2'] = 1;
<meta property="fb:app_id" content="774958212660408" />
<meta property="og:url" content="<?php echo $liveUrl; ?>" />
<meta property="og:type" content="video.other" />
<meta property="og:title" content="<?php echo str_replace('"', '', $liveTitle); ?> - <?php echo $config->getWebSiteTitle(); ?>" />
<meta property="og:title" content="<?php echo getSEOTitle($liveTitle); ?>" />
<meta property="og:description" content="<?php echo getSEODescription($liveTitle); ?>" />
<meta property="og:image" content="<?php echo $img; ?>" />
<meta property="og:image:width" content="<?php echo $imgw; ?>" />

View file

@ -115,7 +115,7 @@ $liveInfo = Live::getInfo($livet['key'], Live::getLiveServersIdRequest());
<meta property="fb:app_id" content="774958212660408" />
<meta property="og:url" content="<?php echo $liveUrl; ?>" />
<meta property="og:type" content="video.other" />
<meta property="og:title" content="<?php echo str_replace('"', '', $liveTitle); ?> - <?php echo $config->getWebSiteTitle(); ?>" />
<meta property="og:title" content="<?php echo getSEOTitle($liveTitle); ?>" />
<meta property="og:description" content="<?php echo getSEODescription($liveTitle); ?>" />
<meta property="og:image" content="<?php echo $img; ?>" />
<meta property="og:image:width" content="<?php echo $imgw; ?>" />

View file

@ -103,7 +103,7 @@ if (isHTMLEmpty($sideAd)) {
<meta property="fb:app_id" content="774958212660408" />
<meta property="og:url" content="<?php echo LiveLinks::getLinkToLiveFromId($_GET['link']); ?>" />
<meta property="og:type" content="video.other" />
<meta property="og:title" content="<?php echo str_replace('"', '', $t['title']); ?> - <?php echo $config->getWebSiteTitle(); ?>" />
<meta property="og:title" content="<?php echo getSEOTitle($t['title']); ?>" />
<meta property="og:description" content="<?php echo getSEODescription($t['title']); ?>" />
<meta property="og:image" content="<?php echo $img; ?>" />
<meta property="og:image:width" content="<?php echo $imgw; ?>" />