【问题标题】:How to remove URLs in meta description tag如何删除元描述标签中的 URL
【发布时间】:2018-11-17 21:55:32
【问题描述】:

我遇到了一个 Google 和其他搜索引擎根本不理解的小问题。

在我的 vbulletin 论坛中,我的大多数主题都是以图片开头,然后是文字。

问题是当我们查看搜索引擎结果时,它看起来像这样:

那么你知道 php/html 中是否有办法从元标记中删除 url 吗?

我知道这是 vbulletin 引擎的一个问题,但我已经问过他们有关对此问题进行排序的问题,他们说这是他们的费用。

顺便说一句,负责元描述标签的 2 个 php 文件包含它(也许它可能会有所帮助):

在 showthread.php 中:

$thread['meta_description'] = strip_bbcode(strip_quotes($thread['description']), false, true);
$thread['meta_description'] = htmlspecialchars_uni(fetch_censored_text(fetch_trimmed_title($thread['meta_description'], 500, false)));

在 get_forum.php 中:

if ($foruminfo['description'] != '') {
        $desc = prepare_utf8_string(strip_tags($foruminfo['description']));
        if (strlen($desc) > 0) {
            $out['desc'] = $desc;
        }

非常感谢您帮助我,我知道这不是寻求 vbulletin 帮助的最佳场所,但即使在他们的 2 个官方论坛中,也没有人能正确地帮助我解决这个问题。

【问题讨论】:

    标签: php html seo vbulletin


    【解决方案1】:

    在标题中提及元标记并抓取网站以供 google 审查。抓取可能需要一些时间,但它会起作用。

    <meta name="description" content="This is an example of a meta description. This will often show up in search results.">
    

    【讨论】:

    • 您好,感谢您的回复,但我的所有页面/线程的标题中已经有一个描述元标记..
    猜你喜欢
    • 1970-01-01
    • 2021-08-20
    • 2015-11-26
    • 1970-01-01
    • 2013-05-28
    • 1970-01-01
    • 2011-11-06
    • 2012-08-23
    • 1970-01-01
    相关资源
    最近更新 更多