post_content) $html = apply_filters( 'the_content', $post->post_content ); } if ( str_contains( $html, 'sp-position-' ) ) { $dir = dirname( __DIR__, 1 ); $js .= file_get_contents( $dir . '/assets/js/position.js' ); } return $js; }