Javascript String UnicoToUtf8()

Description

Javascript String UnicoToUtf8()


'use strict'/*w  w w. ja  v  a 2 s.  c o m*/
String.prototype.UnicoToUtf8  = function() {
    let str = this.toString();
    var result = str.replace(/\\/g, "%");
    return unescape(result);
}

Javascript String UnicoToUtf8()

String.prototype.UnicoToUtf8 = function() {
 let str = this.toString();
 let result = str.replace( /\\/g, '%' );
 return unescape( result );
};



PreviousNext

Related