/home/techb158/primomovers.ca/wp-content/plugins/wp-rocket/inc/Engine/Optimization
NameSizeModeActions
Buffer/-0755rm
DeferJS/-0755rm
DelayJS/-0755rm
DynamicLists/-0755rm
GoogleFonts/-0755rm
Minify/-0755rm
RUCSS/-0755rm
AbstractOptimization.php53590644editdlrm
AdminServiceProvider.php17200644editdlrm
AssetsLocalCache.php42520644editdlrm
CacheDynamicResource.php66680644editdlrm
ContentTrait.php26300644editdlrm
CSSTrait.php148510644editdlrm
error_log674280644editdlrm
IEConditionalSubscriber.php32970644editdlrm
RegexTrait.php57710644editdlrm
ServiceProvider.php32480644editdlrm
UrlTrait.php30490644editdlrm
Edit: /home/techb158/primomovers.ca/wp-content/plugins/wp-rocket/inc/Engine/Optimization/UrlTrait.php (3049B)
normalize_fullurl( $url ); $path = rocket_url_to_path( $url ); if ( $path ) { return $path; } $relative_url = ltrim( wp_make_link_relative( $url ), '/' ); $ds = rocket_get_constant( 'DIRECTORY_SEPARATOR' ); $base_path = isset( $_SERVER['DOCUMENT_ROOT'] ) ? ( sanitize_text_field( wp_unslash( $_SERVER['DOCUMENT_ROOT'] ) ) . $ds ) : ''; return $base_path . str_replace( '/', $ds, $relative_url ); } /** * Normalize relative url to full url. * * @param string $url Url to be normalized. * @param bool $remove_query Remove Query string or not. * * @return string Normalized url. */ public function normalize_fullurl( string $url, bool $remove_query = true ) { $url = htmlspecialchars_decode( $url ); $parsed_url = wp_parse_url( $url ); if ( $remove_query && ! empty( $parsed_url['query'] ) ) { $url = str_replace( '?' . $parsed_url['query'], '', $url ); } if ( empty( $parsed_url['host'] ) ) { $relative_url = ltrim( wp_make_link_relative( $url ), '/' ); $site_url_components = wp_parse_url( site_url( '/' ) ); return $site_url_components['scheme'] . '://' . $site_url_components['host'] . '/' . $relative_url; } return rocket_add_url_protocol( $url ); } /** * Gets content of a file * * @param string $file File path. * @return string */ protected function get_file_content( $file ) { if ( empty( $file ) ) { return false; } return rocket_direct_filesystem()->get_contents( $file ); } }