aioseo_normalize_assets_host, $paths[ $path ]
aioseo_normalize_assets_host, $paths[ $path ]
Appears in: all-in-one-seo-pack.5.0.0.1
Hook Type: filter
Displaying hooks found in version: all-in-one-seo-pack.5.0.0.1apply_filters('aioseo_normalize_assets_host, $paths[ $path ]') is found 3 times:
- /app/Common/Traits/Assets.php line 571
*/ public function normalizeAssetsHost( $path ) { static $paths = []; if ( isset( $paths[ $path ] ) ) { return apply_filters( 'aioseo_normalize_assets_host', $paths[ $path ] ); } // We need to verify the domain on the $path attribute matches // what's in site_url() for our assets or they won't load. $siteUrl = site_url(); $siteUrlEscaped = aioseo()->helpers->escapeRegex( $siteUrl ); - /app/Common/Traits/Assets.php line 581
$siteUrlEscaped = aioseo()->helpers->escapeRegex( $siteUrl ); if ( preg_match( "/^$siteUrlEscaped/i", (string) $path ) ) { $paths[ $path ] = $path; return apply_filters( 'aioseo_normalize_assets_host', $paths[ $path ] ); } // We now know that the path doesn't contain the site_url(). $newPath = $path; $siteUrlParsed = wp_parse_url( $siteUrl ); $host = aioseo()->helpers->escapeRegex( str_replace( 'www.', '', $siteUrlParsed['host'] ) ); - /app/Common/Traits/Assets.php line 607
} $paths[ $path ] = $newPath; return apply_filters( 'aioseo_normalize_assets_host', $paths[ $path ] ); } /** * Get all the CSS files which a JS asset depends on. * This won't work properly unless you've run `npm run build` first. *