OAuth 函数
在线手册:中文  英文

oauth_urlencode

(PECL OAuth >=0.99.2)

oauth_urlencodeEncode a URI to RFC 3986

说明

string oauth_urlencode ( string $uri )

Encodes a URI to » RFC 3986.

参数

uri

URI to encode.

返回值

Returns an » RFC 3986 encoded string.


OAuth 函数
在线手册:中文  英文

用户评论:

bohwaz (2010-03-30 07:20:09)

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;
}

?>

易百教程