Skip to content

Instantly share code, notes, and snippets.

@mypacecreator
Last active December 15, 2021 08:02
Show Gist options
  • Save mypacecreator/1e56c762b171c540a04d to your computer and use it in GitHub Desktop.
Save mypacecreator/1e56c762b171c540a04d to your computer and use it in GitHub Desktop.
WordPress4.4でタイトルタグのセパレータが' - 'になったのを' | 'に戻す
<?php
//コピペするなら3行目から↓
function mypace_custom_title_separator( $sep ){
$sep = '|';
return $sep;
}
add_filter( 'document_title_separator', 'mypace_custom_title_separator' ); //フィルターフックで処理を上書き
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment