urlEncode

fun String?.urlEncode(charsetName: String = "UTF-8"): String