function _openid_normalize_url in Drupal 6
1 call to _openid_normalize_url()
- _openid_normalize in modules/
openid/ openid.inc - Normalize the given identifier as per spec.
File
- modules/
openid/ openid.inc, line 110 - OpenID utility functions.
Code
function _openid_normalize_url($url) {
$normalized_url = $url;
if (stristr($url, '://') === FALSE) {
$normalized_url = 'http://' . $url;
}
// Strip the fragment and fragment delimiter if present.
$normalized_url = strtok($normalized_url, '#');
if (substr_count($normalized_url, '/') < 3) {
$normalized_url .= '/';
}
return $normalized_url;
}