Same name in other branches
- 5.0.x src/Asset/AssetOptimizer.php \Drupal\advagg\Asset\AssetOptimizer::convertPathForceHttps()
- 8.x-3.x src/Asset/AssetOptimizer.php \Drupal\advagg\Asset\AssetOptimizer::convertPathForceHttps()
- 8.x-4.x src/Asset/AssetOptimizer.php \Drupal\advagg\Asset\AssetOptimizer::convertPathForceHttps()
Convert http:// to https://.
Parameters
string $path: Path to check.
Return value
string The modified path or the original if already https or relative.
1 call to AssetOptimizer::convertPathForceHttps()
- AssetOptimizer::processAssetArray in src/
Asset/ AssetOptimizer.php - Process a core asset array.
File
-
src/
Asset/ AssetOptimizer.php, line 418
Class
- AssetOptimizer
- Defines the base AdvAgg optimizer.
Namespace
Drupal\advagg\AssetCode
protected function convertPathForceHttps($path) {
if (strpos($path, 'http://') === 0) {
$path = 'https://' . substr($path, 7);
}
return $path;
}