JavaScript Error name Property URIError

Introduction

URIError: An error in encodeURI() has occurred

View in separate window

<!DOCTYPE html>
<html>
<body>
<p id="demo"></p>

<script>
try {//ww w  .  j  a  va 2 s. co  m
  decodeURI("%%%");
}
catch(err) {
  document.getElementById("demo").innerHTML = err.name;
}
</script>

</body>
</html>



PreviousNext

Related