The encodeURI and decodeURI functions are intended to work with complete URIs; they
assume that any reserved characters in the URI are intended to have special meaning and so are not
encoded. The encodeURIComponent and decodeURIComponent functions are intended to work with the
individual component parts of a URI; they assume that any reserved characters represent text and so must be
encoded so that they are not interpreted as reserved characters when the component is part of a complete
URI.

比较清楚的解析了这两对函数的区别。

ECMA5.1中关于encodeURI,decodeURI 和encodeComponentURI,decodeComponentURI的区别的更多相关文章

  1. PHP中的urlencode,rawurlencode和JS中的encodeURI,encodeURIComponent

    PHP中的urlencode,rawurlencode和JS中的encodeURI,encodeURIComponent [PHP中的urlencode和rawurlencode] urlencode ...

  2. 在php中定义常量时,const与define的区别?

    问]在php中定义常量时,const与define的区别?  [答]使用const使得代码简单易读,const本身就是一个语言结构,而define是一个函数.另外const在编译时要比define快很 ...

  3. [转载]jQuery中wrap、wrapAll和wrapInner用法以及区别

    原文地址:jQuery中wrap.wrapAll和wrapInner用法以及区别作者:伊少君 原文: <ul>   <li title='苹果'>苹果</li>   ...

  4. 脚本引用中的defer和async的用法和区别

    之前的博客漫谈前端优化中的引用资源优化曾经提到过脚本引用异步设置defer.async,没有细说,这里展开一下,谈谈它们的作用和区别,先上张图来个针对没用过的小伙伴有个初始印象: 是的,就是在页面脚本 ...

  5. jQuery中的.bind()、.live()和.delegate()之间区别分析

    jQuery中的.bind()..live()和.delegate()之间区别分析,学习jquery的朋友可以参考下.   DOM树   首先,可视化一个HMTL文档的DOM树是很有帮助的.一个简单的 ...

  6. SQL语句中count(1)count(*)count(字段)用法的区别

    SQL语句中count(1)count(*)count(字段)用法的区别 在SQL语句中count函数是最常用的函数之一,count函数是用来统计表中记录数的一个函数, 一. count(1)和cou ...

  7. js中的text(),html() ,val()的区别

    js中的text(),html() ,val()的区别 text(),html() ,val()三个方法用于html元素的存值和取值,但是他们各有特点,text()用于html元素文本内容的存取,ht ...

  8. python中urllib, urllib2,urllib3, httplib,httplib2, request的区别

    permike原文python中urllib, urllib2,urllib3, httplib,httplib2, request的区别 若只使用python3.X, 下面可以不看了, 记住有个ur ...

  9. Linux中tty、pty、pts的概念区别

    转自Linux中tty.pty.pts的概念区别 基本概念: 1> tty(终端设备的统称): tty一词源于Teletypes,或者teletypewriters,原来指的是电传打字机,是通过 ...

随机推荐

  1. CodeForces Round #179 (295A) - Greg and Array

    题目链接:http://codeforces.com/problemset/problem/295/A 我的做法,两次线段树 #include <cstdio> #include < ...

  2. 教程-(SQL DBE、ADO连接)+(Firebird火鸟+DbExpress)+(VF DBF数据库)+(DB Paradox)

    DBE 连接SQL Server显然用ADO或DBEXPRESS更有优势,起码连接起来比较方便. BDE的话可以用如下方法:(以下以Delphi7为例,其它版本的DELPHI请自己摸索一下,不过基本相 ...

  3. Extending JavaScript Natives

    Most built-in JavaScript types are constructors whose prototypes contain the methods and other prope ...

  4. js定时显示广告代码

    这是一则定时显示广告的javascript代码,当然也可以定时显示某一区块内容,很实用. 代码如下: function strToDate(str, ext) { if (str == null || ...

  5. textarea文本域宽度和高度(width、height)自己主动适应变化处理

    文章来源:http://www.cnblogs.com/jice/archive/2011/08/07/2130069.html <HTML> <HEAD> <TITLE ...

  6. 原创 C# 正则表达式 读写 Ini 文件

    昨天遇到读ini文件的问题,我知道C#里没有提供相应的类,所有的.net配置都是xml方式存储的. 读取ini文件,很多人直接google一把,然后添加dll引用.介绍的比较详细的,如: C#如何读写 ...

  7. debian安装mono环境

    官网 http://pkg-mono.alioth.debian.org/ 在/etc/apt/sources.list 加上 deb http://debian.meebey.net/pkg-mon ...

  8. 用Java对xml文档进行遍历,更新,创建,删除

    import java.io.File;import java.io.FileInputStream; import javax.imageio.stream.FileImageInputStream ...

  9. iOS UIKit:TableView之编辑模式(3)

    一般table view有编辑模式和正常模式,当table view进入编辑模式时,会在row的左边显示编辑和重排控件,如图 42所示的编辑模式时的控件布局:左边的editing control有表 ...

  10. javascript进击(九)参考手册

    完整的 Number 对象参考手册 如需可用于 Number 对象的所有属性和方法的完整参考,请访问我们的 Number 对象参考手册. 该参考手册包含每个属性和方法的描述和实例. 完整的 Strin ...