* We need our custom method because encodeURIComponent is too aggressive and doesn't follow * http://www.ietf.org/rfc/rfc3986.txt with regards to the character set (pchar) allowed in path * segments: * segment = *pchar * pchar = unreserved / pct-encoded / sub-delims / ":" / "
(val)
| 1173 | * / "*" / "+" / "," / ";" / "=" |
| 1174 | */ |
| 1175 | function encodeUriSegment(val) { |
| 1176 | return encodeUriQuery(val, true). |
| 1177 | replace(/%26/gi, '&'). |
| 1178 | replace(/%3D/gi, '='). |
| 1179 | replace(/%2B/gi, '+'); |
| 1180 | } |
| 1181 | |
| 1182 | |
| 1183 | /** |
no test coverage detected