Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#20199 Reverted BaseUrl::isRelative() behaviour to previous 2.0.49 ve… #20203

Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions framework/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Yii Framework 2 Change Log

- Bug #20191: Fix `ActiveRecord::getDirtyAttributes()` for JSON columns with multi-dimensional array values (brandonkelly)
- Bug #20175: Fix bad result for pagination when used with GridView (@lav45)
- Bug #20199: Fix yii\web\UrlManager::createAbsoluteUrl() external absolute links creation (@edegaudenzi)


2.0.50 May 30, 2024
Expand Down
2 changes: 1 addition & 1 deletion framework/helpers/BaseUrl.php
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,7 @@ public static function home($scheme = false)
*/
public static function isRelative($url)
{
return preg_match('~^[[:alpha:]][[:alnum:]+-.]*://|^//~', $url) === 0;
return strncmp($url, '//', 2) && strpos($url, '://') === false;
}

/**
Expand Down
Loading