WordPress.org

Making WordPress.org

Ticket #64: 64-meta.diff

File 64-meta.diff, 1.8 KB (added by iandunn, 7 years ago)
  • header.php

     
    100100<?php } ?>
    101101<meta name="google-site-verification" content="7VWES_-rcHBcmaQis9mSYamPfNwE03f4vyTj4pfuAw0" />
    102102<?php if ( empty( $_GET['wpcodex'] ) ) : ?>
    103 <title><?php if ( WPORG_SANDBOXED ) echo WPORG_SANDBOXED . ': '; echo $pagetitle; ?></title>
     103<title><?php echo wporg_sandbox_title( $pagetitle ); ?></title>
    104104<?php else : // codex ?>
    105105<!-- [codex head meta] -->
    106106<link rel="stylesheet" href="<?php echo $http_prefix; ?>wordpress.org/style/codex-wp4.css?3" />
  • functions-global.php

     
    191191<?php
    192192}
    193193
     194/*
     195 * If the current server is a sandbox, then put it's ID in the <title> tag to
     196 * help distinguish it from production
     197 */
     198function wporg_sandbox_title( $title ) {
     199        if ( defined( 'WPORG_SANDBOXED' ) && WPORG_SANDBOXED )
     200                $title = WPORG_SANDBOXED . ': ' . $title;
     201
     202        return $title;
     203}
     204 No newline at end of file
  • wp-content/themes/make-twentyeleven/functions.php

     
     1<?php
     2
     3require_once( ABSPATH . '/functions-global.php' );
     4add_filter( 'wp_title', 'wporg_sandbox_title' );
     5 No newline at end of file