From 29366cb136dca1f205237bfbbf9f643dab634c6b Mon Sep 17 00:00:00 2001 From: n0099 Date: Fri, 9 Dec 2022 09:25:54 +0800 Subject: [PATCH] feat: add OpenGraph and twitter cards (#553) Co-authored-by: n0099 Co-authored-by: Seaton Jiang --- header.php | 61 +++++++++++++++++++++++++++++++++++++----------------- 1 file changed, 42 insertions(+), 19 deletions(-) diff --git a/header.php b/header.php index fffc4b7..330e84a 100644 --- a/header.php +++ b/header.php @@ -4,36 +4,59 @@ * 主题页眉 * @author Seaton Jiang * @license GPL-3.0 License - * @version 2022.05.27 + * @version 2022.12.09 */ ?> - - + - <?php wp_title('-', true, 'right'); ?> - - - + - + + + + + + + + + + + '; - } - wp_head(); - wp_print_scripts('jquery'); - mourning(); - if (kratos_option('seo_statistical')) { - echo kratos_option('seo_statistical'); - } + if (!is_home()) { + $tags = get_the_tags(); + if (is_array($tags)) { + foreach ($tags as $tag) { ?> + + + + + + + + + + + '; + } + wp_head(); + wp_print_scripts('jquery'); + mourning(); + if (kratos_option('seo_statistical')) { + echo kratos_option('seo_statistical'); + } ?> -
- \ No newline at end of file +