.neturlencode

What's the difference between EscapeUriString and EscapeDataString?


If only deal with url encoding, I should use EscapeUriString?


Solution

  • Use EscapeDataString always (for more info about why, see Livven's answer below)

    Edit: removed dead link to how the two differ on encoding