Automattic\WooCommerce\StoreApi\Utilities
JsonWebToken::to_base_64_url()
Encodes a string to url safe base64.
Method of the class: JsonWebToken{}
No Hooks.
Return
String
.
Usage
$result = JsonWebToken::to_base_64_url( $string );
- $string(string) (required)
- The string to be encoded.
JsonWebToken::to_base_64_url() JsonWebToken::to base 64 url code WC 7.7.0
private static function to_base_64_url( string $string ) { return str_replace( array( '+', '/', '=' ), array( '-', '_', '' ), base64_encode( $string ) // phpcs:ignore WordPress.PHP.DiscouragedPHPFunctions.obfuscation_base64_encode ); }