-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathheader.php
More file actions
executable file
·49 lines (43 loc) · 1.73 KB
/
Copy pathheader.php
File metadata and controls
executable file
·49 lines (43 loc) · 1.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
/**
* The header for our theme.
*
* This is the template that displays all of the <head> section and everything up until <div id="content">
*
* @link https://developer.wordpress.org/themes/basics/template-files/#template-partials
*
* @package shiro
*/
use WMF\Images\Credits;
if ( ! defined( 'ABSPATH' ) ) {
exit; // File should never be accessed directly.
}
$wmf_skip2_content_label = get_theme_mod( 'wmf_skip2_content_label', __( 'Skip to content', 'shiro-admin' ) );
$wmf_post_thumbnail_url = get_the_post_thumbnail_url( get_the_ID() );
$wmf_ogmeta_ogimageurl = get_site_option( 'ogmeta_ogimageurl' );
?>
<!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- Setting up 'og:image' variable within <head> -->
<?php
// If set, configure 'featured image' as 'og:image'.
if ( $wmf_post_thumbnail_url && ! ( is_plugin_active( 'wordpress-seo/wp-seo.php' ) ) ) : ?>
<meta property="og:image" content="<?php echo esc_url( $wmf_post_thumbnail_url ); ?>" />
<?php
// If set, configure 'ogmeta_ogimageurl' as 'og:image'.
elseif ( $wmf_ogmeta_ogimageurl && ! ( is_plugin_active( 'wordpress-seo/wp-seo.php' ) ) ) : ?>
<meta property="og:image" content="<?php echo esc_url( $wmf_ogmeta_ogimageurl ); ?>" />
<?php endif; ?>
<?php wp_head(); ?>
</head>
<body <?php body_class(); ?>>
<div data-dropdown-backdrop></div>
<a class="skip-link screen-reader-text" href="#content"><?php echo esc_html( $wmf_skip2_content_label ); ?></a>
<div id="page" class="site">
<?php block_template_part( 'header' ); ?>
<div class="<?php echo esc_attr( wmf_get_header_container_class() ); ?>">
<div class="header-inner alignwide">
<?php