PHP 8.3.4 Released!

oauth_urlencode

(PECL OAuth >=0.99.2)

oauth_urlencodeКодирует URI в соответствии с RFC 3986

Описание

oauth_urlencode(string $uri): string

Кодирует URI в соответствии с » RFC 3986.

Список параметров

uri

URI для кодирования.

Возвращаемые значения

Возвращает строку закодированную в соответствии с » RFC 3986.

add a note

User Contributed Notes 1 note

up
-1
bohwaz
13 years ago
Note that php5.3 rawurlencode will do exactly the same thing.

For PHP 5.2, easy replacement to this function :

<?php

function rfc3986_encode($str)
{
$str = rawurlencode($str);
$str = str_replace('%E7', '~', $str);
return
$str;
}

?>
To Top