<?php if ( !defined( 'ABSPATH' ) ) exit;//PHPの宣言と直接アクセスの拒否

/***** SEOセクション *****/
/* get_option GetOP01_optimize() */

/* alt属性の自動付与 */
if( isset( GetOP01_optimize()['use-auto-alt'] ) && GetOP01_optimize()['use-auto-alt'] ==1){
require_once (__DIR__ .'/auto-alt/auto-alt.php');
}

/* 画像タイトルタグの自動生成 */
if( isset( GetOP01_optimize()['add-image-title-tag'] ) && GetOP01_optimize()['add-image-title-tag'] ==1){
require_once (__DIR__ .'/add-media-title-attribute/add-media-title-attribute-functions.php');
}

/* Canonicalタグの出力 */
if( isset( GetOP01_optimize()['output-archive-canonical-tag'] ) && GetOP01_optimize()['output-archive-canonical-tag'] ==1){
require_once (__DIR__ .'/canonical-tag/canonical-tag.php');
}

/* 構造化データの出力 */
if( isset( GetOP01_optimize()['output-schema'] ) && GetOP01_optimize()['output-schema'] ==1){
//require_once (__DIR__ .'/schema/schema.php');
//require_once (__DIR__ .'/schema/schema-main-functions.php');
require_once (__DIR__ .'/schema/function.php');
}

/* SEOメタタグ設定 */
if( isset( GetOP01_optimize()['output-seo-fields'] ) && GetOP01_optimize()['output-seo-fields'] ==1){
require_once (__DIR__ .'/seo-fields/seo-fields.php');
require_once (__DIR__ .'/seo-fields/seo-fields-content.php');
}

/* noindexタグの出力 */
if( isset( GetOP01_optimize()['add-noindex-tag-in-head'] ) && GetOP01_optimize()['add-noindex-tag-in-head'] ==1){
require_once (__DIR__ .'/noindex/noindex-functions.php');
}

/***** 表示速度改善セクション *****/
/* get_option GetOP02_optimize() */

/* スクリプトの遅延読み込み */
if( isset( GetOP02_optimize()['use-defer-script'] ) && GetOP02_optimize()['use-defer-script'] ==1){
require_once (__DIR__ .'/defer-script/defer-script-function.php');
}

/*** .htaccessへの追記 ***/
if( isset( GetOP02_optimize()['add-htaccess-su-code'] ) && GetOP02_optimize()['add-htaccess-su-code'] ==1){
require_once (__DIR__ .'/add-htaccess/add-htaccess-functions.php');
}

/***** OGPタグの設定 *****/
/* get_option GetOP03_optimize() */

/* OGPタグの出力 */
if( isset( GetOP03_optimize()['output-ogptag'] ) && GetOP03_optimize()['output-ogptag'] == 1 ){
require_once (__DIR__ .'/ogptag/ogp-tag.php');
}

/***** SMTP AUTH *****/
/* get_option GetOP04_optimize() */

/* SMTP AUTH */
if( isset( GetOP04_optimize()['enable-smtp-auth'] ) && GetOP04_optimize()['enable-smtp-auth'] ==1){
require_once (__DIR__ .'/smtp-auth/smtp-auth-functions.php');
}


/***** その他セクション *****/
/* get_option GetOP05_optimize() */

/* 検索フォーム内の全角スペースを半角へ変換 */
if( isset( GetOP05_optimize()['use-search-optimize'] ) && GetOP05_optimize()['use-search-optimize'] ==1){
require_once (__DIR__ .'/search-optimize/search-optimize.php');
}

/* ゴミ箱の自動削除を停止 */
if( isset( GetOP05_optimize()['disable-trash-auto-cleanup'] ) && GetOP05_optimize()['disable-trash-auto-cleanup'] ==1){
require_once (__DIR__ .'/disable-trash-auto-clean/disable-trash-auto-clean-function.php');
}

/* リビジョン数の設定 */
if( isset( GetOP05_optimize()['enable-set-revisions'] ) && GetOP05_optimize()['enable-set-revisions'] ==1){
require_once (__DIR__ .'/set-revisions/functions.php');
}

/* 標準のサイトマップの制御（各項目の有効無効はプログラム上で行う） */
require_once (__DIR__ .'/default-sitemap/default-sitemap.php');

/* WordPress側のzlib圧縮を無効にする */
if( isset( GetOP05_optimize()['disable-zlib-complession'] ) && GetOP05_optimize()['disable-zlib-complession'] ==1){
require_once (__DIR__ .'/disable-zlib-comp/disable-zlib-comp.php');
}


