Expert Developer JavaScript Question:
Download Questions PDF

What is decodeURI() function?

Expert JavaScript Developer Interview Question
Expert JavaScript Developer Interview Question

Answer:

► The decodeURI() function is used to decode the URI.
► Syntax :
decodeURI(uri)
Where uri is URI to be decoded
► For example :
<script>
var uri = "EmpDetails.asp?Emp=årpit&mode=edit";
document.write(encodeURI(uri) + "
");
document.write(decodeURI(uri) + "
");
</script>
► Output :
EmpDetails.asp?Emp=%C3%A5&mode=edit
EmpDetails.asp?Emp=årpit&mode=edit.

Download Expert JavaScript Developer Interview Questions And Answers PDF

Previous QuestionNext Question
What is encodeURI() function?What is the difference between a null value and an undefined value?