%2$s', esc_url( get_permalink( get_the_ID() ) ), /* translators: %s: Name of current post */ sprintf( esc_html__( 'Continue reading %s', 'afterlight-2' ), '' . get_the_title( get_the_ID() ) . '' ) ); return ' … ' . $link; } add_filter( 'excerpt_more', 'afterlight_2_excerpt_more' ); endif; /** * Apply full-page background image to the pseudo element so that it also works on mobile Safari. * * @since Afterlight 1.0 * * @see wp_add_inline_style() */ function afterlight_2_full_page_background_image() { $image = get_background_image(); $full_page_background = get_theme_mod( 'afterlight_2_full_page_background', '1' ); $css = ''; if ( ! empty ( $image ) && '1' == $full_page_background ) { $css .= 'body:before { background-image: url("' . esc_url( $image ) . '"); }'; } wp_add_inline_style( 'afterlight-2-style', $css ); } add_action( 'wp_enqueue_scripts', 'afterlight_2_full_page_background_image' ); /** * Add a pingback url auto-discovery header for singularly identifiable articles. */ function afterlight_2_pingback_header() { if ( is_singular() && pings_open() ) { echo ''; } } add_action( 'wp_head', 'afterlight_2_pingback_header' );