文件操作 - functions.php
返回文件管理
返回主菜单
删除本文件
文件: /storage/v12552/kidsonlychiropract/public_html/wp-content/themes/astra-child/functions.php
编辑文件内容
<?php /** * Astra Child Theme functions and definitions * * @link https://developer.wordpress.org/themes/basics/theme-functions/ * * @package Astra Child * @since 1.0.0 */ /** * Define Constants */ define( 'CHILD_THEME_ASTRA_CHILD_VERSION', '1.0.0' ); /** * Enqueue styles */ function child_enqueue_styles() { wp_enqueue_style( 'astra-child-theme', get_stylesheet_directory_uri() . '/style.css?ver='.time()); } add_action( 'wp_enqueue_scripts', 'child_enqueue_styles', 15 ); /* Exclude posts from sitemap.xml */ /*add_filter( 'wpseo_exclude_from_sitemap_by_post_ids', 'exclude_posts_from_xml_sitemaps' ); function exclude_posts_from_xml_sitemaps() { return [ 357,385,455,456,458,460,461,462,463,526,569,620,686 ]; } */ // Hide subscribe box on all event pages. add_filter( 'tec_views_v2_subscribe_links', function( $subscribe_links ) { // When passed an empty array, the template will bail and not display. return []; }, 100 ); /** * Enables the HTTP Strict Transport Security (HSTS) header in WordPress. */ add_action( 'send_headers', 'enable_strict_transport_security_hsts_header_wordpress' ); function enable_strict_transport_security_hsts_header_wordpress() { header( 'Strict-Transport-Security: max-age=31536000; includeSubDomains; preload' ); } add_action('wp_head', 'add_custom_javascript', 10); function add_custom_javascript(){ ?> <script type="text/javascript"> jQuery(document).ready(function(){ if(jQuery('#tec_noindex').length > 0){ jQuery('#tec_noindex').remove(); } }) </script> <?php } ?>
修改文件时间
将文件时间修改为当前时间的前一年
删除文件