<?xml version="1.0" encoding="utf-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><title>艾研之家</title><link>http://loveyan.com/</link><description>书山有路勤为径，学海无涯苦作舟！</description><item><title>红帽子RedHatLinux9光盘安装图解教程</title><link>http://loveyan.com/post/6.html</link><description>&lt;p style=&quot;text-align: left;&quot;&gt;一,准备工作&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;1,购买或下载Redhat9的安装光盘(3张盘)或镜像文件,下载地址: 红帽子主站下载∶&lt;a href=&quot;http://www.redhat.com/
&quot; _src=&quot;http://www.redhat.com/
&quot;&gt;http://www.redhat.com/&amp;nbsp;&lt;/a&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;2,在硬盘中至少留2个分区给安装系统用,挂载点所用分区推荐4G以上，交换分区不用太大在250M左右比较适合,文件系统格式不论,反正安装过程会重新格式化。&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;3,记录下你电脑中下列设备型号∶鼠标、键盘、显卡、网卡、显示器。及网络设置用到的IP地址、子网掩码、默认网关和DNS名称服务器地址等信息。&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;二,安装红帽子Red Hat Linux 9
 &amp;nbsp; &amp;nbsp;将光驱设为第一启动盘,放入第一张安装光盘后重新启动电脑,如果你的光驱支持自启动, 如无意外将出现如下图&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/y20061225172759.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;直接按回车键后将出现如下图1 ,如果你不处理30秒后也会自动进入。&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/d20061225172840.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图1&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;在图1中提示:是否测试安装CD的内容的完整性,选“OK”开始测试安装CD;选“Skip”不测试安装CD开始安装出现图6所示,如果是第一次安装当然要测试安装CD,选“OK”后回车,出现如下图2&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/o20061225172923.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图2&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;选“Test”测试安装光盘的文件,选“Eject CD”测试光盘以外的安装文件,这里我选择“Test”后回车,出现如下图3&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/u20061225172955.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图3&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;正在测试第一张安装CD,测试完后显示如下图4所示&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/y20061225173022.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图4&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;看到上图最后一行英文“It is OK to install from this media”说明这张安装CD是OK的,按“Enter”键回车后,显示如下图5所示&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/920061225173055.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图5&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;选择“Continue”并回车开始安装。假如你想测试余下的2张安装CD,请放入下一张安装CD到光驱中,并选“Test”后回车即开始测试,完成后再次出现图4画面表示通过测试,再按回车键后又出现图5所示,重复步骤直到完成全部安装CD的测试。全部安装CD的测试完成后,用“向右箭头键”选择“Continue”并放入第一张安装CD到光驱后回车,安装程序开始检测计算机外围硬件设备,接着出现如下图6&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/b20061225173125.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图6&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;出现帮助文本和介绍,按“Hide Help”关闭帮助文本,按“Release Notes”显示发行注记,按“Next”进行下一步,出现如下图7&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/k20061225173157.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图7&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;这时鼠标可用了,这一步选择安装向导所用语言(不是安装系统所用语言),就选“简体中文(简体中文)”,点击“下一步”后显示如下图8&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/620061225173231.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图8&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;选择键盘类型,一般的键盘多为美式键盘“U.S English”,选择好后,点击“下一步”显示如下图9&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/t2006122517331.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图9&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;根据你的鼠标类型进行选择,然后点击“下一步”显示如下图10&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/420061225173329.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图10&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;选择安装类型,我这里选“个人桌面”,点击“下一步”显示如下图11&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/n20061225173432.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图11&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;磁盘分区设置是关键的一步,搞不好会丢失硬盘有用数据,请小心。如果选“自动分区”后,点击“下一步”会显示如下图12&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/l20061225173459.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图12&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;自动分区包含三个选项:删除系统内所有的Linux分区、删除系统内的所有分区和保存所有分区使用现有的空闲空间。由此看来这项选择不适合我的需要,我的硬盘有4个分区,而第一个分区已安装了Windows 98,我想保留它装双系统。于是点击“上一步”返回到图11所示画面后再重新选择“用Disk Druid手工分区”,点击“下一步”显示如下图13&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/520061225173528.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图13&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;表中列出了硬盘的所有分区,我准备用原系统的D盘和E盘。即用/dev/hda5(4.8G)作挂载点安装系统,用/dev/hda6(252M)做交换分区。点击“/dev/hda5”将其选中(如上图中),然后点击“编缉”按钮,弹出如下图14所示的对话框。&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/n2006122517361.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图14&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;挂载点选根分区“/”即可,当前文件系统类型是FAT,是Linux不支持的,因些选中“将分区格式化成”并在框内选“ext3”或“ext2”,如下图15所示&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/t20061225173633.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图15&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;点击“确定”即可,在分区表中可见到已创建了挂载点。还要创建交换分区才能进行下一步安装，接着在图13所示分区表中点击“/dev/hda6”把它选中,然后点击“编缉”按钮,弹出如下图16所示的对话框。&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/520061225173710.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图16&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;因/dev/hda6是用来做交换分区,所以挂载点一栏不用选,只选“将分区格式化成swap”, 然后点击“确定”即可。显示如下图17&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/y20061225173743.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图17&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;在图中可见到/dev/hda5和/dev/hda6的分区类型已经更改了。点击“下一步”弹出如下图18所示的对话框。&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/j20061225173817.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图18&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;提示格式化两个分区，点“格式化”按钮后,显示如下图19&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/a20061225173852.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图19&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;引导装载程序配置,默认将系统引导信息写到硬盘主引导扇区,可通过点击右上角的“改变引导装载程序”按钮进行设置。上图中列出了启动菜单有两项∶DOS和Red Hat Linux,可选中DOS然后点编辑,将DOS改为Windows 98；同样将Red Hat Linux改为Red Hat Linux 9；改动后如下图20&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/a20061225173924.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图20&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;选择开机默认启动的系统(在其前面的囗内打勾),如上图中选Red Hat Linux 9为默认启动系统。然后点击“下一步”出现如下图21&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/420061225173956.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图21&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;设置网络,如果你不清楚亦可以后进系统后再配置,点击“下一步”出现如下图22&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/p20061225174022.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图22&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;防火墙配置一般用途选“中级”就可以了,点击“下一步”出现如下图23&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/r20061225174048.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图23&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;选择系统默认语言一定要选中“Chinese(P.R.of China)”简体中文,否则可能进系统后不能显示简体中文还需另外安装语言支持包。在“选择你想在该系统上安装的其它语言”框内最少要选一项“Chinese(P.R.of China)”简体中文,可同时选择多种语言(如果有必要)。点击“下一步”出现如下图24&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/b20061225174114.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图24&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;时区选“亚洲/上海”,点击“下一步”出现如下图25&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/820061225174142.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图25&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;设置根口令即root管理员密码,root帐号在系统中具有最高权根,平时登陆系统一般不用该帐号,设置完根口令后,点击“下一步”出现如下图26&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/d20061225174212.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图26&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;个人桌面默认软件包安装选择,一般用途使用默认的就够用。亦可在安装完成后,进系统运行“redhat-config-package”工具来添加/删除软件。点击“下一步”出现如下图27&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/420061225174246.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图27&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;安装向导到此结束，如果你对上面各个步骤还有异议可直点“上一步”返回后重新设置, 否则点“下一步”后再无“上一步”选择,程序不可亦。要开始安装请点击“下一步”,出现如下图28&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/r2006122517444.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图28&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;一个慢长的安装过程已经开始,你可休息约30分钟了。总进度去到约75%时,出现如下图29&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/120061225174431.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图29&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;第一张光盘中要安装的内容已完成,提示插入第二张光盘,插入第二张光盘后点“确定”后继续安装,到总进度去到约96%时,按提示换第三张光盘,完成后出现如下图30&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/a20061225174458.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图30&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;建议创建引导盘,将去除写保护的空白软盘放入软驱中,点击“下一步”,出现如下图31&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/w20061225174530.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图31&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;正在创建引导盘,完成后出现如下图32所示&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/62006122517462.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图32&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;核对安装程序检测的显卡型号是否与你的真实显卡型号是否相同,如果不同请正确选择,然后点击“下一步”,出现如下图33&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/p20061225174629.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图33&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;核对安装程序检测的显示器型号是否与你的真实显示器型号是否相同,如果不同请正确选择,然后点击“下一步”,出现如下图34&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/l20061225174654.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图34&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;选择色彩深度和屏幕分辨率,然后点击“下一步”,出现如下图35&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/i20061225174721.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图35&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;安装已完成,取出光盘和软盘后点“退出”,系统将重新启动,重新启动后将首次出现启动选择菜单,如下图36&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/g20061225174752.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图36&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;10秒后自动进入,出现如下图37&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/y20061225174823.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图37&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;第一次启动还是进入命令提示,要求输入用户名,现在系统只有一个帐号即管理员帐号,默认的管理员帐号名为root,输入“root”后回车,出现如下图38&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/r2006122517495.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图38&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;提示输入密码,输入安装时设定的系统管理员密码后回车,出现如下图39&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/c20061225174941.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图39&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;已经以管理员身份登陆了系统,但我不想用命令提示形式显示,要进入图形介面.进入图形介面的命令是“startx”,输入“startx”后回车准备进入,出现如下图40&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/d2006122517508.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图40&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;怎么搞?又跳出来！原来X配置出问题,需运行“redhat-config-xfree86”重新配置,运行“redhat-config-xfree86”后出现如下图41&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/020061225175042.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图41&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;点击“配置”对显示器及显卡的型号和参数重新设置,如不能确定也可点系统默认设置,完成后点“确定”后如配置正确即可进入图形界面,出现如下图42&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/920061225175116.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图42&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;再次出现登陆窗口,输入“root”后回车,出现如下图43&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/420061225175146.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图43&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;再输入密码后回车,出现如下图44&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/k20061225175233.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图44&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;原来已经以root的身份进入了桌面,不过好像错过了设置普通帐号那一步,于是点红帽子主菜单--注销,在弹出的对话框中选“重新启动”,重新启动后又再出现启动选择菜单,接着出现如下图45&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/p20061225175310.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图45&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;本来应该早出现的东西现在才出现,点“前进”开始配置系统,出现如下图46&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/420061225175345.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图46&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;创建一个普通帐号,用于平时登陆系统用,帐号名用abc,输入密码后,点“前进”出现如下图47&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/s2006122517550.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图47&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;正确设置时间和日期后,点“前进”出现如下图48&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/q20061225175531.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图48&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;注册提示,有两项选择,第一项:“是,我想在 Red Hat 网络注册我的系统”,第二项:“否,我不想注删我的系统”。以后再说,选第二项:“否,我不想注删我的系统”,点“前进”出现如下图49&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/420061225175611.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图49&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;如果你有其它光盘想安装，就装啦。点“前进”出现如下图50&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/a20061225175645.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图50&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;全部设置已经结束,点“前进”出现如下图51&lt;/p&gt;&lt;p style=&quot;text-align:center&quot;&gt;&lt;img src=&quot;/zb_users/upload/2006/12/720061225175718.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图51&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;安装全部完成,现在以abc用户的身份进入了系统。以后进入系统都是图形界面了。慢慢分享一下啦!&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;三、卸载Redhat9系统的方法:&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;进入DOS下在提示符“A:\&amp;gt;_”下输入“fdisk/mbr”回车,重写硬盘主引导扇区即可,重启后就没有了Redhat9的启动菜单了,再格式化Redhat9所在的分区就完事！&lt;/p&gt;</description><pubDate>Mon, 27 Mar 2006 16:00:30 +0800</pubDate></item><item><title>红旗Linux5.0桌面正式版光盘安装图解教程</title><link>http://loveyan.com/post/5.html</link><description>&lt;p style=&quot;text-align: left;&quot;&gt;&amp;nbsp;&amp;nbsp;红旗Linux5.0桌面正式版是北京中科红旗软件技术有限公司2006年4月8日推出的。 红旗Linux 桌面版5.0（产品代号为Apatite），Apatite全球率先通过了LSB3.0测试认证，具备了Linux标准基础的一切品质。&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&amp;nbsp;&amp;nbsp;一,准备工作:&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&amp;nbsp;&amp;nbsp;1,购买红旗Linux5.0桌面正式版安装光盘或下载镜像文件,镜像文件下载地址:&lt;a href=&quot;http://www.redflag-linux.com/chanpin/dt5/&quot; _src=&quot;http://www.redflag-linux.com/chanpin/dt5/&quot;&gt;http://www.redflag-linux.com/chanpin/dt5/&lt;/a&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&amp;nbsp;&amp;nbsp;2,记录下你电脑中网络设置用到的IP地址、子网掩码、默认网关和DNS名称服务器地址等信息。DNS地址，大家可以从windows中的拨号软件中获得，如在98/Me/2000中安装EnterNet300,连接上网后，点击其登陆网络后右下角的图标，从“详细”按钮中看登陆信息即可,实在不行打个客服电话。&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&amp;nbsp;&amp;nbsp;3,硬件兼容性列表∶&lt;a href=&quot;http://www.redflag-linux.com/ppd/product_user/hardware_table.php&quot; _src=&quot;http://www.redflag-linux.com/ppd/product_user/hardware_table.php&quot;&gt;http://www.redflag-linux.com/ppd/product_user/hardware_table.php&lt;/a&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&amp;nbsp;&amp;nbsp;二,安装红旗Linux5.0桌面版
&amp;nbsp;&amp;nbsp;将下载的镜像文件刻录成光盘后，将光驱设为第一启动盘,放入第一张安装光盘后重新启动电脑,如果你的光驱支持自启动, 如无意外将出现如下图1&lt;img src=&quot;/zb_users/upload/2006/12/j20061225165151.jpg&quot;/&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图1&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&amp;nbsp;&amp;nbsp;上图显示∶用图形界面方式安装或升级安装Red Flag Linux请按回车键，用文本方式安装或升级安装Red Flag Linux请输入“text”后按&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;这里要用图形界面方式安装红旗Linux5.0桌面正式版，直接回车后继续，将出现如下图2所示画面。&lt;img src=&quot;/zb_users/upload/2006/12/p20061225165242.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图2&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;全中文界面的安装向导。许可协议，阅读后，点击“接受”再点击“下一步”按钮，很快出现如下图3所示画面。&lt;img src=&quot;/zb_users/upload/2006/12/k20061225165313.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图3&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;选择安装分区及分区的方式是安装Linux的关键步骤，搞不好会丢失硬盘数据，应慎重选择。&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;如果选择自动分区，将会有三个选项∶1、删除硬盘中所有Linux分区；2、删除硬盘中所有分区；3、用硬盘中未分配空间安装系统。&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;使用Disk Druid手工分区即可随心所欲进行分区。&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;这里选“使用Disk Druid进行手工分区”。选择“使用Disk Druid进行手工分区”后点击“下一步”按钮出现如下图4所示。&lt;img src=&quot;/zb_users/upload/2006/12/820061225165350.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图4&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;上图列出了硬盘中的所有分区详细信息(这里我的硬盘是未分区的)。在这里准备将硬盘划分为三个分区∶第一个约8G用于安装系统，第二个约512MB(内存2倍)用作交换区，剩余空间给第三个分区。&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;在分区列表中点击“空闲”后，再点击“编辑”按钮，出现如下图5&lt;img src=&quot;/zb_users/upload/2006/12/i20061225165422.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图5&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;在弹出的窗口中挂载点一栏选择“/”，文件系统类型选“ext3”，大小为“8000”如下图6所示。&lt;img src=&quot;/zb_users/upload/2006/12/p20061225165454.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图6&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;然后点击“确实”按钮，出现下图7所示。&lt;img src=&quot;/zb_users/upload/2006/12/520061225165632.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图7&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;从上图可见∶第一个分区已经建成。接下来建交换区在分区列表中再次点击“空闲”后，再点击“编辑”按钮，出现如下图8&lt;img src=&quot;/zb_users/upload/2006/12/x20061225165659.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图8&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;在弹出的窗口中挂载点一栏不进行选择，文件系统类型选“swap”，大小为“512”如下图9所示。&lt;img src=&quot;/zb_users/upload/2006/12/n20061225165729.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图9&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;点击“确实”按钮，出现下图10所示。&lt;img src=&quot;/zb_users/upload/2006/12/d2006122516580.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图10&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;从上图可见∶交换区已经建成。接下来将全部剩余空间作一个区，在分区列表中再次点击“空闲”后，再点击“编辑”按钮，出现如下图11所示。&lt;img src=&quot;/zb_users/upload/2006/12/k20061225165827.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图11&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;在弹出的窗口中挂载点一栏选择“/D”(因为存放数据的分区，名称可自定，但要在前面加上“/”)，文件系统类型选“ext3”，大小一栏不管它而是直接勾选“使用全部可用空间”，选择结果如下图12所示。&lt;img src=&quot;/zb_users/upload/2006/12/y20061225165941.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图12&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;点击“确实”按钮，出现下图13所示。&lt;img src=&quot;/zb_users/upload/2006/12/02006122517011.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图13&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;从上图可见∶三个分区都建成并将格式化。点下一步继续，出现下图14&lt;img src=&quot;/zb_users/upload/2006/12/92006122517036.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图14&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;引导设置∶引导程序的安装位置用默认值，把它安装在主引导记录(MBR)上就行了。点下一步继续，出现下图15所示。&lt;img src=&quot;/zb_users/upload/2006/12/y200612251711.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图15&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;上图为网络设置。点击“编辑”按钮，弹出编辑窗口如下图16&lt;img src=&quot;/zb_users/upload/2006/12/62006122517134.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图16&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;这里要指定IP地址，因此先取消“通过DHCP进行配置”前面的勾。如下图17所示。&lt;img src=&quot;/zb_users/upload/2006/12/i200612251724.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图17&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;IP地址∶如果是多台机共用一条宽带线上网的，主机或宽带路由器的IP地址设为192.168.1.1 子网掩码为255.255.255.0 其它机的IP地址设为192.168.1.x(x为2--255的整数)；如果是单独一台机用一条宽带线上网的，IP地址设为169.254.0.1子网掩码为255.255.0.0即可。这里设置如下图18所示。&lt;img src=&quot;/zb_users/upload/2006/12/j2006122517232.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图18&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;点击“确实”按钮，出现下图19所示。&lt;img src=&quot;/zb_users/upload/2006/12/a2006122517258.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图19&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;主机名随便设；网关设为主机IP地址，内网设为192.168.1.1单独上网的设为与IP地址相同169.254.0.1即可。再输入名称解释服务器DNS地址。我用佛山联通DNS如下图20所示。&lt;img src=&quot;/zb_users/upload/2006/12/p2006122517356.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图20&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;点下一步继续，出现下图21所示。&lt;img src=&quot;/zb_users/upload/2006/12/m2006122517430.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图21&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;为系统管理员root帐户设置密码，输入6位以上密码后，点击“下一步”按钮继续，出现如下图22所示。&lt;img src=&quot;/zb_users/upload/2006/12/4200612251751.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图22&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;安装向导到此结束，点“下一步”后再没回头的余地，出现如下图23所示。&lt;img src=&quot;/zb_users/upload/2006/12/92006122517534.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图23&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;开始分区并格式化分区，然后开始安装系统，如下图24所示。&lt;img src=&quot;/zb_users/upload/2006/12/k200612251762.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图24&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;安装过程是最漫长的，完成后出现如下图25所示。&lt;img src=&quot;/zb_users/upload/2006/12/w2006122517631.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图25&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;安装已经全部完成，取出安装光盘后，点击“下一步”安装程序将重新启动计算机，重新启动后首先出现启动菜单，如下图26所示。&lt;img src=&quot;/zb_users/upload/2006/12/a200612251774.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图26&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;上图有三个选项∶第一项为正常启动，第二项为进入安全模式(与正常启动比较，在启动时增加了显示设置调整)，第三项为进入控制台(命令行模式)。
 &amp;nbsp; &amp;nbsp;如不进行选择，10秒后将自动启动默认选项。红旗Linux5.0桌面正式版启动过程出现如下图27所示。&lt;img src=&quot;/zb_users/upload/2006/12/z2006122517732.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图27&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;当进度条完成后，出现如下图28所示的用户登陆画面。&lt;img src=&quot;/zb_users/upload/2006/12/y200612251780.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图28&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;如果显卡驱动没有正确安装是看不清楚这个画面的，可重启选择进入安全模式先设置好显示设置。
&amp;nbsp; &amp;nbsp;用户名输入“root”，然后输入密码，再点击“登录”按钮继续启动。出现如下图29所示。&lt;img src=&quot;/zb_users/upload/2006/12/52006122517830.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图29&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;正在初始化系统服务，很快出现下图30&lt;img src=&quot;/zb_users/upload/2006/12/h200612251791.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图30&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;已经进入桌面了，同时弹出了硬件配置向导，还是配置一下！点击“配置”按钮，配置显卡后再配置网卡等，完成后出现如下图31所示。&lt;img src=&quot;/zb_users/upload/2006/12/82006122517930.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图31&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;点“确定”后自动保存设置并注销，出现如下图32所示。&lt;img src=&quot;/zb_users/upload/2006/12/b2006122517955.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图32&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp; 输入密码，点击“登录”按钮启动。进入桌面后如下图33所示。&lt;img src=&quot;/zb_users/upload/2006/12/c20061225171024.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图33&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;打开我的电脑后显示如下图34所示。&lt;img src=&quot;/zb_users/upload/2006/12/720061225171048.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图34&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;从上图可见两个分区“/”和“/D”已经加载。在开始菜单中没有关机选项，按“Ctrl+Alt+Del”组合键后才出现，如下图35所示。&lt;img src=&quot;/zb_users/upload/2006/12/l20061225171116.jpg&quot;/&gt;&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: center;&quot;&gt;图35&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;这个系统的操作方式很接近Windows XP系统。对NTFS分区只读，对FAT32分区可读写。&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;三、卸载红旗Linux5.0桌面正式版方法&lt;/enter&gt;&lt;/p&gt;&lt;p style=&quot;text-align: left;&quot;&gt;&lt;enter&gt;&amp;nbsp;&amp;nbsp;用MS-DOS启动盘或98启动盘启动进入DOS，运行“fdisk /mbr” 重写主引导记录MBR即可删除启动菜单只留下进入Windows系统选项，再格式化Linux5.0安装分区即可。&lt;/enter&gt;&lt;/p&gt;</description><pubDate>Sun, 26 Mar 2006 17:32:57 +0800</pubDate></item><item><title>ls 命令使用详解</title><link>http://loveyan.com/post/17.html</link><description>&lt;pre class=&quot;prism-highlight prism-language-bash&quot;&gt;用法：ls&amp;nbsp;[选项]...&amp;nbsp;[文件]...
List&amp;nbsp;information&amp;nbsp;about&amp;nbsp;the&amp;nbsp;FILEs&amp;nbsp;(the&amp;nbsp;current&amp;nbsp;directory&amp;nbsp;by&amp;nbsp;default).
Sort&amp;nbsp;entries&amp;nbsp;alphabetically&amp;nbsp;if&amp;nbsp;none&amp;nbsp;of&amp;nbsp;-cftuvSUX&amp;nbsp;nor&amp;nbsp;--sort&amp;nbsp;is&amp;nbsp;specified.

长选项必须使用的参数对于短选项时也是必需使用的。
&amp;nbsp;&amp;nbsp;-a,&amp;nbsp;--all&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;不隐藏任何以.&amp;nbsp;开始的项目
&amp;nbsp;&amp;nbsp;-A,&amp;nbsp;--almost-all&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;列出除.&amp;nbsp;及..&amp;nbsp;以外的任何项目
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--author&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;与-l&amp;nbsp;同时使用时列出每个文件的作者
&amp;nbsp;&amp;nbsp;-b,&amp;nbsp;--escape&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以八进制溢出序列表示不可打印的字符
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--block-size=SIZE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;scale&amp;nbsp;sizes&amp;nbsp;by&amp;nbsp;SIZE&amp;nbsp;before&amp;nbsp;printing&amp;nbsp;them.&amp;nbsp;&amp;nbsp;E.g.,
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;`--block-size=M&amp;#39;&amp;nbsp;prints&amp;nbsp;sizes&amp;nbsp;in&amp;nbsp;units&amp;nbsp;of
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1,048,576&amp;nbsp;bytes.&amp;nbsp;&amp;nbsp;See&amp;nbsp;SIZE&amp;nbsp;format&amp;nbsp;below.
&amp;nbsp;&amp;nbsp;-B,&amp;nbsp;--ignore-backups&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;do&amp;nbsp;not&amp;nbsp;list&amp;nbsp;implied&amp;nbsp;entries&amp;nbsp;ending&amp;nbsp;with&amp;nbsp;~
&amp;nbsp;&amp;nbsp;-c&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;with&amp;nbsp;-lt:&amp;nbsp;sort&amp;nbsp;by,&amp;nbsp;and&amp;nbsp;show,&amp;nbsp;ctime&amp;nbsp;(time&amp;nbsp;of&amp;nbsp;last
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;modification&amp;nbsp;of&amp;nbsp;file&amp;nbsp;status&amp;nbsp;information)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;with&amp;nbsp;-l:&amp;nbsp;show&amp;nbsp;ctime&amp;nbsp;and&amp;nbsp;sort&amp;nbsp;by&amp;nbsp;name
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;otherwise:&amp;nbsp;sort&amp;nbsp;by&amp;nbsp;ctime,&amp;nbsp;newest&amp;nbsp;first
&amp;nbsp;&amp;nbsp;-C&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;每栏由上至下列出项目
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--color[=WHEN]&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;控制是否使用色彩分辨文件。WHEN&amp;nbsp;可以是
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;quot;never&amp;quot;(默认)、&amp;quot;always&amp;quot;或&amp;quot;auto&amp;quot;其中之一
&amp;nbsp;&amp;nbsp;-d,&amp;nbsp;--directory&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;当遇到目录时列出目录本身而非目录内的文件
&amp;nbsp;&amp;nbsp;-D,&amp;nbsp;--dired&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;产生适合Emacs&amp;nbsp;的dired&amp;nbsp;模式使用的结果
&amp;nbsp;&amp;nbsp;-f&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;不进行排序，-aU&amp;nbsp;选项生效，-lst&amp;nbsp;选项失效
&amp;nbsp;&amp;nbsp;-F,&amp;nbsp;--classify&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;加上文件类型的指示符号(*/=@|&amp;nbsp;其中一个)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--format=关键字&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;交错-x，逗号分隔-m，水平-x，长-l，
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;单栏-1，详细-l，垂直-C
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--full-time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;即-l&amp;nbsp;--time-style=full-iso
&amp;nbsp;&amp;nbsp;-g&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;类似-l，但不列出所有者
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--group-directories-first
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;在文件前分组目录。此选项可与--sort&amp;nbsp;一起使用，
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;但是一旦使用--sort=none&amp;nbsp;(-U)将禁用分组
&amp;nbsp;&amp;nbsp;-G,&amp;nbsp;--no-group&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以一个长列表的形式，不输出组名
&amp;nbsp;&amp;nbsp;-h,&amp;nbsp;--human-readable&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;与-l&amp;nbsp;一起，以易于阅读的格式输出文件大小
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;(例如&amp;nbsp;1K&amp;nbsp;234M&amp;nbsp;2G)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--si&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;同上面类似，但是使用1000&amp;nbsp;为基底而非1024
&amp;nbsp;&amp;nbsp;-H,&amp;nbsp;--dereference-command-line
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;跟随命令行列出的符号链接
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--dereference-command-line-symlink-to-dir
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;跟随命令行列出的目录的符号链接
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--hide=PATTERN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;隐藏符合PATTERN&amp;nbsp;模式的项目
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;(-a&amp;nbsp;或&amp;nbsp;-A&amp;nbsp;将覆盖此选项)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--indicator-style=方式&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;指定在每个项目名称后加上指示符号方式：
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;none&amp;nbsp;(默认)，classify&amp;nbsp;(-F)，file-type&amp;nbsp;(-p)
&amp;nbsp;&amp;nbsp;-i,&amp;nbsp;--inode&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;显示每个文件的inode&amp;nbsp;号
&amp;nbsp;&amp;nbsp;-I,&amp;nbsp;--ignore=PATTERN&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;不显示任何符合指定shell&amp;nbsp;PATTERN&amp;nbsp;的项目
&amp;nbsp;&amp;nbsp;-k&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;即--block-size=1K
&amp;nbsp;&amp;nbsp;-l&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;使用较长格式列出信息
&amp;nbsp;&amp;nbsp;-L,&amp;nbsp;--dereference&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;当显示符号链接的文件信息时，显示符号链接所指示
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;的对象而并非符号链接本身的信息
&amp;nbsp;&amp;nbsp;-m&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;所有项目以逗号分隔，并填满整行行宽
&amp;nbsp;&amp;nbsp;-n,&amp;nbsp;--numeric-uid-gid&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;类似&amp;nbsp;-l，但列出UID&amp;nbsp;及GID&amp;nbsp;号
&amp;nbsp;&amp;nbsp;-N,&amp;nbsp;--literal&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;输出未经处理的项目名称&amp;nbsp;(如不特别处理控制字符)
&amp;nbsp;&amp;nbsp;-o&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;类似&amp;nbsp;-l，但不列出有关组的信息
&amp;nbsp;&amp;nbsp;-p,&amp;nbsp;&amp;nbsp;--indicator-style=slash&amp;nbsp;&amp;nbsp;对目录加上表示符号&amp;quot;/&amp;quot;
&amp;nbsp;&amp;nbsp;-q,&amp;nbsp;--hide-control-chars&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以&amp;quot;?&amp;quot;字符代替无法打印的字符
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--show-control-chars&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;直接显示无法打印的字符&amp;nbsp;(这是默认方式，除非调用
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;的程序名称是&amp;quot;ls&amp;quot;而且是在终端输出结果)
&amp;nbsp;&amp;nbsp;-Q,&amp;nbsp;--quote-name&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;将条目名称括上双引号
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--quoting-style=方式&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;使用指定的quoting&amp;nbsp;方式显示条目的名称：
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;literal、locale、shell、shell-always、c、escape
&amp;nbsp;&amp;nbsp;-r,&amp;nbsp;--reverse&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;逆序排列
&amp;nbsp;&amp;nbsp;-R,&amp;nbsp;--recursive&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;递归显示子目录
&amp;nbsp;&amp;nbsp;-s,&amp;nbsp;--size&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以块数形式显示每个文件分配的尺寸
&amp;nbsp;&amp;nbsp;-S&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;根据文件大小排序
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--sort=WORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以下是可选用的WORD&amp;nbsp;和它们代表的相应选项：
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;extension&amp;nbsp;-X&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;status&amp;nbsp;&amp;nbsp;&amp;nbsp;-c
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;none&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;-U&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;-t
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;size&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;-S&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;atime&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;-u
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;time&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;-t&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;access&amp;nbsp;&amp;nbsp;&amp;nbsp;-u
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;version&amp;nbsp;&amp;nbsp;&amp;nbsp;-v&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;use&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;-u
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--time=WORD&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;和-l&amp;nbsp;同时使用时显示WORD&amp;nbsp;所代表的时间而非修改时
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;间：atime、access、use、ctime&amp;nbsp;或status；加上
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--sort=time&amp;nbsp;选项时会以指定时间作为排序关键字
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--time-style=STYLE&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;和-l&amp;nbsp;同时使用时根据STYLE&amp;nbsp;代表的格式显示时间：
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;full-iso、iso、locale、posix-iso、+FORMAT。
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;FORMAT&amp;nbsp;即是&amp;quot;date&amp;quot;所用的时间格式；如果FORMAT
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;是FORMAT1&amp;lt;换行&amp;gt;FORMAT2，FORMAT1&amp;nbsp;适用于较旧
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;的文件而FORMAT2&amp;nbsp;适用于较新的文件；如果STYLE
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;以&amp;quot;posix-&amp;quot;开头，则STYLE&amp;nbsp;仅在POSIX&amp;nbsp;语系之外
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;生效。
&amp;nbsp;&amp;nbsp;-t&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;根据修改时间排序
&amp;nbsp;&amp;nbsp;-T,&amp;nbsp;--tabsize=宽度&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;指定制表符(Tab)的宽度，而非8&amp;nbsp;个字符
&amp;nbsp;&amp;nbsp;-t&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;sort&amp;nbsp;by&amp;nbsp;modification&amp;nbsp;time,&amp;nbsp;newest&amp;nbsp;first
&amp;nbsp;&amp;nbsp;-T,&amp;nbsp;--tabsize=COLS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;assume&amp;nbsp;tab&amp;nbsp;stops&amp;nbsp;at&amp;nbsp;each&amp;nbsp;COLS&amp;nbsp;instead&amp;nbsp;of&amp;nbsp;8
&amp;nbsp;&amp;nbsp;-u&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;同-lt&amp;nbsp;一起使用：按照访问时间排序并显示
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;同-l一起使用：显示访问时间并按文件名排序
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;其他：按照访问时间排序
&amp;nbsp;&amp;nbsp;-U&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;不进行排序；按照目录顺序列出项目
&amp;nbsp;&amp;nbsp;-v&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;在文本中进行数字(版本)的自然排序
&amp;nbsp;&amp;nbsp;-w,&amp;nbsp;--width=COLS&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;自行指定萤幕宽度而不使用目前的数值
&amp;nbsp;&amp;nbsp;-x&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;逐行列出项目而不是逐栏列出
&amp;nbsp;&amp;nbsp;-X&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;根据扩展名排序
&amp;nbsp;&amp;nbsp;-1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;每行只列出一个文件
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--help&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;显示此帮助信息并退出
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;--version&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;显示版本信息并退出

SIZE&amp;nbsp;可以是一个可选的整数，后面跟着以下单位中的一个：
KB&amp;nbsp;1000，K&amp;nbsp;1024，MB&amp;nbsp;1000*1000，M&amp;nbsp;1024*1024，还有&amp;nbsp;G、T、P、E、Z、Y。

使用色彩来区分文件类型的功能已被禁用，默认设置和&amp;nbsp;--color=never&amp;nbsp;同时禁用了它。
使用&amp;nbsp;--color=auto&amp;nbsp;选项，ls&amp;nbsp;只在标准输出被连至终端时才生成颜色代码。
LS_COLORS&amp;nbsp;环境变量可改变此设置，可使用&amp;nbsp;dircolors&amp;nbsp;命令来设置。

退出状态：
&amp;nbsp;0&amp;nbsp;&amp;nbsp;正常
&amp;nbsp;1&amp;nbsp;&amp;nbsp;一般问题&amp;nbsp;(例如：无法访问子文件夹)
&amp;nbsp;2&amp;nbsp;&amp;nbsp;严重问题&amp;nbsp;(例如：无法使用命令行参数)

#示例：
#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-l&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#显示当前目录内容的长列表
total&amp;nbsp;8016
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;25214&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;favicon.ico
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;446&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;feed.php
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1577&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-lh&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#不以字节方式显示文件大小
total&amp;nbsp;7.9M
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;25K&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;favicon.ico
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;446&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;feed.php
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;1.6K&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-ihS&amp;nbsp;&amp;nbsp;&amp;nbsp;#显示文件大小之后，从大到小排序
4459543&amp;nbsp;favicon.ico&amp;nbsp;&amp;nbsp;4461279&amp;nbsp;zb_system&amp;nbsp;&amp;nbsp;4459541&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-l&amp;nbsp;--block-size=M&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#使用MB作为单位，文件大小
total&amp;nbsp;8M
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;1M&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;favicon.ico
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;1M&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;feed.php
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;1M&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-a&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#显示隐藏文件
.&amp;nbsp;&amp;nbsp;..&amp;nbsp;&amp;nbsp;favicon.ico&amp;nbsp;&amp;nbsp;feed.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-d&amp;nbsp;*/&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#只列出目录
zb_install/&amp;nbsp;&amp;nbsp;zb_system/&amp;nbsp;&amp;nbsp;zb_users/

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-g&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#不打印所有者信息
total&amp;nbsp;8016
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;25214&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;favicon.ico
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;446&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;feed.php
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1577&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-lG&amp;nbsp;&amp;nbsp;&amp;nbsp;#不打印组信息
total&amp;nbsp;8016
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;25214&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;favicon.ico
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;446&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;feed.php
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1577&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-n&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#打印UID和GID&amp;nbsp;
total&amp;nbsp;8016
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;500&amp;nbsp;500&amp;nbsp;&amp;nbsp;&amp;nbsp;25214&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;favicon.ico
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;500&amp;nbsp;500&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;446&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;feed.php
-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;500&amp;nbsp;500&amp;nbsp;&amp;nbsp;&amp;nbsp;1577&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-li&amp;nbsp;&amp;nbsp;&amp;nbsp;#打印每个文件的索引号&amp;nbsp;
total&amp;nbsp;8016
4459543&amp;nbsp;-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;25214&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;favicon.ico
4459542&amp;nbsp;-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;446&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;feed.php
4459541&amp;nbsp;-rw-r--r--&amp;nbsp;&amp;nbsp;1&amp;nbsp;www&amp;nbsp;www&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;1577&amp;nbsp;Mar&amp;nbsp;&amp;nbsp;3&amp;nbsp;13:59&amp;nbsp;index.php

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-p&amp;nbsp;&amp;nbsp;&amp;nbsp;#目录增加&amp;nbsp;/&amp;nbsp;(斜线)&amp;nbsp;
avatar/&amp;nbsp;&amp;nbsp;cache/&amp;nbsp;&amp;nbsp;data/&amp;nbsp;&amp;nbsp;emotion/&amp;nbsp;&amp;nbsp;plugin/&amp;nbsp;&amp;nbsp;theme/&amp;nbsp;&amp;nbsp;upload/

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-r&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#按时间倒排序
03&amp;nbsp;&amp;nbsp;02

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-R&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;#递归列出子目录&amp;nbsp;
.:
avatar
cache
c_option.php
data
emotion
plugin
theme
upload

./avatar:
0.png

./cache:
compiled
index.html
。。。。。。。。。。。。。。省略。。。。。。。。。。。。。。。

#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-lX&amp;nbsp;&amp;nbsp;&amp;nbsp;#扩展名排序
#&amp;nbsp;&amp;nbsp;ls&amp;nbsp;-lt&amp;nbsp;&amp;nbsp;&amp;nbsp;#按修改时间倒排序&lt;/pre&gt;</description><pubDate>Wed, 01 Mar 2006 11:37:30 +0800</pubDate></item><item><title>一个文本框输入限制</title><link>http://loveyan.com/post/16.html</link><description>&lt;pre class=&quot;prism-highlight prism-language-javascript&quot;&gt;&amp;lt;script&amp;gt;
function&amp;nbsp;regInput(obj,&amp;nbsp;reg,&amp;nbsp;inputStr)
{
&amp;nbsp;&amp;nbsp;var&amp;nbsp;docSel&amp;nbsp;=&amp;nbsp;document.selection.createRange()
&amp;nbsp;&amp;nbsp;if&amp;nbsp;(docSel.parentElement().tagName&amp;nbsp;!=&amp;nbsp;&amp;quot;INPUT&amp;quot;)&amp;nbsp;return&amp;nbsp;false
&amp;nbsp;&amp;nbsp;oSel&amp;nbsp;=&amp;nbsp;docSel.duplicate()
&amp;nbsp;&amp;nbsp;oSel.text&amp;nbsp;=&amp;nbsp;&amp;quot;&amp;quot;
&amp;nbsp;&amp;nbsp;var&amp;nbsp;srcRange&amp;nbsp;=&amp;nbsp;obj.createTextRange()
&amp;nbsp;&amp;nbsp;oSel.setEndPoint(&amp;quot;StartToStart&amp;quot;,&amp;nbsp;srcRange)
&amp;nbsp;&amp;nbsp;var&amp;nbsp;str&amp;nbsp;=&amp;nbsp;oSel.text&amp;nbsp;+&amp;nbsp;inputStr&amp;nbsp;+&amp;nbsp;srcRange.text.substr(oSel.text.length)
&amp;nbsp;&amp;nbsp;return&amp;nbsp;reg.test(str)
}
&amp;lt;/script&amp;gt;

小写英文：&amp;lt;xmp&amp;nbsp;style=&amp;nbsp;&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[a-z]*$/,&amp;nbsp;&amp;nbsp;String.fromCharCode(event.keyCode))&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[a-z]*$/,&amp;nbsp;&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[a-z]*$/,&amp;nbsp;&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;style=&amp;quot;ime-mode:Disabled&amp;quot;
&amp;gt;&amp;lt;br&amp;gt;

大写英文：&amp;lt;xmp&amp;nbsp;style=&amp;nbsp;&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[A-Z]*$/,&amp;nbsp;&amp;nbsp;String.fromCharCode(event.keyCode))&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[A-Z]*$/,&amp;nbsp;&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[A-Z]*$/,&amp;nbsp;&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;style=&amp;quot;ime-mode:Disabled&amp;quot;&amp;gt;
&amp;lt;br&amp;gt;

任意数字：&amp;lt;xmp&amp;nbsp;style=&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[0-9]*$/,&amp;nbsp;&amp;nbsp;String.fromCharCode(event.keyCode))&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[0-9]*$/,&amp;nbsp;&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[0-9]*$/,&amp;nbsp;&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;style=&amp;quot;ime-mode:Disabled&amp;quot;
&amp;gt;&amp;lt;br&amp;gt;

限2位小数：&amp;lt;xmp&amp;nbsp;style=&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^\d*\.?\d{0,2}$/,&amp;nbsp;&amp;nbsp;String.fromCharCode(event.keyCode))&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^\d*\.?\d{0,2}$/,&amp;nbsp;&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^\d*\.?\d{0,2}$/,&amp;nbsp;&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;style=&amp;quot;ime-mode:Disabled&amp;quot;
&amp;gt;&amp;nbsp;如:&amp;nbsp;123.12&amp;lt;br&amp;gt;


日　&amp;nbsp;&amp;nbsp;期：&amp;lt;xmp&amp;nbsp;style=&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^\d{1,4}([-\/](\d{1,2}([-\/](\d{1,2})?)?)?)?$/,&amp;nbsp;&amp;nbsp;String.fromCharCode(event.keyCode))&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^\d{1,4}([-\/](\d{1,2}([-\/](\d{1,2})?)?)?)?$/,&amp;nbsp;&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^\d{1,4}([-\/](\d{1,2}([-\/](\d{1,2})?)?)?)?$/,&amp;nbsp;&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;style=&amp;quot;ime-mode:Disabled&amp;quot;
&amp;gt;&amp;nbsp;如:&amp;nbsp;2002-9-29&amp;lt;br&amp;gt;

任意中文：&amp;lt;xmp&amp;nbsp;style=&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^$/,&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;String.fromCharCode(event.keyCode))&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[\u4E00-\u9FA5]*$/,&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[\u4E00-\u9FA5]*$/,&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;gt;&amp;lt;br&amp;gt;

部分英文：&amp;lt;xmp&amp;nbsp;style=&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[a-e]*$/,&amp;nbsp;&amp;nbsp;String.fromCharCode(event.keyCode))&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[a-e]*$/,&amp;nbsp;&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[a-e]*$/,&amp;nbsp;&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;style=&amp;quot;ime-mode:Disabled&amp;quot;
&amp;gt;&amp;nbsp;范围:&amp;nbsp;a,b,c,d,e&amp;lt;br&amp;gt;

部分中文：&amp;lt;xmp&amp;nbsp;style=&amp;quot;display:inline&amp;quot;&amp;gt;&amp;nbsp;&amp;lt;/xmp&amp;gt;

&amp;lt;script&amp;nbsp;language=javascript&amp;gt;
function&amp;nbsp;checkChinese(oldLength,&amp;nbsp;obj)
{
var&amp;nbsp;oTR&amp;nbsp;=&amp;nbsp;window.document.selection.createRange()
var&amp;nbsp;reg&amp;nbsp;=&amp;nbsp;/[^一二三四五六七八九十]/g
oTR.moveStart(&amp;quot;character&amp;quot;,&amp;nbsp;-1*(obj.value.length-oldLength))
oTR.text&amp;nbsp;=&amp;nbsp;oTR.text.replace(reg,&amp;nbsp;&amp;quot;&amp;quot;)
}
&amp;lt;/script&amp;gt;
&amp;lt;input&amp;nbsp;onkeypress=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;onkeydown=&amp;quot;setTimeout(&amp;#39;checkChinese(&amp;#39;+this.value.length+&amp;#39;,&amp;#39;+this.uniqueID+&amp;#39;)&amp;#39;,&amp;nbsp;1)&amp;quot;
&amp;nbsp;&amp;nbsp;onpaste&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[一二三四五六七八九十]*$/,&amp;nbsp;&amp;nbsp;window.clipboardData.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;nbsp;&amp;nbsp;ondrop&amp;nbsp;&amp;nbsp;=&amp;nbsp;&amp;quot;return&amp;nbsp;regInput(this,&amp;nbsp;/^[一二三四五六七八九十]*$/,&amp;nbsp;&amp;nbsp;event.dataTransfer.getData(&amp;#39;Text&amp;#39;))&amp;quot;
&amp;gt;&amp;nbsp;范围:&amp;nbsp;一二三四五六七八九十&amp;lt;br&amp;gt;&lt;/pre&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Sat, 18 Feb 2006 11:31:18 +0800</pubDate></item><item><title>WEB编程开发常用的代码</title><link>http://loveyan.com/post/15.html</link><description>&lt;pre class=&quot;prism-highlight prism-language-actionscript&quot;&gt;1.&amp;nbsp;ASP与Access数据库连接：&amp;nbsp;
dim&amp;nbsp;conn,mdbfile&amp;nbsp;&amp;nbsp;
mdbfile=server.mappath(&amp;quot;数据库名称.mdb&amp;quot;)&amp;nbsp;&amp;nbsp;
set&amp;nbsp;conn=server.createobject(&amp;quot;adodb.connection&amp;quot;)&amp;nbsp;&amp;nbsp;
conn.open&amp;nbsp;&amp;quot;driver={microsoft&amp;nbsp;access&amp;nbsp;driver&amp;nbsp;(*.mdb)};uid=admin;pwd=数据库密码;dbq=&amp;quot;&amp;amp;mdbfile

2.&amp;nbsp;ASP与SQL数据库连接：&amp;nbsp;dim&amp;nbsp;conn&amp;nbsp;&amp;nbsp;
set&amp;nbsp;conn=server.createobject(&amp;quot;ADODB.connection&amp;quot;)&amp;nbsp;&amp;nbsp;
con.open&amp;nbsp;&amp;quot;PROVIDER=SQLOLEDB;DATA&amp;nbsp;SOURCE=SQL服务器名称或IP地址;UID=sa;PWD=数据库密码;DATABASE=数据库名称&amp;nbsp;

建立记录集对象：&amp;nbsp;set&amp;nbsp;rs=server.createobject(&amp;quot;adodb.recordset&amp;quot;)&amp;nbsp;&amp;nbsp;
rs.open&amp;nbsp;SQL语句,conn,3,2&amp;nbsp;&amp;nbsp;

SQL常用命令使用方法：&amp;nbsp;

数据记录筛选：&amp;nbsp;sql=&amp;quot;select&amp;nbsp;*&amp;nbsp;from&amp;nbsp;数据表&amp;nbsp;where&amp;nbsp;字段名=字段值&amp;nbsp;order&amp;nbsp;by&amp;nbsp;字段名&amp;nbsp;&amp;quot;&amp;nbsp;&amp;nbsp;
sql=&amp;quot;select&amp;nbsp;*&amp;nbsp;from&amp;nbsp;数据表&amp;nbsp;where&amp;nbsp;字段名&amp;nbsp;like&amp;nbsp;‘%字段值%‘&amp;nbsp;order&amp;nbsp;by&amp;nbsp;字段名&amp;nbsp;&amp;quot;&amp;nbsp;&amp;nbsp;
sql=&amp;quot;select&amp;nbsp;top&amp;nbsp;10&amp;nbsp;*&amp;nbsp;from&amp;nbsp;数据表&amp;nbsp;where&amp;nbsp;字段名&amp;nbsp;order&amp;nbsp;by&amp;nbsp;字段名&amp;nbsp;&amp;quot;&amp;nbsp;&amp;nbsp;
sql=&amp;quot;select&amp;nbsp;*&amp;nbsp;from&amp;nbsp;数据表&amp;nbsp;where&amp;nbsp;字段名&amp;nbsp;in&amp;nbsp;(‘值1‘,‘值2‘,‘值3‘)&amp;quot;&amp;nbsp;&amp;nbsp;
sql=&amp;quot;select&amp;nbsp;*&amp;nbsp;from&amp;nbsp;数据表&amp;nbsp;where&amp;nbsp;字段名&amp;nbsp;between&amp;nbsp;值1&amp;nbsp;and&amp;nbsp;值2&amp;quot;&amp;nbsp;&amp;nbsp;
更新数据记录：&amp;nbsp;sql=&amp;quot;update&amp;nbsp;数据表&amp;nbsp;set&amp;nbsp;字段名=字段值&amp;nbsp;where&amp;nbsp;条件表达式&amp;quot;&amp;nbsp;&amp;nbsp;
sql=&amp;quot;update&amp;nbsp;数据表&amp;nbsp;set&amp;nbsp;字段1=值1,字段2=值2&amp;nbsp;……&amp;nbsp;字段n=值n&amp;nbsp;where&amp;nbsp;条件表达式&amp;quot;&amp;nbsp;&amp;nbsp;


删除数据记录：&amp;nbsp;sql=&amp;quot;delete&amp;nbsp;from&amp;nbsp;数据表&amp;nbsp;where&amp;nbsp;条件表达式&amp;quot;&amp;nbsp;&amp;nbsp;
sql=&amp;quot;delete&amp;nbsp;from&amp;nbsp;数据表&amp;quot;&amp;nbsp;(将数据表所有记录删除)&amp;nbsp;


添加数据记录：&amp;nbsp;sql=&amp;quot;insert&amp;nbsp;into&amp;nbsp;数据表&amp;nbsp;(字段1,字段2,字段3&amp;nbsp;…)&amp;nbsp;valuess&amp;nbsp;(值1,值2,值3&amp;nbsp;…)&amp;quot;&amp;nbsp;&amp;nbsp;
sql=&amp;quot;insert&amp;nbsp;into&amp;nbsp;目标数据表&amp;nbsp;select&amp;nbsp;*&amp;nbsp;from&amp;nbsp;源数据表&amp;quot;&amp;nbsp;(把源数据表的记录添加到目标数据表)&amp;nbsp;&amp;nbsp;
数据记录统计函数：&amp;nbsp;
AVG(字段名)&amp;nbsp;得出一个表格栏平均值&amp;nbsp;
COUNT(*|字段名)&amp;nbsp;对数据行数的统计或对某一栏有值的数据行数统计&amp;nbsp;
MAX(字段名)&amp;nbsp;取得一个表格栏最大的值&amp;nbsp;
MIN(字段名)&amp;nbsp;取得一个表格栏最小的值&amp;nbsp;
SUM(字段名)&amp;nbsp;把数据栏的值相加&amp;nbsp;

引用以上函数的方法：&amp;nbsp;sql=&amp;quot;select&amp;nbsp;sum(字段名)&amp;nbsp;as&amp;nbsp;别名&amp;nbsp;from&amp;nbsp;数据表&amp;nbsp;where&amp;nbsp;条件表达式&amp;quot;&amp;nbsp;&amp;nbsp;
set&amp;nbsp;rs=conn.excute(sql)&amp;nbsp;&amp;nbsp;
用&amp;nbsp;rs(&amp;quot;别名&amp;quot;)&amp;nbsp;获取统的计值，其它函数运用同上。&amp;nbsp;

数据表的建立和删除：&amp;nbsp;Create&amp;nbsp;TABLE&amp;nbsp;数据表名称(字段1&amp;nbsp;类型1(长度),字段2&amp;nbsp;类型2(长度)&amp;nbsp;……&amp;nbsp;)&amp;nbsp;&amp;nbsp;
例：Create&amp;nbsp;TABLE&amp;nbsp;tab01(name&amp;nbsp;varchar(50),datetime&amp;nbsp;default&amp;nbsp;now())&amp;nbsp;&amp;nbsp;
Drop&amp;nbsp;TABLE&amp;nbsp;数据表名称&amp;nbsp;(永久性删除一个数据表)&amp;nbsp;&amp;nbsp;

记录集对象的方法：&amp;nbsp;&amp;nbsp;&amp;nbsp;
rs.movenext&amp;nbsp;将记录指针从当前的位置向下移一行&amp;nbsp;&amp;nbsp;
rs.moveprevious&amp;nbsp;将记录指针从当前的位置向上移一行&amp;nbsp;&amp;nbsp;
rs.movefirst&amp;nbsp;将记录指针移到数据表第一行&amp;nbsp;&amp;nbsp;
rs.movelast&amp;nbsp;将记录指针移到数据表最后一行&amp;nbsp;&amp;nbsp;
rs.absoluteposition=N&amp;nbsp;将记录指针移到数据表第N行&amp;nbsp;&amp;nbsp;
rs.absolutepage=N&amp;nbsp;将记录指针移到第N页的第一行&amp;nbsp;&amp;nbsp;
rs.pagesize=N&amp;nbsp;设置每页为N条记录&amp;nbsp;&amp;nbsp;
rs.pagecount&amp;nbsp;根据&amp;nbsp;pagesize&amp;nbsp;的设置返回总页数&amp;nbsp;&amp;nbsp;
rs.recordcount&amp;nbsp;返回记录总数&amp;nbsp;&amp;nbsp;
rs.bof&amp;nbsp;返回记录指针是否超出数据表首端，true表示是，false为否&amp;nbsp;&amp;nbsp;
rs.eof&amp;nbsp;返回记录指针是否超出数据表末端，true表示是，false为否&amp;nbsp;&amp;nbsp;
rs.delete&amp;nbsp;删除当前记录，但记录指针不会向下移动&amp;nbsp;&amp;nbsp;
rs.addnew&amp;nbsp;添加记录到数据表末端&amp;nbsp;&amp;nbsp;
rs.update&amp;nbsp;更新数据表记录&amp;nbsp;&amp;nbsp;

判断所填数据是数字型&amp;nbsp;
if&amp;nbsp;not&amp;nbsp;isNumeric(request(&amp;quot;字段名称&amp;quot;))&amp;nbsp;then&amp;nbsp;&amp;nbsp;
response.write&amp;nbsp;&amp;quot;不是数字&amp;quot;&amp;nbsp;&amp;nbsp;
else&amp;nbsp;&amp;nbsp;
response.write&amp;nbsp;&amp;quot;数字&amp;quot;&amp;nbsp;&amp;nbsp;
end&amp;nbsp;if&amp;nbsp;
页面执行时间：


&amp;lt;%startime&amp;nbsp;=&amp;nbsp;Timer()%&amp;gt;&amp;nbsp;
....&amp;nbsp;....&amp;nbsp;
内容&amp;nbsp;
...&amp;nbsp;...&amp;nbsp;
结尾&amp;nbsp;
&amp;lt;%&amp;nbsp;
&amp;nbsp;&amp;nbsp;&amp;nbsp;Dim&amp;nbsp;Endtime&amp;nbsp;
&amp;nbsp;&amp;nbsp;&amp;nbsp;Endtime&amp;nbsp;=&amp;nbsp;Timer()&amp;nbsp;&amp;nbsp;
&amp;nbsp;&amp;nbsp;&amp;nbsp;response.write&amp;nbsp;&amp;quot;页面执行时间：&amp;lt;font&amp;nbsp;color=red&amp;gt;&amp;quot;&amp;amp;FormatNumber((Endtime-Startime)*1000,5)&amp;amp;&amp;quot;&amp;lt;/font&amp;gt;&amp;nbsp;毫秒&amp;quot;&amp;nbsp;
%&amp;gt;&amp;nbsp;
定义打开网页时起始窗口的大小
&amp;lt;script&amp;nbsp;for=&amp;quot;window&amp;quot;&amp;nbsp;event=&amp;quot;onload&amp;quot;&amp;gt;&amp;nbsp;
window.resizeTo(500,300)&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;


随机数:
&amp;lt;%randomize%&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;%=(int(rnd()*n)+1)%&amp;gt;&amp;nbsp;


查询数据时得到的记录关键字用红色显示：
replace(RS(&amp;quot;字段X&amp;quot;),searchname,&amp;quot;&amp;lt;font&amp;nbsp;color=#FF0000&amp;gt;&amp;quot;&amp;nbsp;&amp;amp;&amp;nbsp;searchname&amp;nbsp;&amp;amp;&amp;nbsp;&amp;quot;&amp;lt;/font&amp;gt;&amp;quot;)&amp;nbsp;&amp;nbsp;


通过asp的手段来检查来访者是否用了代理
&amp;lt;%&amp;nbsp;if&amp;nbsp;Request.ServerVariables(&amp;quot;HTTP_X_FORWARDED_FOR&amp;quot;)&amp;lt;&amp;gt;&amp;quot;&amp;quot;&amp;nbsp;then&amp;nbsp;&amp;nbsp;
response.write&amp;nbsp;&amp;quot;&amp;lt;font&amp;nbsp;color=#FF0000&amp;gt;您通过了代理服务器，&amp;quot;&amp;amp;&amp;nbsp;_&amp;nbsp;&amp;nbsp;
&amp;quot;真实的IP为&amp;quot;&amp;amp;Request.ServerVariables(&amp;quot;HTTP_X_FORWARDED_FOR&amp;quot;)&amp;nbsp;&amp;nbsp;
end&amp;nbsp;if&amp;nbsp;&amp;nbsp;
%&amp;gt;&amp;nbsp;&amp;nbsp;

判断上一页的来源
request.servervariables(&amp;quot;HTTP_REFERER&amp;quot;)&amp;nbsp;&amp;nbsp;
javascript:&amp;nbsp;document.referrer&amp;nbsp;



清除缓存，重新加载页面
&amp;lt;%response.expires&amp;nbsp;=&amp;nbsp;0&amp;nbsp;&amp;nbsp;&amp;nbsp;
response.expiresabsolute&amp;nbsp;=&amp;nbsp;now()&amp;nbsp;-&amp;nbsp;1&amp;nbsp;&amp;nbsp;
response.addHeader&amp;nbsp;&amp;quot;pragma&amp;quot;,&amp;quot;no-cache&amp;quot;&amp;nbsp;&amp;nbsp;
response.addHeader&amp;nbsp;&amp;quot;cache-control&amp;quot;,&amp;quot;private&amp;quot;&amp;nbsp;&amp;nbsp;
Response.cachecontrol&amp;nbsp;=&amp;nbsp;&amp;quot;no-cache&amp;quot;&amp;nbsp;&amp;nbsp;
%&amp;gt;&amp;nbsp;


检索并删除数据库里的重复记录
conn.execute(&amp;quot;delete&amp;nbsp;from&amp;nbsp;table&amp;nbsp;where&amp;nbsp;id&amp;nbsp;not&amp;nbsp;in&amp;nbsp;(select&amp;nbsp;distinct&amp;nbsp;from&amp;nbsp;table)&amp;quot;)&amp;nbsp;

文件删除函数&amp;nbsp;&amp;lt;%&amp;nbsp;&amp;nbsp;
&amp;#39;文件删除函数&amp;nbsp;&amp;nbsp;
function&amp;nbsp;deletefile(filename)&amp;nbsp;&amp;nbsp;
if&amp;nbsp;filename&amp;lt;&amp;gt;&amp;quot;&amp;quot;&amp;nbsp;then&amp;nbsp;&amp;nbsp;
set&amp;nbsp;fso=server.CreateObject(&amp;quot;scripting.filesystemobject&amp;quot;)&amp;nbsp;&amp;nbsp;
if&amp;nbsp;fso.FileExists(filename)&amp;nbsp;then&amp;nbsp;&amp;nbsp;
fso.DeleteFile&amp;nbsp;filename&amp;nbsp;&amp;nbsp;
else&amp;nbsp;&amp;nbsp;
Response.Write&amp;nbsp;&amp;quot;&amp;lt;script&amp;gt;alert(’该文件不存在’);&amp;lt;/script&amp;gt;&amp;quot;&amp;nbsp;&amp;nbsp;
end&amp;nbsp;if&amp;nbsp;&amp;nbsp;
end&amp;nbsp;if&amp;nbsp;&amp;nbsp;
end&amp;nbsp;function&amp;nbsp;&amp;nbsp;

strfile=server.MapPath(&amp;quot;fileName&amp;quot;)&amp;nbsp;&amp;nbsp;
deletefile(strfile)&amp;nbsp;&amp;nbsp;
%&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;

ASP字数计算函数&amp;nbsp;&amp;nbsp;&amp;lt;%&amp;nbsp;&amp;nbsp;
Function&amp;nbsp;WordCount(strInput)&amp;nbsp;&amp;nbsp;
Dim&amp;nbsp;strTemp&amp;nbsp;&amp;nbsp;
strTemp&amp;nbsp;=&amp;nbsp;Replace(strInput,&amp;nbsp;vbTab,&amp;nbsp;&amp;quot;&amp;nbsp;&amp;quot;)&amp;nbsp;&amp;nbsp;
strTemp&amp;nbsp;=&amp;nbsp;Replace(strTemp,&amp;nbsp;vbCr,&amp;nbsp;&amp;quot;&amp;nbsp;&amp;quot;)&amp;nbsp;&amp;nbsp;
strTemp&amp;nbsp;=&amp;nbsp;Replace(strTemp,&amp;nbsp;vbLf,&amp;nbsp;&amp;quot;&amp;nbsp;&amp;quot;)&amp;nbsp;&amp;nbsp;

&amp;#39;&amp;nbsp;删除字首字尾空格&amp;nbsp;&amp;nbsp;
strTemp&amp;nbsp;=&amp;nbsp;Trim(strTemp)&amp;nbsp;&amp;nbsp;

&amp;#39;&amp;nbsp;替换为一个空格&amp;nbsp;&amp;nbsp;
Do&amp;nbsp;While&amp;nbsp;InStr(1,&amp;nbsp;strTemp,&amp;nbsp;&amp;quot;&amp;nbsp;&amp;quot;,&amp;nbsp;1)&amp;nbsp;&amp;lt;&amp;gt;&amp;nbsp;0&amp;nbsp;&amp;nbsp;
strTemp&amp;nbsp;=&amp;nbsp;Replace(strTemp,&amp;nbsp;&amp;quot;&amp;nbsp;&amp;quot;,&amp;nbsp;&amp;quot;&amp;nbsp;&amp;quot;)&amp;nbsp;&amp;nbsp;
Loop&amp;nbsp;&amp;nbsp;
WordCount&amp;nbsp;=&amp;nbsp;UBound(Split(strTemp,&amp;nbsp;&amp;quot;&amp;nbsp;&amp;quot;,&amp;nbsp;-1,&amp;nbsp;1))&amp;nbsp;+1&amp;nbsp;&amp;nbsp;
End&amp;nbsp;Function&amp;nbsp;&amp;nbsp;
%&amp;gt;&amp;nbsp;
全正则的检测IP是否合法的函数&amp;nbsp;function&amp;nbsp;checkIP2(sIPAddress)
{
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var&amp;nbsp;exp=/^(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])\.(\d{1,2}|1\d\d|2[0-4]\d|25[0-5])$/;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var&amp;nbsp;reg&amp;nbsp;=&amp;nbsp;sIPAddress.match(exp);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var&amp;nbsp;ErrMsg=&amp;quot;你输入的是一个非法的IP地址段！\nIP段为：:xxx.xxx.xxx.xxx（xxx为0-255)！&amp;quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var&amp;nbsp;Msg=&amp;quot;你输入的是一个合法的IP地址段！&amp;quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;if(reg==null)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;alert(ErrMsg);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;else
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;{
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;alert(reg);
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}
}


关闭子窗口时刷新父窗口&amp;nbsp;在子窗口
&amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;gt;
window.opener.location=&amp;quot;父窗口页面&amp;quot;
window.close()
&amp;lt;/script&amp;gt;&amp;nbsp;
不能点右键，不用CTRL+A，不能复制作!
&amp;lt;body&amp;nbsp;oncontextmenu=&amp;quot;window.event.returnValue=false&amp;quot;&amp;nbsp;&amp;nbsp;
onkeypress=&amp;quot;window.event.returnValue=false&amp;quot;&amp;nbsp;&amp;nbsp;
onkeydown=&amp;quot;window.event.returnValue=false&amp;quot;&amp;nbsp;&amp;nbsp;
onkeyup=&amp;quot;window.event.returnValue=false&amp;quot;&amp;nbsp;&amp;nbsp;
ondragstart=&amp;quot;window.event.returnValue=false&amp;quot;&amp;nbsp;&amp;nbsp;
onselectstart=&amp;quot;event.returnValue=false&amp;quot;&amp;gt;&amp;nbsp;
&amp;lt;/body&amp;gt;&amp;nbsp;

显示状态拦固定文字：
放在body前&amp;nbsp;
&amp;lt;base&amp;nbsp;onmouseover=&amp;quot;window.status=&amp;#39;这里是Goaler的Blog系统，欢迎访问&amp;#39;;return&amp;nbsp;true&amp;quot;&amp;gt;&amp;nbsp;

用键盘打开网页&amp;nbsp;&amp;lt;script&amp;nbsp;language=javascript&amp;gt;
document.onkeydown=gopage
var&amp;nbsp;add=&amp;quot;Admin/AddArticle.asp&amp;quot;
var&amp;nbsp;logon=&amp;quot;Admin/Logon.asp&amp;quot;
function&amp;nbsp;gopage()&amp;nbsp;{
if&amp;nbsp;(event.keyCode==13)&amp;nbsp;location=add
if&amp;nbsp;(event.keyCode==38)&amp;nbsp;location=logon
}
&amp;lt;/script&amp;gt;&amp;nbsp;


根据内容自动调整iframe高度&amp;nbsp;有时为了方便使用Iframe，但被潜入的页面长度不是固定的，显示滚动条不仅影响美观还对用户操作带来不便，自动调整高度可以解决这个问题。^_^

function&amp;nbsp;f_frameStyleResize(targObj)
{
var&amp;nbsp;targWin&amp;nbsp;=&amp;nbsp;targObj.parent.document.all[targObj.name];
if(targWin&amp;nbsp;!=&amp;nbsp;null)
{
&amp;nbsp;&amp;nbsp;var&amp;nbsp;HeightValue&amp;nbsp;=&amp;nbsp;targObj.document.body.scrollHeight
&amp;nbsp;&amp;nbsp;if(HeightValue&amp;nbsp;&amp;lt;&amp;nbsp;600){HeightValue&amp;nbsp;=&amp;nbsp;600}&amp;nbsp;//不小于600
&amp;nbsp;&amp;nbsp;targWin.style.pixelHeight&amp;nbsp;=&amp;nbsp;HeightValue;
}
}
function&amp;nbsp;f_iframeResize()
{
bLoadComplete&amp;nbsp;=&amp;nbsp;true;
f_frameStyleResize(self);
}

var&amp;nbsp;bLoadComplete&amp;nbsp;=&amp;nbsp;false;
window.onload&amp;nbsp;=&amp;nbsp;f_iframeResize;

禁止页面正文内容被选取&amp;nbsp;

&amp;lt;body&amp;nbsp;oncontextmenu=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;ondragstart=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;onselectstart&amp;nbsp;=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;onselect=&amp;quot;document.selection.empty()&amp;quot;&amp;nbsp;oncopy=&amp;quot;document.selection.empty()&amp;quot;&amp;nbsp;onbeforecopy=&amp;quot;return&amp;nbsp;&amp;nbsp;
false&amp;quot;onmouseup=&amp;quot;document.selection.empty()&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

消除ie6自动出现的图像工具栏，设置&amp;nbsp;GALLERYIMG属性为false或no&amp;nbsp;.&amp;nbsp;

&amp;lt;IMG&amp;nbsp;SRC=&amp;quot;mypicture.jpg&amp;quot;&amp;nbsp;HEIGHT=&amp;quot;100px&amp;quot;&amp;nbsp;WIDTH=&amp;quot;100px&amp;quot;&amp;nbsp;GALLERYIMG=&amp;quot;no&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

防止点击空链接时，页面往往重置到页首端。&amp;nbsp;

代码“javascript:void(null)”代替原来的“#”标记&amp;nbsp;&amp;nbsp;

如何避免别人把你的网页放在框架中

&amp;lt;script&amp;nbsp;language=“javascript”&amp;gt;&amp;lt;!--if&amp;nbsp;(self!=top){top.location=self.location;}&amp;nbsp;--&amp;gt;&amp;lt;&amp;nbsp;/script&amp;gt;&amp;nbsp;

页面定时刷新&amp;nbsp;

&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;Refresh&amp;quot;&amp;nbsp;content=&amp;quot;秒&amp;quot;&amp;nbsp;&amp;gt;&amp;nbsp;

页面定时转向新的地址&amp;nbsp;

&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;refresh&amp;quot;&amp;nbsp;content=&amp;quot;秒;URL=url&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

关闭窗口，这个是不会弹出提示直接关的：&amp;nbsp;
把如下代码加入&amp;lt;body&amp;gt;区域中&amp;nbsp;

&amp;lt;OBJECT&amp;nbsp;id=closes&amp;nbsp;type=&amp;quot;application/x-oleobject&amp;quot;&amp;nbsp;classid=&amp;quot;clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;param&amp;nbsp;name=&amp;quot;Command&amp;quot;&amp;nbsp;value=&amp;quot;Close&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/object&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;script&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;function&amp;nbsp;shutwin(){closes.Click();return;}&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;a&amp;nbsp;href=&amp;quot;javascript:shutwin();&amp;quot;&amp;gt;关闭本窗口&amp;lt;/a&amp;gt;&amp;nbsp;&amp;nbsp;

有时候好不容易写出来的程序代码被别人抄去，心里一定不好受。这还是小事，但如果在我们的源代码中有一些不希望让别人知道的内容，比如密码、Action的指向等，这些一旦被人利用，那后果有时是不堪设想的。而网页加密就是我们现在需要解决的问题。下面就我在网页制作中的一些经验向大家介绍一些简单的防范方法。&amp;nbsp;
禁止右键&amp;nbsp;
看到这里大家一定会想，这招有很多人介绍过了，而且破解的方法也有很多。但我这里要说的是另一种方法，而且我试了很多方法都没有能破解。具体如下：&amp;nbsp;

&amp;lt;html&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;head&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;script&amp;gt;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;stop(){&amp;nbsp;&amp;nbsp;
alert(&amp;quot;试试能破解吗？&amp;quot;);&amp;nbsp;&amp;nbsp;
return&amp;nbsp;false;&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;
document.oncontextmenu=stop;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;boyd&amp;gt;你可以按右键、shift+F10和右ctrl左边的那个键试试！看能不能解。^_^&amp;lt;/body&amp;gt;&amp;nbsp;&amp;nbsp;


大家试试，看能不能破解！你可以将alert(&amp;quot;试试能破解吗？&amp;quot;);这句去掉，这样当按右键时就什么反应也没有了，就好像没有右键功能一样。&amp;nbsp;

禁示查看源代码&amp;nbsp;
我们已经禁了右键，但从&amp;quot;查看&amp;quot;菜单下的&amp;quot;源文件&amp;quot;中同样可以看到源代码，下面我们就来解决这个问题：&amp;nbsp;
其实这只要使用一个含有&amp;lt;frame&amp;gt;&amp;lt;/frame&amp;gt;标记的网页便可以达到目的。&amp;nbsp;


&amp;lt;frameset&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;frame&amp;nbsp;src=&amp;quot;你要保密的文件的URL&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/frameset&amp;gt;&amp;nbsp;&amp;nbsp;


这样当有人使用&amp;quot;查看&amp;quot;下的&amp;quot;源文件&amp;quot;的时候，看到的将是上面的那段代码，而你真正的文件又躲过一劫。&amp;nbsp;

禁示另存为&amp;nbsp;
通过上面的两步好像你的源代码已经安全了，但别忘了，别人还可以将你的页面保存下来，再慢慢分析。不过别担心，下面我们来解决这个问题。&amp;nbsp;
在你要保密的网页中加入以下代码：&amp;nbsp;

&amp;lt;noscript&amp;gt;&amp;lt;iframe&amp;nbsp;src=&amp;quot;*.htm&amp;quot;&amp;gt;&amp;lt;/iframe&amp;gt;&amp;lt;/noscript&amp;gt;

彻底屏蔽右键方法。

&amp;lt;body&amp;nbsp;oncontextmenu=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;gt;&amp;nbsp;

双击页面后自动滚屏，单击后停止。

&amp;lt;SCRIPT&amp;nbsp;language=JavaScript&amp;gt;&amp;nbsp;&amp;nbsp;
var&amp;nbsp;currentpos,timer;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;initialize()&amp;nbsp;&amp;nbsp;
{&amp;nbsp;timer=setInterval(&amp;quot;scrollwindow()&amp;quot;,16);&amp;nbsp;}&amp;nbsp;&amp;nbsp;
function&amp;nbsp;sc(){&amp;nbsp;&amp;nbsp;
clearInterval(timer);&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;
function&amp;nbsp;scrollwindow()&amp;nbsp;&amp;nbsp;
{currentpos=document.body.scrollTop;&amp;nbsp;&amp;nbsp;
window.scroll(0,++currentpos);&amp;nbsp;&amp;nbsp;
if&amp;nbsp;(currentpos&amp;nbsp;!=&amp;nbsp;document.body.scrollTop)&amp;nbsp;&amp;nbsp;
sc();&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;
document.onmousedown=sc&amp;nbsp;&amp;nbsp;
document.ondblclick=initialize&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;

设定脚本出错能继续运行


&amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;gt;&amp;nbsp;
function&amp;nbsp;KillError()&amp;nbsp;
{&amp;nbsp;
return&amp;nbsp;false;&amp;nbsp;
}&amp;nbsp;
window.onerror=KillError;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;
　

将彻底屏蔽鼠标右键

oncontextmenu=&amp;quot;window.event.returnvalue=false&amp;quot;&amp;nbsp;

可用于Table&amp;nbsp;

&amp;lt;table&amp;nbsp;border&amp;nbsp;oncontextmenu=return(false)&amp;gt;&amp;lt;td&amp;gt;no&amp;lt;/table&amp;gt;&amp;nbsp;&amp;nbsp;

取消选取、防止复制

&amp;lt;body&amp;nbsp;onselectstart=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;gt;&amp;nbsp;

不准粘贴&amp;nbsp;

onpaste=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;&amp;nbsp;

防止复制

oncopy=&amp;quot;return&amp;nbsp;false;&amp;quot;&amp;nbsp;oncut=&amp;quot;return&amp;nbsp;false;&amp;quot;&amp;nbsp;&amp;nbsp;

IE地址栏前换成自己的图标&amp;nbsp;

&amp;lt;link&amp;nbsp;rel=&amp;quot;Shortcut&amp;nbsp;Icon&amp;quot;&amp;nbsp;href=&amp;quot;favicon.ico&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

可以在收藏夹中显示出你的图标&amp;nbsp;

&amp;lt;link&amp;nbsp;rel=&amp;quot;Bookmark&amp;quot;&amp;nbsp;href=&amp;quot;favicon.ico&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;


关闭输入法

&amp;lt;input&amp;nbsp;style=&amp;quot;ime-mode:disabled&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;


永远都会带着框架&amp;nbsp;


&amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;gt;&amp;lt;!--&amp;nbsp;&amp;nbsp;
if&amp;nbsp;(window&amp;nbsp;==&amp;nbsp;top)top.location.href&amp;nbsp;=&amp;nbsp;&amp;quot;frames.htm&amp;quot;;&amp;nbsp;&amp;nbsp;
//frames.htm为框架网页&amp;nbsp;&amp;nbsp;
//&amp;nbsp;--&amp;gt;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;

防止被人frame&amp;nbsp;

&amp;lt;SCRIPT&amp;nbsp;LANGUAGE=javascript&amp;gt;&amp;lt;!--&amp;nbsp;&amp;nbsp;
if&amp;nbsp;(top.location&amp;nbsp;!=&amp;nbsp;self.location)&amp;nbsp;
top.location=self.location;&amp;nbsp;&amp;nbsp;
//&amp;nbsp;--&amp;gt;&amp;nbsp;
&amp;lt;/SCRIPT&amp;gt;&amp;nbsp;&amp;nbsp;

怎样通过asp的手段来检查来访者是否用了代理&amp;nbsp;

&amp;lt;%&amp;nbsp;if&amp;nbsp;Request.ServerVariables(&amp;quot;HTTP_X_FORWARDED_FOR&amp;quot;)&amp;lt;&amp;gt;&amp;quot;&amp;quot;&amp;nbsp;then&amp;nbsp;&amp;nbsp;
response.write&amp;nbsp;&amp;quot;&amp;lt;font&amp;nbsp;color=#FF0000&amp;gt;您通过了代理服务器，&amp;quot;&amp;nbsp;&amp;amp;&amp;nbsp;&amp;quot;真实的IP为&amp;nbsp;&amp;quot;&amp;amp;Request.ServerVariables(&amp;quot;HTTP_X_FORWARDED_FOR&amp;quot;)&amp;nbsp;&amp;nbsp;
end&amp;nbsp;if&amp;nbsp;&amp;nbsp;
%&amp;gt;&amp;nbsp;&amp;nbsp;

取得控件的绝对位置&amp;nbsp;

//javascript&amp;nbsp;&amp;nbsp;
&amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;getIE(e){&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
var&amp;nbsp;t=e.offsetTop;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
var&amp;nbsp;l=e.offsetLeft;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
while(e=e.offsetParent){&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
t+=e.offsetTop;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
l+=e.offsetLeft;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
alert(&amp;quot;top=&amp;quot;+t+&amp;quot;nleft=&amp;quot;+l);&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;

//VBScript&amp;nbsp;&amp;nbsp;
&amp;lt;script&amp;nbsp;language=&amp;quot;VBScript&amp;quot;&amp;gt;
&amp;lt;!--&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;getIE()&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
dim&amp;nbsp;t,l,a,b&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
set&amp;nbsp;a=document.all.img1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
t=document.all.img1.offsetTop&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
l=document.all.img1.offsetLeft&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
while&amp;nbsp;a.tagName&amp;lt;&amp;gt;&amp;quot;BODY&amp;quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
set&amp;nbsp;a&amp;nbsp;=&amp;nbsp;a.offsetParent&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
t=t+a.offsetTop&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
l=l+a.offsetLeft&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
wend&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
msgbox&amp;nbsp;&amp;quot;top=&amp;quot;&amp;amp;t&amp;amp;chr(13)&amp;amp;&amp;quot;left=&amp;quot;&amp;amp;l,64,&amp;quot;得到控件的位置&amp;quot;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
end&amp;nbsp;function&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
--&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;

光标是停在文本框文字的最后&amp;nbsp;

&amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;cc()&amp;nbsp;&amp;nbsp;
{&amp;nbsp;&amp;nbsp;
var&amp;nbsp;e&amp;nbsp;=&amp;nbsp;event.srcElement;&amp;nbsp;&amp;nbsp;
var&amp;nbsp;r&amp;nbsp;=e.createTextRange();&amp;nbsp;&amp;nbsp;
r.moveStart(&amp;#39;character&amp;#39;,e.value.length);&amp;nbsp;&amp;nbsp;
r.collapse(true);&amp;nbsp;&amp;nbsp;
r.select();&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;input&amp;nbsp;type=text&amp;nbsp;name=text1&amp;nbsp;value=&amp;quot;123&amp;quot;&amp;nbsp;onfocus=&amp;quot;cc()&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

判断上一页的来源&amp;nbsp;

asp:&amp;nbsp;&amp;nbsp;
request.servervariables(&amp;quot;HTTP_REFERER&amp;quot;)&amp;nbsp;&amp;nbsp;&amp;nbsp;

javascript:&amp;nbsp;&amp;nbsp;
document.referrer&amp;nbsp;

最小化、最大化、关闭窗口&amp;nbsp;

&amp;lt;object&amp;nbsp;id=hh1&amp;nbsp;classid=&amp;quot;clsid:ADB880A6-D8FF-11CF-9377-00AA003B7A11&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;param&amp;nbsp;name=&amp;quot;Command&amp;quot;&amp;nbsp;value=&amp;quot;Minimize&amp;quot;&amp;gt;&amp;lt;/object&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;object&amp;nbsp;id=hh2&amp;nbsp;classid=&amp;quot;clsid:ADB880A6-D8FF-11CF-9377-00AA003B7A11&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;param&amp;nbsp;name=&amp;quot;Command&amp;quot;&amp;nbsp;value=&amp;quot;Maximize&amp;quot;&amp;gt;&amp;lt;/object&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;OBJECT&amp;nbsp;id=hh3&amp;nbsp;classid=&amp;quot;clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;PARAM&amp;nbsp;NAME=&amp;quot;Command&amp;quot;&amp;nbsp;value=&amp;quot;Close&amp;quot;&amp;gt;&amp;lt;/OBJECT&amp;gt;&amp;nbsp;&amp;nbsp;

&amp;lt;input&amp;nbsp;type=button&amp;nbsp;value=最小化&amp;nbsp;onclick=hh1.Click()&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;input&amp;nbsp;type=button&amp;nbsp;value=最大化&amp;nbsp;onclick=hh2.Click()&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;input&amp;nbsp;type=button&amp;nbsp;value=关闭&amp;nbsp;onclick=hh3.Click()&amp;gt;&amp;nbsp;&amp;nbsp;
本例适用于IE&amp;nbsp;

记录并显示网页的最后修改时间&amp;nbsp;

&amp;lt;script&amp;nbsp;language=JavaScript&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;
document.write(&amp;quot;最后更新时间:&amp;nbsp;&amp;quot;&amp;nbsp;+&amp;nbsp;document.lastModified&amp;nbsp;+&amp;nbsp;&amp;quot;&amp;quot;)&amp;nbsp;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;

2秒后关闭当前页

&amp;lt;script&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;!--&amp;nbsp;&amp;nbsp;
setTimeout(&amp;#39;window.close();&amp;#39;,2000);&amp;nbsp;&amp;nbsp;
--&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;

2秒后载入指定网页

&amp;lt;head&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;refresh&amp;quot;&amp;nbsp;content=&amp;quot;2;URL=http://你的网址&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/head&amp;gt;&amp;nbsp;&amp;nbsp;

添加到收藏夹

&amp;lt;Script&amp;nbsp;Language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;bookmarkit()&amp;nbsp;&amp;nbsp;
{&amp;nbsp;&amp;nbsp;
　window.external.addFavorite(&amp;#39;http://你的网址&amp;#39;,&amp;#39;你的网站名称&amp;#39;)&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;
　if&amp;nbsp;(document.all)document.write(&amp;#39;&amp;lt;a&amp;nbsp;href=&amp;quot;#&amp;quot;&amp;nbsp;onClick=&amp;quot;bookmarkit()&amp;quot;&amp;gt;加入收藏夹&amp;lt;/a&amp;gt;&amp;#39;)&amp;nbsp;&amp;nbsp;
&amp;lt;/Script&amp;gt;&amp;nbsp;

禁止鼠标右键的动作

&amp;lt;Script&amp;nbsp;Language&amp;nbsp;=&amp;nbsp;&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;click()&amp;nbsp;{&amp;nbsp;if&amp;nbsp;(event.button==2||event.button==3)&amp;nbsp;&amp;nbsp;
{&amp;nbsp;&amp;nbsp;
　alert(&amp;#39;禁止鼠标右键&amp;#39;);&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;
&amp;nbsp;&amp;nbsp;&amp;nbsp;document.onmousedown=click&amp;nbsp;//&amp;nbsp;--&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/Script&amp;gt;&amp;nbsp;

或

&amp;lt;script&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;click()&amp;nbsp;{&amp;nbsp;if&amp;nbsp;(event.button==2)&amp;nbsp;&amp;nbsp;
{alert(&amp;#39;*^_^*&amp;#39;);&amp;nbsp;}&amp;nbsp;}&amp;nbsp;document.onmousedown=click&amp;nbsp;//&amp;nbsp;--&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;

设置该页为首页

&amp;lt;body&amp;nbsp;bgcolor=&amp;quot;#FFFFFF&amp;quot;&amp;nbsp;text=&amp;quot;#000000&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;a&amp;nbsp;class=&amp;quot;chlnk&amp;quot;&amp;nbsp;style=&amp;quot;cursor:hand&amp;quot;&amp;nbsp;HREF&amp;nbsp;&amp;nbsp;onClick=&amp;quot;this.style.behavior=&amp;#39;url(#default#homepage)&amp;#39;;&amp;nbsp;&amp;nbsp;this.setHomePage(&amp;#39;你的网站名称);&amp;quot;&amp;gt;&amp;lt;font&amp;nbsp;color=&amp;quot;000000&amp;quot;&amp;nbsp;size=&amp;quot;2&amp;quot;&amp;nbsp;face=&amp;quot;宋体&amp;quot;&amp;gt;设为首页&amp;lt;/font&amp;gt;&amp;lt;/a&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/body&amp;gt;&amp;nbsp;&amp;nbsp;

节日倒计时

&amp;lt;Script&amp;nbsp;Language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;timedate=&amp;nbsp;new&amp;nbsp;Date(&amp;quot;October&amp;nbsp;1,2002&amp;quot;);&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;times=&amp;quot;国庆节&amp;quot;;&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;now&amp;nbsp;=&amp;nbsp;new&amp;nbsp;Date();&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;date&amp;nbsp;=&amp;nbsp;timedate.getTime()&amp;nbsp;-&amp;nbsp;now.getTime();&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;time&amp;nbsp;=&amp;nbsp;Math.floor(date&amp;nbsp;/&amp;nbsp;(1000&amp;nbsp;*&amp;nbsp;60&amp;nbsp;*&amp;nbsp;60&amp;nbsp;*&amp;nbsp;24));&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;(time&amp;nbsp;&amp;gt;=&amp;nbsp;0)&amp;nbsp;&amp;nbsp;
　　document.write(&amp;quot;现在离&amp;quot;+times+&amp;quot;还有:&amp;nbsp;&amp;quot;+time&amp;nbsp;+&amp;quot;天&amp;quot;)
&amp;lt;/Script&amp;gt;&amp;nbsp;&amp;nbsp;

单击按钮打印出当前页

&amp;lt;Script&amp;nbsp;Language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;(window.print)&amp;nbsp;{&amp;nbsp;&amp;nbsp;
　　document.write(&amp;#39;&amp;lt;form&amp;gt;&amp;#39;&amp;nbsp;&amp;nbsp;
　　+&amp;nbsp;&amp;#39;&amp;lt;input&amp;nbsp;type=button&amp;nbsp;name=print&amp;nbsp;value=&amp;quot;打印本页&amp;quot;&amp;nbsp;&amp;#39;&amp;nbsp;&amp;nbsp;
　　+&amp;nbsp;&amp;#39;onClick=&amp;quot;javascript:window.print()&amp;quot;&amp;gt;&amp;lt;/form&amp;gt;&amp;#39;);&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
&amp;lt;/Script&amp;gt;&amp;nbsp;&amp;nbsp;

单击按钮‘另存为’当前页

&amp;lt;input&amp;nbsp;type=&amp;quot;button&amp;quot;&amp;nbsp;name=&amp;quot;Button&amp;quot;&amp;nbsp;value=&amp;quot;保存本页&amp;quot;&amp;nbsp;&amp;nbsp;onClick=&amp;quot;document.all.button.ExecWB(4,1)&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;object&amp;nbsp;id=&amp;quot;button&amp;quot;&amp;nbsp;&amp;nbsp;width=0&amp;nbsp;&amp;nbsp;height=0&amp;nbsp;&amp;nbsp;classid=&amp;quot;CLSID:8856F961-340A-11D0-A96B-00C04FD705A2&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;embed&amp;nbsp;width=&amp;quot;0&amp;quot;&amp;nbsp;height=&amp;quot;0&amp;quot;&amp;gt;&amp;lt;/embed&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/object&amp;gt;&amp;nbsp;&amp;nbsp;

显示系统当前日期

&amp;lt;script&amp;nbsp;language=JavaScript&amp;gt;&amp;nbsp;&amp;nbsp;
　　today=new&amp;nbsp;Date();&amp;nbsp;&amp;nbsp;
　　function&amp;nbsp;date(){&amp;nbsp;&amp;nbsp;
　　this.length=date.arguments.length&amp;nbsp;&amp;nbsp;
　　for(var&amp;nbsp;i=0;i&amp;lt;this.length;i++)&amp;nbsp;&amp;nbsp;
　　this[i+1]=date.arguments&amp;nbsp;}&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;d=new&amp;nbsp;date(&amp;quot;星期日&amp;quot;,&amp;quot;星期一&amp;quot;,&amp;quot;星期二&amp;quot;,&amp;quot;星期三&amp;quot;,&amp;quot;星期四&amp;quot;,&amp;quot;星期五&amp;quot;,&amp;quot;星期六&amp;quot;);&amp;nbsp;&amp;nbsp;
　　document.write(&amp;nbsp;&amp;nbsp;
　　&amp;quot;&amp;lt;font&amp;nbsp;color=##000000&amp;nbsp;style=&amp;#39;font-size:9pt;font-family:&amp;nbsp;宋体&amp;#39;&amp;gt;&amp;nbsp;&amp;quot;,&amp;nbsp;&amp;nbsp;
　　today.getYear(),&amp;quot;年&amp;quot;,today.getMonth()+1,&amp;quot;月&amp;quot;,today.getDate(),&amp;quot;日&amp;quot;,&amp;nbsp;&amp;nbsp;
　　d[today.getDay()+1],&amp;quot;&amp;lt;/font&amp;gt;&amp;quot;&amp;nbsp;);&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;


不同时间段显示不同问候语&amp;nbsp;&amp;lt;Script&amp;nbsp;Language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
var&amp;nbsp;text=&amp;quot;&amp;quot;;&amp;nbsp;day&amp;nbsp;=&amp;nbsp;new&amp;nbsp;Date(&amp;nbsp;);&amp;nbsp;time&amp;nbsp;=&amp;nbsp;day.getHours(&amp;nbsp;);&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;((&amp;nbsp;time&amp;gt;=0)&amp;nbsp;&amp;amp;&amp;amp;&amp;nbsp;(time&amp;nbsp;&amp;lt;&amp;nbsp;7&amp;nbsp;))&amp;nbsp;&amp;nbsp;
　　　　text=&amp;quot;夜猫子，要注意身体哦！&amp;nbsp;&amp;quot;&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;((&amp;nbsp;time&amp;nbsp;&amp;gt;=&amp;nbsp;7&amp;nbsp;)&amp;nbsp;&amp;amp;&amp;amp;&amp;nbsp;(time&amp;nbsp;&amp;lt;&amp;nbsp;12))&amp;nbsp;&amp;nbsp;
　　　　text=&amp;quot;今天的阳光真灿烂啊，你那个朋友呢？&amp;quot;&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;((&amp;nbsp;time&amp;nbsp;&amp;gt;=&amp;nbsp;12)&amp;nbsp;&amp;amp;&amp;amp;&amp;nbsp;(time&amp;nbsp;&amp;lt;&amp;nbsp;14))&amp;nbsp;&amp;nbsp;
　　　　text=&amp;quot;午休时间。您要保持睡眠哦！&amp;quot;&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;((&amp;nbsp;time&amp;nbsp;&amp;gt;=14)&amp;nbsp;&amp;amp;&amp;amp;&amp;nbsp;(time&amp;nbsp;&amp;lt;&amp;nbsp;18))&amp;nbsp;&amp;nbsp;
　　　　text=&amp;quot;祝您下午工作愉快！&amp;nbsp;&amp;quot;&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;((time&amp;nbsp;&amp;gt;=&amp;nbsp;18)&amp;nbsp;&amp;amp;&amp;amp;&amp;nbsp;(time&amp;nbsp;&amp;lt;=&amp;nbsp;22))&amp;nbsp;&amp;nbsp;
　　　　text=&amp;quot;您又来了，可别和MM聊太久哦！&amp;quot;&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;((time&amp;nbsp;&amp;gt;=&amp;nbsp;22)&amp;nbsp;&amp;amp;&amp;amp;&amp;nbsp;(time&amp;nbsp;&amp;lt;&amp;nbsp;24))&amp;nbsp;&amp;nbsp;
　　　　text=&amp;quot;您应该休息了！&amp;quot;&amp;nbsp;&amp;nbsp;
　　document.write(text)&amp;nbsp;&amp;nbsp;
&amp;lt;/Script&amp;gt;&amp;nbsp;&amp;nbsp;

水中倒影效果&amp;nbsp;&amp;lt;img&amp;nbsp;id=&amp;quot;reflect&amp;quot;&amp;nbsp;src=&amp;quot;你自己的图片文件名&amp;quot;&amp;nbsp;width=&amp;quot;175&amp;quot;&amp;nbsp;height=&amp;quot;59&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;script&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　function&amp;nbsp;f1()&amp;nbsp;&amp;nbsp;
　　{&amp;nbsp;&amp;nbsp;
　　　　setInterval(&amp;quot;mdiv.filters.wave.phase+=10&amp;quot;,100);&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;(document.all)&amp;nbsp;&amp;nbsp;
　　{&amp;nbsp;&amp;nbsp;
　　　　document.write(&amp;#39;&amp;lt;img&amp;nbsp;id=mdiv&amp;nbsp;src=&amp;quot;&amp;#39;+document.all.reflect.src+&amp;#39;&amp;quot;&amp;nbsp;&amp;nbsp;
　　　　style=&amp;quot;filter:wave(strength=3,freq=3,phase=0,lightstrength=30)&amp;nbsp;blur()&amp;nbsp;flipv()&amp;quot;&amp;gt;&amp;#39;)&amp;nbsp;&amp;nbsp;
　　　　window.onload=f1&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;

慢慢变大的窗口&amp;nbsp;&amp;lt;Script&amp;nbsp;Language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;!--&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;Windowsheight=100&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;Windowswidth=100&amp;nbsp;&amp;nbsp;
　　var&amp;nbsp;numx=5&amp;nbsp;&amp;nbsp;
　　function&amp;nbsp;openwindow(thelocation){&amp;nbsp;&amp;nbsp;
　　temploc=thelocation&amp;amp;,&amp;nbsp;amp;,&amp;nbsp;nbsp;&amp;nbsp;
　　if&amp;nbsp;&amp;nbsp;
　　(!(window.resizeTo&amp;amp;&amp;amp;document.all)&amp;amp;&amp;amp;!(window.resizeTo&amp;amp;&amp;amp;document.getElementById))&amp;nbsp;&amp;nbsp;
　　{&amp;nbsp;&amp;nbsp;
　　　　window.open(thelocation)&amp;nbsp;&amp;nbsp;
　　　　return&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　windowsize=window.open(&amp;quot;&amp;quot;,&amp;quot;&amp;quot;,&amp;quot;scrollbars&amp;quot;)&amp;nbsp;&amp;nbsp;
　　windowsize.moveTo(0,0)&amp;nbsp;&amp;nbsp;
　　windowsize.resizeTo(100,100)&amp;nbsp;&amp;nbsp;
　　tenumxt()&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　function&amp;nbsp;tenumxt(){&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;(Windowsheight&amp;gt;=screen.availHeight-3)&amp;nbsp;&amp;nbsp;
　　　　numx=0&amp;nbsp;&amp;nbsp;
　　windowsize.resizeBy(5,numx)&amp;nbsp;&amp;nbsp;
　　Windowsheight+=5&amp;nbsp;&amp;nbsp;
　　Windowswidth+=5&amp;nbsp;&amp;nbsp;
　　if&amp;nbsp;(Windowswidth&amp;gt;=screen.width-5)&amp;nbsp;&amp;nbsp;
　　{&amp;nbsp;&amp;nbsp;
　　　　windowsize.location=temploc&amp;nbsp;&amp;nbsp;
　　　　Windowsheight=100&amp;nbsp;&amp;nbsp;
　　　　Windowswidth=100&amp;nbsp;&amp;nbsp;
　　　　numx=5&amp;nbsp;&amp;nbsp;
　　　　return&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　setTimeout(&amp;quot;tenumxt()&amp;quot;,50)&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　//--&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;a&amp;nbsp;href=&amp;quot;javascript:openwindow(&amp;#39;http://www.ccjol.com&amp;#39;)&amp;quot;&amp;gt;进入&amp;lt;/a&amp;gt;&amp;nbsp;


鼠标指向时弹出信息框&amp;nbsp;
在&amp;lt;body&amp;gt;&amp;lt;/body&amp;gt;之间加上如下代码：&amp;nbsp;&amp;lt;a&amp;nbsp;href&amp;nbsp;onmouseover=&amp;quot;alert(&amp;#39;弹出信息！&amp;#39;)&amp;quot;&amp;gt;显示的链接文字&amp;lt;/a&amp;gt;&amp;nbsp;&amp;nbsp;


随机变换背景图象（一个可以刷新心情的特效）&amp;nbsp;
在&amp;lt;head&amp;gt;&amp;lt;/head&amp;gt;之间加上如下代码：&amp;nbsp;&amp;nbsp;
&amp;lt;Script&amp;nbsp;Language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　image&amp;nbsp;=&amp;nbsp;new&amp;nbsp;Array(4);&amp;nbsp;//定义image为图片数量的数组&amp;nbsp;&amp;nbsp;
　　image&amp;nbsp;[0]&amp;nbsp;=&amp;nbsp;&amp;#39;tu0.gif&amp;#39;&amp;nbsp;//背景图象的路径&amp;nbsp;&amp;nbsp;
　　image&amp;nbsp;[1]&amp;nbsp;=&amp;nbsp;&amp;#39;tu1.gif&amp;#39;&amp;nbsp;&amp;nbsp;
　　image&amp;nbsp;[2]&amp;nbsp;=&amp;nbsp;&amp;#39;tu2.gif&amp;#39;&amp;nbsp;&amp;nbsp;
　　image&amp;nbsp;[3]&amp;nbsp;=&amp;nbsp;&amp;#39;tu3.gif&amp;#39;&amp;nbsp;&amp;nbsp;
　　image&amp;nbsp;[4]&amp;nbsp;=&amp;nbsp;&amp;#39;tu4.gif&amp;#39;&amp;nbsp;&amp;nbsp;
　　number&amp;nbsp;=&amp;nbsp;Math.floor(Math.random()&amp;nbsp;*&amp;nbsp;image.length);&amp;nbsp;&amp;nbsp;
　　document.write(&amp;quot;&amp;lt;BODY&amp;nbsp;BACKGROUND=&amp;quot;+image[number]+&amp;quot;&amp;gt;&amp;quot;);&amp;nbsp;&amp;nbsp;
&amp;lt;/Script&amp;gt;&amp;nbsp;&amp;nbsp;

鼠标一碰就给颜色看的链接&amp;nbsp;在&amp;lt;body&amp;gt;&amp;lt;/body&amp;gt;之间加上如下代码：&amp;nbsp;&amp;nbsp;
&amp;lt;p&amp;nbsp;onMouseMove=&amp;quot;anniu()&amp;quot;&amp;gt;你敢碰我，我就给点颜色你看！&amp;lt;/p&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;Script&amp;nbsp;Language&amp;nbsp;=&amp;nbsp;&amp;quot;VBScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　sub&amp;nbsp;anniu&amp;nbsp;&amp;nbsp;
　　document.fgColor=int(256*256*256*rnd)&amp;nbsp;&amp;nbsp;
　　end&amp;nbsp;sub&amp;nbsp;&amp;nbsp;
&amp;lt;/Script&amp;gt;&amp;nbsp;&amp;nbsp;

从天而降并有幻影效果的窗口&amp;nbsp;

　　&amp;lt;head&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;Script&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　function&amp;nbsp;move(x)&amp;nbsp;{&amp;nbsp;&amp;nbsp;
　　if(self.moveBy){&amp;nbsp;&amp;nbsp;
　　self.moveBy&amp;nbsp;(0,-800);&amp;nbsp;&amp;nbsp;
　　for(i&amp;nbsp;=&amp;nbsp;x;&amp;nbsp;i&amp;nbsp;&amp;gt;&amp;nbsp;0;&amp;nbsp;i--)&amp;nbsp;&amp;nbsp;
　　{&amp;nbsp;&amp;nbsp;
　　self.moveBy(0,3);&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　for(j&amp;nbsp;=&amp;nbsp;200;&amp;nbsp;j&amp;nbsp;&amp;gt;&amp;nbsp;0;&amp;nbsp;j--){&amp;nbsp;//如果你认为窗口抖动厉害，就200换成个位数&amp;nbsp;&amp;nbsp;
　　self.moveBy(0,j);&amp;nbsp;&amp;nbsp;
　　self.moveBy(j,0);&amp;nbsp;&amp;nbsp;
　　self.moveBy(0,-j);&amp;nbsp;&amp;nbsp;
　　self.moveBy(-j,0);&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　}&amp;nbsp;&amp;nbsp;
　　&amp;lt;/Scrip&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;body&amp;nbsp;bgColor=#ffffff&amp;nbsp;onload=move(280)&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;/body&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;/head&amp;gt;&amp;nbsp;&amp;nbsp;

表格的半透明显示效果&amp;nbsp;在&amp;lt;head&amp;gt;&amp;lt;/head&amp;gt;之间加上如下代码：&amp;nbsp;&amp;nbsp;
&amp;lt;style&amp;gt;&amp;nbsp;&amp;nbsp;
.alpha{filter:&amp;nbsp;Alpha(Opacity=50)}&amp;nbsp;//50表示50%的透明度&amp;nbsp;&amp;nbsp;
&amp;lt;/style&amp;gt;&amp;nbsp;&amp;nbsp;

在&amp;lt;body&amp;gt;&amp;lt;/body&amp;gt;之间加上如下代码：&amp;nbsp;&amp;nbsp;
&amp;lt;table&amp;nbsp;border=&amp;quot;1&amp;quot;&amp;nbsp;width=&amp;quot;100&amp;quot;&amp;nbsp;height=&amp;quot;62&amp;quot;&amp;nbsp;class=&amp;quot;alpha&amp;quot;&amp;nbsp;bgcolor=&amp;quot;#F2A664&amp;quot;&amp;nbsp;&amp;gt;&amp;nbsp;&amp;nbsp;
　&amp;lt;tr&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;td&amp;nbsp;width=&amp;quot;100%&amp;quot;&amp;nbsp;height=&amp;quot;62&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;div&amp;nbsp;align=&amp;quot;center&amp;quot;&amp;gt;很酷吧!&amp;lt;/div&amp;gt;&amp;nbsp;&amp;nbsp;
　　&amp;lt;/td&amp;gt;&amp;nbsp;&amp;nbsp;
　&amp;lt;/tr&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/table&amp;gt;&amp;nbsp;


锁定状态栏文字防止显示地址
&amp;lt;body&amp;nbsp;onmouseover=&amp;quot;self.status=&amp;#39;文字&amp;#39;;return&amp;nbsp;true&amp;quot;&amp;gt;&amp;nbsp;


禁止图片下载
在&amp;lt;body......&amp;gt;这里的最后加入：&amp;nbsp;
oncontextmenu=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;ondragstart=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;onselectstart=&amp;quot;return&amp;nbsp;false&amp;quot;&amp;nbsp;scroll=&amp;quot;auto&amp;quot;&amp;nbsp;

禁止缓存
&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;Expires&amp;quot;&amp;nbsp;CONTENT=&amp;quot;0&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;Cache-Control&amp;quot;&amp;nbsp;CONTENT=&amp;quot;no-cache&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;Pragma&amp;quot;&amp;nbsp;CONTENT=&amp;quot;no-cache&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
加在HEAD里&amp;nbsp;

使用包含页面
加密所包含页面地址，使用工具&amp;nbsp;htmlguardian5.3.5
目前功能最强的html代码加密软件,可以保护连接和html代码被盗。1.锁右键。2.禁鼠标圈选。3.不允许离线使用。4.密码保护。5.不显示状态栏url地址。6.全代码&amp;nbsp;或&amp;nbsp;局部代码保护。7.链接跟踪。8.禁止打印(IE5+)。9.压缩代码(&amp;nbsp;未加密前)。10.可加密*.html&amp;nbsp;*.js&amp;nbsp;*.asp&amp;nbsp;*.vbs。11.两种不同加密算法。12.加密&amp;nbsp;frameset&amp;nbsp;结构。13.某些功能支持几个不同版本的浏览器。

下载flash我的三种方法：
--查看源文件，找出flash的绝对路径，复制，在flashget（或蚂蚁）中点任务
，然后点新建下载任务即可。
--在IE的临时文件夹Temporary&amp;nbsp;Internet&amp;nbsp;Files里把所有的东西都删掉，然后

刷新你想要下载flash的网页，即可得到你所要的flash
--使用外部软件，推荐使用Flash&amp;nbsp;Catcher,安装后只需在你所要下载的flash上右键，save即可。

让IFRAME框架内的文档的背景透明
&amp;lt;iframe&amp;nbsp;src=&amp;quot;about:&amp;lt;body&amp;nbsp;style=&amp;#39;background:transparent&amp;#39;&amp;gt;&amp;quot;&amp;nbsp;allowtransparency&amp;gt;&amp;lt;/iframe&amp;gt;&amp;nbsp;

进入页面后立即自动刷新？
&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;refresh&amp;quot;&amp;nbsp;content=&amp;quot;120;url=http://www.loveyan.com/cn083&amp;quot;&amp;gt;
http://www.loveyan.com/cn083,这是你自己的网址。

打开窗口即最大化
&amp;lt;script&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;!--&amp;nbsp;Begin&amp;nbsp;&amp;nbsp;
self.moveTo(0,0)&amp;nbsp;
self.resizeTo(screen.availWidth,screen.availHeight)&amp;nbsp;
//&amp;nbsp;End&amp;nbsp;--&amp;gt;&amp;nbsp;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;

能隐藏IFRAME的滚动条吗？我知道的三种方法:
1.&amp;nbsp;设置iframe&amp;nbsp;scrolling=&amp;quot;no&amp;quot;
2.&amp;nbsp;被包含页body应用overflow:hidden
3.&amp;nbsp;被包含页的body标签加scroll=&amp;quot;no&amp;quot;

加入背景音乐


&amp;lt;bgsound&amp;nbsp;src=&amp;quot;mid/windblue[1].mid&amp;quot;&amp;nbsp;loop=&amp;quot;-1&amp;quot;&amp;gt;&amp;nbsp;只适用于IE&amp;nbsp;

&amp;lt;embed&amp;nbsp;src=&amp;quot;music.mid&amp;quot;&amp;nbsp;autostart=&amp;quot;true&amp;quot;&amp;nbsp;loop=&amp;quot;true&amp;quot;&amp;nbsp;hidden=&amp;quot;true&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

对Netscape&amp;nbsp;,IE&amp;nbsp;都适用&amp;nbsp;

嵌入网页

&amp;lt;iframe&amp;nbsp;name=&amp;quot;tt&amp;quot;&amp;nbsp;src=&amp;quot;01a.html&amp;quot;&amp;nbsp;width=&amp;quot;450&amp;quot;&amp;nbsp;height=&amp;quot;287&amp;quot;&amp;nbsp;scrolling=&amp;quot;Auto&amp;quot;&amp;nbsp;frameborder=&amp;quot;0&amp;quot;&amp;gt;&amp;lt;/iframe&amp;gt;&amp;nbsp;

跳转

&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;refresh&amp;quot;&amp;nbsp;content=&amp;quot;3;URL=list.htm&amp;quot;&amp;gt;&amp;nbsp;

滚动

&amp;lt;MARQUEE&amp;nbsp;direction=up&amp;nbsp;height=146&amp;nbsp;onmouseout=start()&amp;nbsp;onmouseover=stop()&amp;nbsp;scrollAmount=4&amp;gt;&amp;nbsp;
&amp;lt;/marquee&amp;gt;&amp;nbsp;

细线分隔线

&amp;lt;hr&amp;nbsp;noshade&amp;nbsp;size=0&amp;nbsp;color=#C0C0C0&amp;gt;&amp;nbsp;

过度方式

&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;Page-Exit&amp;quot;&amp;nbsp;content=&amp;quot;revealTrans(Duration=3,Transition=5)&amp;quot;&amp;gt;&amp;nbsp;
Duration的值为网页动态过渡的时间，单位为秒。&amp;nbsp;
Transition是过渡方式，它的值为0到23，分别对应24种过渡方式。如下表：&amp;nbsp;
0&amp;nbsp;盒状收缩&amp;nbsp;1&amp;nbsp;盒状放射&amp;nbsp;
2&amp;nbsp;圆形收缩&amp;nbsp;3&amp;nbsp;圆形放射&amp;nbsp;
4&amp;nbsp;由下往上&amp;nbsp;5&amp;nbsp;由上往下&amp;nbsp;
6&amp;nbsp;从左至右&amp;nbsp;7&amp;nbsp;从右至左&amp;nbsp;
8&amp;nbsp;垂直百叶窗&amp;nbsp;9&amp;nbsp;水平百叶窗&amp;nbsp;
10&amp;nbsp;水平格状百叶窗&amp;nbsp;11垂直格状百叶窗&amp;nbsp;
12&amp;nbsp;随意溶解&amp;nbsp;13从左右两端向中间展开&amp;nbsp;
14从中间向左右两端展开&amp;nbsp;15从上下两端向中间展开&amp;nbsp;
16从中间向上下两端展开&amp;nbsp;17&amp;nbsp;从右上角向左下角展开&amp;nbsp;
18&amp;nbsp;从右下角向左上角展开&amp;nbsp;19&amp;nbsp;从左上角向右下角展开&amp;nbsp;
20&amp;nbsp;从左下角向右上角展开&amp;nbsp;21&amp;nbsp;水平线状展开&amp;nbsp;
22&amp;nbsp;垂直线状展开&amp;nbsp;23&amp;nbsp;随机产生一种过渡方式&amp;nbsp;

如何控制横向和纵向滚动条的显隐？

&amp;lt;body&amp;nbsp;style=&amp;quot;overflow-y:hidden&amp;quot;&amp;gt;&amp;nbsp;去掉x轴&amp;nbsp;
&amp;lt;body&amp;nbsp;style=&amp;quot;overflow-x:hidden&amp;quot;&amp;gt;&amp;nbsp;去掉y轴&amp;nbsp;
&amp;lt;body&amp;nbsp;scroll=&amp;quot;no&amp;quot;&amp;gt;不显&amp;nbsp;

定义本网页关键字，可以在&amp;lt;Head&amp;gt;&amp;lt;/Head&amp;gt;中加入如下代码：&amp;nbsp;&amp;lt;meta&amp;nbsp;name=&amp;quot;Keywords&amp;quot;&amp;nbsp;content=&amp;quot;china,enterprise,business,net&amp;quot;&amp;gt;&amp;nbsp;　　&amp;nbsp;&amp;nbsp;
Content&amp;nbsp;中所包含的就是关键字,你可以自行设置。&amp;nbsp;　　&amp;nbsp;
这里有个技巧,你可以重复某一个单词,这样可以提高自己网站的排行位置,如：

&amp;lt;meta&amp;nbsp;name=&amp;quot;Keywords&amp;quot;&amp;nbsp;content=&amp;quot;china,china,china,china&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

IE5.0&amp;nbsp;的部分快捷键：&amp;nbsp;

A:打开查找功能：Ctrl+F&amp;nbsp;&amp;nbsp;
关闭浏览器窗口：Ctrl+W&amp;nbsp;&amp;nbsp;
打开地址栏下拉列表框：F4&amp;nbsp;&amp;nbsp;
刷&amp;nbsp;新：F5&amp;nbsp;&amp;nbsp;
将当前Web页保存到收藏夹列表：Ctrl+D&amp;nbsp;&amp;nbsp;
打开当前&amp;nbsp;IE&amp;nbsp;窗口的一个拷贝：Ctrl+N&amp;nbsp;&amp;nbsp;
停止下载当前网页：Esc&amp;nbsp;&amp;nbsp;
光标迅速移动到网页的开头：Home&amp;nbsp;&amp;nbsp;
光标迅速移动到网页的尾部：End&amp;nbsp;&amp;nbsp;
打开新的地址键入窗口：Ctrl+O&amp;nbsp;&amp;nbsp;
打开收藏夹：Ctrl+I&amp;nbsp;&amp;nbsp;
打开历史记录文件夹：Ctrl+H&amp;nbsp;&amp;nbsp;
打开浏览器设定的默认主页：Alt+HOME&amp;nbsp;&amp;nbsp;

添加到收藏夹：
&amp;lt;a&amp;nbsp;href=&amp;quot;javascript:window.external.addFavorite(&amp;#39;http://链接&amp;#39;,&amp;#39;说明&amp;#39;);&amp;quot;&amp;gt;添加到收藏夹&amp;lt;/a&amp;gt;&amp;nbsp;

设为首页：
&amp;lt;a&amp;nbsp;href=#&amp;nbsp;onclick=this.style.behavior=&amp;#39;url(#default#homepage)&amp;#39;;this.setHomePage&amp;nbsp;(&amp;#39;http://链接&amp;#39;);&amp;gt;设为首页&amp;lt;/a&amp;gt;&amp;nbsp;&amp;nbsp;

定制浏览器地址栏前的小图标：
A:在网页的&amp;lt;head&amp;gt;&amp;lt;/head&amp;gt;间加入以下语句

&amp;lt;link&amp;nbsp;rel=&amp;quot;shortcuticon&amp;quot;&amp;nbsp;href=&amp;quot;http://…/icon.ico&amp;quot;&amp;gt;&amp;nbsp;

即可。其中&amp;nbsp;icon.ico&amp;nbsp;为&amp;nbsp;16x16&amp;nbsp;的图标文件，

颜色不要超过&amp;nbsp;16&amp;nbsp;色。&amp;nbsp;

把滚动条放在浏览器窗口的左边
A:在&amp;nbsp;&amp;lt;body&amp;gt;&amp;nbsp;中加&amp;nbsp;dir=RTL，即&amp;nbsp;&amp;lt;body&amp;nbsp;dir=RTL&amp;gt;。

让背景图不滚动
IE浏览器支持一个&amp;nbsp;Body&amp;nbsp;属性&amp;nbsp;bgproperties，它可以让背景不滚动:&amp;nbsp;

&amp;lt;Body&amp;nbsp;Background=&amp;quot;图片文件&amp;quot;&amp;nbsp;bgproperties=&amp;quot;fixed&amp;quot;&amp;gt;&amp;nbsp;&amp;nbsp;

删除确认：

&amp;lt;input&amp;nbsp;type=&amp;quot;button&amp;quot;&amp;nbsp;name=&amp;quot;DEL&amp;quot;&amp;nbsp;onclick=&amp;quot;{if(confirm(&amp;#39;确认删除么?&amp;#39;)){location.href=&amp;#39;xxx.asp&amp;#39;;}return&amp;nbsp;false;}&amp;quot;&amp;nbsp;&amp;nbsp;value=&amp;quot;ON&amp;quot;&amp;nbsp;&amp;gt;&amp;nbsp;

隐藏状态栏中的链接地址：

&amp;lt;script&amp;nbsp;language=&amp;quot;javascript&amp;quot;&amp;gt;&amp;nbsp;
kstatus();&amp;nbsp;
function&amp;nbsp;kstatus(){&amp;nbsp;
self.status=&amp;quot;GBlog&amp;nbsp;()&amp;nbsp;&amp;quot;;&amp;nbsp;
setTimeout(&amp;quot;kstatus()&amp;quot;,0);&amp;nbsp;
}&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;
自定义指定区域的文字大小：
&amp;lt;div&amp;nbsp;id=zoom&amp;gt;sdrrrrrrrrrrrrrrrrrrrrrrrrrrrrr&amp;lt;/div&amp;gt;&amp;nbsp;
【&amp;lt;A&amp;nbsp;href=&amp;quot;javascript:doZoom(16)&amp;quot;&amp;gt;大&amp;lt;/A&amp;gt;&amp;nbsp;&amp;lt;A&amp;nbsp;href=&amp;quot;javascript:doZoom(14)&amp;quot;&amp;gt;中&amp;lt;/A&amp;gt;&amp;nbsp;&amp;lt;A&amp;nbsp;href=&amp;quot;javascript:doZoom(12)&amp;quot;&amp;gt;小&amp;lt;/A&amp;gt;】&amp;nbsp;
&amp;lt;SCRIPT&amp;nbsp;language=JavaScript&amp;gt;&amp;nbsp;
function&amp;nbsp;doZoom(size){&amp;nbsp;
document.getElementById(&amp;#39;zoom&amp;#39;).style.fontSize=size+&amp;#39;px&amp;#39;&amp;nbsp;
}&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;

Input输入框文字效果：


&amp;lt;input&amp;nbsp;type=&amp;quot;text&amp;quot;&amp;nbsp;value=&amp;quot;123456&amp;quot;&amp;nbsp;style=&amp;quot;FONT-size:38px;color:red;font-family:arial&amp;nbsp;black&amp;quot;&amp;gt;&amp;nbsp;
通过层来实现渐淡淡出
&amp;lt;script&amp;nbsp;language=&amp;quot;JavaScript1.2&amp;quot;&amp;gt;&amp;nbsp;
function&amp;nbsp;makevisible(cur,which){&amp;nbsp;
if&amp;nbsp;(which==0)&amp;nbsp;
cur.filters.alpha.opacity=100&amp;nbsp;
else&amp;nbsp;
cur.filters.alpha.opacity=50&amp;nbsp;
}&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;
&amp;lt;div&amp;nbsp;style=&amp;quot;width:200px;height:200px;filter:alpha(opacity=50);border:1px&amp;nbsp;solid&amp;nbsp;#000;background:#efefef&amp;quot;&amp;nbsp;onMouseOver=&amp;quot;makevisible(this,0)&amp;quot;&amp;nbsp;onMouseOut=&amp;quot;makevisible(this,1)&amp;quot;&amp;gt;&amp;nbsp;
ywicc.com&amp;nbsp;
&amp;lt;/div&amp;gt;&amp;nbsp;


网页屏保
&amp;lt;script&amp;nbsp;&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;
function&amp;nbsp;&amp;nbsp;screensave(){&amp;nbsp;
test.value++;&amp;nbsp;
if(test.value==5){&amp;nbsp;
test.style.display=&amp;#39;none&amp;#39;;&amp;nbsp;
document.all[4].bgColor=&amp;#39;black&amp;#39;;&amp;nbsp;
}&amp;nbsp;
}&amp;nbsp;
function&amp;nbsp;&amp;nbsp;screenopen(){&amp;nbsp;
test.value=0;&amp;nbsp;
test.style.display=&amp;#39;&amp;#39;;&amp;nbsp;
document.all[4].bgColor=&amp;#39;&amp;#39;;&amp;nbsp;
}&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;
&amp;lt;body&amp;nbsp;&amp;nbsp;onkeydown=&amp;quot;screenopen()&amp;quot;&amp;nbsp;&amp;nbsp;onmousemove=&amp;quot;screenopen()&amp;quot;&amp;nbsp;&amp;nbsp;onload=&amp;quot;setInterval(&amp;#39;screensave()&amp;#39;,1000)&amp;quot;&amp;gt;&amp;nbsp;
5&amp;nbsp;&amp;nbsp;秒屏保&amp;lt;input&amp;nbsp;&amp;nbsp;id=&amp;quot;test&amp;quot;&amp;gt;&amp;nbsp;


让标题动态
&amp;lt;script&amp;gt;&amp;nbsp;
&amp;lt;!--&amp;nbsp;
var&amp;nbsp;tx&amp;nbsp;=&amp;nbsp;new&amp;nbsp;Array&amp;nbsp;(&amp;nbsp;
&amp;quot;◇:::::::静怡家园:::::::◇欢迎您!◇&amp;quot;,&amp;nbsp;
&amp;quot;◆欢迎大家光临静怡家园网站!◆&amp;quot;,&amp;nbsp;&amp;nbsp;
&amp;quot;◆大量供应网页制作教材,资料,源代码,网页制作软件,相关插件光盘!◆&amp;quot;,&amp;nbsp;
&amp;quot;◆最可怕的敌人，就是没有坚强的信念!◆&amp;quot;,&amp;nbsp;
&amp;quot;◆应该让别人的生活因为有了你的生存而更加美好!◆&amp;quot;&amp;nbsp;
);&amp;nbsp;
var&amp;nbsp;txcount=5;&amp;nbsp;
var&amp;nbsp;i=1;&amp;nbsp;&amp;nbsp;
var&amp;nbsp;wo=0;&amp;nbsp;&amp;nbsp;
var&amp;nbsp;ud=1;&amp;nbsp;&amp;nbsp;
function&amp;nbsp;animatetitle()&amp;nbsp;&amp;nbsp;
{&amp;nbsp;&amp;nbsp;
window.document.title=tx[wo].substr(0,&amp;nbsp;i)+&amp;quot;_&amp;quot;;&amp;nbsp;&amp;nbsp;
if&amp;nbsp;(ud==0)&amp;nbsp;i--;&amp;nbsp;&amp;nbsp;
if&amp;nbsp;(ud==1)&amp;nbsp;i++;&amp;nbsp;&amp;nbsp;
if&amp;nbsp;(i==-1)&amp;nbsp;{ud=1;i=0;wo++;wo=wo%txcount;}&amp;nbsp;&amp;nbsp;
if&amp;nbsp;(i==tx[wo].length+10)&amp;nbsp;{ud=0;i=tx[wo].length;}&amp;nbsp;&amp;nbsp;
//&amp;nbsp;if&amp;nbsp;(window.document.title.length&amp;nbsp;&amp;lt;&amp;nbsp;20&amp;nbsp;)&amp;nbsp;window.document.title=window.document.title+&amp;quot;-&amp;quot;;&amp;nbsp;&amp;nbsp;
//&amp;nbsp;if&amp;nbsp;(window.document.title.length&amp;nbsp;==&amp;nbsp;20&amp;nbsp;)&amp;nbsp;window.document.title=window.document.title+&amp;quot;]&amp;quot;;&amp;nbsp;&amp;nbsp;
//&amp;nbsp;if&amp;nbsp;(window.document.title.length&amp;nbsp;==&amp;nbsp;21&amp;nbsp;)&amp;nbsp;setTimeout(&amp;quot;window.document.title=&amp;#39;Animierte&amp;nbsp;Seitentitel&amp;nbsp;&amp;#39;;&amp;nbsp;&amp;quot;,1000);&amp;nbsp;&amp;nbsp;

parent.window.document.title=tx[wo].substr(0,&amp;nbsp;i)+&amp;quot;_&amp;quot;;&amp;nbsp;&amp;nbsp;
setTimeout(&amp;quot;animatetitle()&amp;quot;,100);&amp;nbsp;&amp;nbsp;
}&amp;nbsp;&amp;nbsp;
animatetitle();&amp;nbsp;
//&amp;nbsp;--&amp;gt;&amp;lt;/script&amp;gt;&amp;lt;script&amp;nbsp;language=&amp;quot;JavaScript&amp;quot;&amp;gt;&amp;nbsp;
&amp;lt;!--&amp;nbsp;
function&amp;nbsp;MM_openBrWindow(theURL,winName,features)&amp;nbsp;{&amp;nbsp;//v2.0&amp;nbsp;
&amp;nbsp;&amp;nbsp;window.open(theURL,winName,features);&amp;nbsp;
}&amp;nbsp;
//--&amp;gt;&amp;nbsp;
&amp;lt;/script&amp;gt;&amp;nbsp;


隐去浏览器中当鼠标移到图片上跳出的工具栏
&amp;lt;img&amp;nbsp;galleryimg=&amp;quot;no&amp;quot;&amp;gt;&amp;nbsp;

或者
&amp;lt;head&amp;gt;&amp;nbsp;
&amp;lt;meta&amp;nbsp;http-equiv=&amp;quot;imagetoolbar&amp;quot;&amp;nbsp;content=&amp;quot;no&amp;quot;&amp;gt;&amp;nbsp;
&amp;lt;/head&amp;gt;&amp;nbsp;

在form中只有input输入框的情况下...在这个input输入框中按enter进行提交表单
&amp;lt;form&amp;nbsp;onsubmit=&amp;quot;if(event.srcElement.name==&amp;#39;bb&amp;#39;){this.submit()}else{return&amp;nbsp;false}&amp;quot;&amp;gt;&amp;nbsp;
&amp;lt;input&amp;nbsp;name=a&amp;nbsp;size=20&amp;gt;&amp;nbsp;
&amp;lt;input&amp;nbsp;type=button&amp;nbsp;name=bb&amp;nbsp;onclick=&amp;quot;submit();&amp;quot;&amp;gt;&amp;nbsp;
&amp;lt;/form&amp;gt;&amp;nbsp;&amp;nbsp;

删除确认
&amp;lt;input&amp;nbsp;type=&amp;quot;button&amp;quot;&amp;nbsp;value=&amp;quot;删除&amp;quot;&amp;nbsp;onclick=&amp;quot;{if(confirm(&amp;#39;确认删除么？&amp;#39;)){location.href=&amp;#39;aa.asp&amp;#39;;}return&amp;nbsp;false;}&amp;quot;&amp;gt;&amp;nbsp;
或
&amp;lt;a&amp;nbsp;href=&amp;quot;aa.asp&amp;quot;&amp;nbsp;onclick=&amp;quot;{if(confirm(&amp;#39;确定删除吗?&amp;#39;)){return&amp;nbsp;true;}return&amp;nbsp;false;}&amp;quot;&amp;gt;删除&amp;lt;/a&amp;gt;&amp;nbsp;
或
&amp;lt;a&amp;nbsp;href=&amp;quot;del.asp&amp;quot;&amp;nbsp;onclick=&amp;quot;return&amp;nbsp;confirm(&amp;#39;该删除操作将无法恢复！是否继续？&amp;#39;)&amp;quot;&amp;gt;删除&amp;lt;/a&amp;gt;&amp;nbsp;

返回页面顶部：
javascript:window.scroll(0,0)&amp;nbsp;


离开页面时弹出警告：
&amp;lt;BODY&amp;nbsp;onbeforeunload=&amp;quot;checkclose()&amp;quot;&amp;gt;

&amp;lt;SCRIPT&amp;gt;
function&amp;nbsp;checkclose(){
&amp;nbsp;&amp;nbsp;event.returnValue&amp;nbsp;=&amp;nbsp;&amp;quot;测试啊&amp;quot;&amp;nbsp;//XXX可以改为任何文本信息也可以是空
}
&amp;lt;/SCRIPT&amp;gt;

&amp;lt;a&amp;nbsp;href=&amp;quot;a.asp&amp;quot;&amp;gt;aa&amp;lt;/a&amp;gt;&lt;/pre&gt;&lt;p&gt;&lt;br/&gt;&lt;/p&gt;</description><pubDate>Tue, 14 Feb 2006 11:15:41 +0800</pubDate></item><item><title>渐变链接特效</title><link>http://loveyan.com/post/14.html</link><description>&lt;p&gt;
    很多网上网下的朋友都超喜欢渐变链接特效，纷纷询问具体的制作过程，因为网上不容易找到专门的教程，但我仍然认为功夫永远在技巧之外，技巧这种东西本来就应该大家分享的，但不见得学会了就一定会有出色的作品，FEEL很重要。OK，闲话少说，今天就专门写下这个教程，希望大家能举一反三，设计出令人耳目一新的作品。
&lt;/p&gt;
&lt;p&gt;
    首先，新建一个文本文档，例如取名为yourname，后缀为.htc。
&lt;/p&gt;
&lt;p&gt;
    在文档中写入以下内容：
&lt;/p&gt;
&lt;pre class=&quot;prism-highlight prism-language-javascript&quot;&gt;&amp;lt;public:component&amp;gt;
&amp;lt;public:attach event=&amp;quot;onmouseover&amp;quot; onevent=&amp;quot;domouseover()&amp;quot;&amp;gt;
&amp;lt;public:attach event=&amp;quot;onmouseout&amp;quot; onevent=&amp;quot;domouseout()&amp;quot;&amp;gt;
&amp;lt;script language=&amp;quot;javascript&amp;quot;&amp;gt;
function domouseover(){
with(element)
{filters.item(0).Apply();filters.item(0).Play();}}
function domouseout(){
with(element){
filters.item(0).Apply();
filters.item(0).Play();}}
&amp;lt;/script&amp;gt;
&amp;lt;/public:component&amp;gt;&lt;/pre&gt;
&lt;p&gt;
    保存。
&lt;/p&gt;
&lt;p&gt;
    打开已经设置好超链接的网页，在&amp;lt;head&amp;gt;&amp;lt;/head&amp;gt;之间写入以下内容：
&lt;/p&gt;
&lt;pre class=&quot;prism-highlight prism-language-css&quot;&gt;&amp;lt;style type=text/css&amp;gt;
&amp;lt;!--
a {cursor:hand; height:1; behavior: url(yourname.htc); filter:progid:dximagetransform.microsoft.gradientwipe(duration=1);text-decoration : none ; } 
a:link { color : #009900 ; }
a:visited { color : #009900 ; }
a:hover { color : #ffffff ; }          （此段即为鼠标划过超连接时所显示的渐变颜色代码）
a:active { color : #009900 ; }
--&amp;gt;
&amp;lt;/style&amp;gt;&lt;/pre&gt;
&lt;p&gt;
    保存。大功告成。
&lt;/p&gt;
&lt;p&gt;
    欲浏览正确效果，请上传到自己的空间内，再用浏览器查看。没有装IIS的同学估计在本机无法看到正确效果。
&lt;/p&gt;</description><pubDate>Wed, 01 Feb 2006 11:10:04 +0800</pubDate></item><item><title>旧貌要换新颜：滚动条大变身</title><link>http://loveyan.com/post/13.html</link><description>&lt;p&gt;
    滚动条的颜色、阴影、立体等等都是由CSS所定义的，可能各位常常听说CSS的大名，又不太了解它到底是何方神圣吧，那偶在这里就简单说说好了。CSS就是样式表，它主要被用来控制网页的字体大小、字体颜色、背景色、滚动条样式等等。
&lt;/p&gt;
&lt;p&gt;
    可能有同学会在这时候插嘴了：“字体颜色大小，我直接在FRONTPAGE中也一样可以控制啊。”
&lt;/p&gt;
&lt;p&gt;
    OK，请坐，这位的话讲得非常好。确实，颜色方面呢倒不是很紧要，但是字体的大小控制可就非常要紧了，这是网站成败的一大关键哦！举例来说吧，可能大家常常会看到一些“怪怪”的网页：本来排版还挺好的，可是字一个个都很大，感觉好象把网页都“撑”破了似的。这种症状就是典型的“CSS未定义或定义不当症”。因为每个电脑用户的IE浏览器的设置都可能不一样，如果没有CSS控制的话，就会发生在自己机器上看着这网页明明是好好的，但是上传到网上后，别人看起来却是乱七八糟的情况。
&lt;/p&gt;
&lt;p&gt;
    呵呵，抱歉，偶又跑题了，不过在讲了这么一堆以后，大家一定对CSS有很大认识咯！现在来讲讲滚动条的定义。
&lt;/p&gt;
&lt;p&gt;
    打开需要控制滚动条的网页，我们转到代码页面，直接拷贝以下代码加入&amp;lt;head&amp;gt;&amp;lt;/head&amp;gt;之间：
&lt;/p&gt;
&lt;pre class=&quot;prism-highlight prism-language-css&quot;&gt;
&amp;lt;style&amp;gt;
&amp;lt;!--
BODY{
scrollbar-face-color:#ffffff;
scrollbar-arrow-color:#cccccc;
scrollbar-shadow-color:&amp;#39;#ffffff&amp;#39;;
scrollbar-highlight-color:&amp;#39;#ffffff&amp;#39;;
scrollbar-base-color:&amp;#39;#ffffff&amp;#39;;
scrollbar-darkshadow-Color:&amp;#39;#ffffff&amp;#39;;
}
--&amp;gt;
&amp;lt;/style&amp;gt;&lt;/pre&gt;
&lt;p&gt;
    现在给出各字段的含义哦，那些“#ffffff”之类的就是颜色代码啦，各位可以随便修改哦。
&lt;/p&gt;
&lt;p&gt;
    scrollbar-face-color &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;立体滚动条凸出部分的颜色
&lt;/p&gt;
&lt;p&gt;
    scrollbar-arrow-color &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 上下按钮上三角箭头的颜色 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;nbsp;
&lt;/p&gt;
&lt;p&gt;
    scrollbar-shadow-color &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;立体滚动条阴影的颜色
&lt;/p&gt;
&lt;p&gt;
    scrollbar-highlight-color &amp;nbsp; &amp;nbsp; 滚动条空白部分的颜色
&lt;/p&gt;
&lt;p&gt;
    scrollbar-base-color &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;滚动条基本颜色
&lt;/p&gt;
&lt;p&gt;
    scrollbar-darkshadow-Color &amp;nbsp; &amp;nbsp;立体滚动条强阴影的颜色
&lt;/p&gt;
&lt;p&gt;
    就这么轻松哦，填上自己喜欢的颜色代码以后，可以预览看看合适不合适，注意一定要与网页本身的主色调搭配，别喧宾夺主咯。最重要的永远是心思，不是技巧哦。
&lt;/p&gt;
&lt;p&gt;
    感谢各位这么赏脸来看偶的教程，最后偶再奉送一道小点心给大家品尝，谢谢谢谢。
&lt;/p&gt;
&lt;p&gt;
    在任何情况下，如果网页超出显示器所设定分辨率的显示范围，就会出现滚动条。但有时偶们可能会觉得它有碍观瞻，不想让它显示，如何隐藏它呢？请在&amp;lt;body &amp;gt; &amp;lt;/body&amp;gt;之间插入代码：&amp;lt;body &amp;nbsp;style=&amp;quot;overflow-x:hidden;overflow-y:hidden&amp;quot;&amp;gt;，搞定。其中x表示水平滚动条，将其改为y的话就可以隐藏垂直滚动条。
&lt;/p&gt;</description><pubDate>Mon, 02 Jan 2006 10:52:19 +0800</pubDate></item><item><title>MySQL 5.0.15数据同步备份(master-slave)</title><link>http://loveyan.com/post/12.html</link><description>平台说明：
&lt;br/&gt;
192.168.200.102=&amp;gt;master
&lt;br/&gt;
192.168.200.101=&amp;gt;slave
&lt;br/&gt;
Mysql版本：Mysql 5.0.15
&lt;br/&gt;
操作系统：Fc3 内核：2.6.9
&lt;br/&gt;&lt;br/&gt;
(1)配置主服务器
&lt;br/&gt;
#vi /etc/my.cnf
&lt;pre class=&quot;prism-highlight prism-language-sql&quot;&gt;[mysqld]
log-bin=hnolwebserver-bin //日志文件的名称，这里可以制定日志到别的目录 如果没有设置则默认主机名的一个日志名称
server-id = 1 //数据库的id这个应该默认是1就不用改动
binlog-do-db=tianya //需同步的数据库，多数据库用binlog-do-db=tianya1。
character-set-server=gb2312 //设置支持gb2312的字符集。&lt;/pre&gt;

&lt;br/&gt;
#/usr/local/mysql/bin/mysql -u root -p
&lt;br/&gt;
#建tianya数据库。
&lt;br/&gt;
#mysql&amp;gt;GRANT REPLICATION SLAVE ON *.* TO &amp;#39;backup&amp;#39;@&amp;#39;192.168.200.101&amp;#39; IDENTIFIED BY &amp;#39;123456&amp;#39;; #添加一个主机为192.168.200.101的backup帐号，具有全局REPLICATION SLAVE权限。
&lt;br/&gt;
在phpMyAdmin中导出tianya数据库的SQL数据为tianya.sql。
&lt;br/&gt;
#mysql&amp;gt;show master status\G;
&lt;br/&gt;
*************************** 1. row ***************************
&lt;br/&gt;
File: hnolwebserver-bin.000010
&lt;br/&gt;
Position: 649
&lt;br/&gt;Binlog_Do_DB: tianya
&lt;br/&gt;Binlog_Ignore_DB:
&lt;br/&gt;1 row in set (0.01 sec)
记下File与Position在设置从服务中需要用到。
&lt;br/&gt;
(2)配置从服务器
&lt;br/&gt;
修改/etc/my.cnf，如是多实例Msyql，则修改my_multi.cnf中的任一个实例定义中。
&lt;pre class=&quot;prism-highlight prism-language-sql&quot;&gt;[mysqld]
master-host=192.168.200.102 #主服务端主机
master-user=backup #主服务端开设的帐号
master-password=123456 #主服务端开设的密码
master-port=3306 #主服务端Mysql端口
server-id=2 #设置数据库id默认主服务器是1可以随便设置但是如果有多台从服务器则不能重复。
master-connect-retry=60 #如果从服务器发现主服务器断掉，重新连接的时间差
replicate-do-db=tianya #同步的数据库
character-set-server=gb2312 #设置中文字符集。&lt;/pre&gt;

将tianya.sql导入到从服务器中。与主服务器数据库一致.&lt;br/&gt;#/usr/local/mysql/bin/mysql -u root -p
&lt;br/&gt;
设置主服务器的各种参数:
&lt;pre class=&quot;prism-highlight prism-language-sql&quot;&gt;#mysql&amp;gt;slave stop; #停止slave的服务
#mysql&amp;gt;CHANGE MASTER TO
#mysql&amp;gt;MASTER_HOST=&amp;#39;192.168.200.102&amp;#39;,#主服务器的IP地址
#mysql&amp;gt;MASTER_USER=&amp;#39;backup&amp;#39;, #同步数据库的用户
#mysql&amp;gt;MASTER_PASSWORD=&amp;#39;123456&amp;#39;, #同步数据库的密码
#mysql&amp;gt;MASTER_LOG_FILE=&amp;#39;hnolwebserver-bin.000016&amp;#39;, #主服务器二进制日志的文件名(前面要求记住的参数)
#mysql&amp;gt;MASTER_LOG_POS=2567; #日志文件的开始位置(前面要求记住的参数)
#mysql&amp;gt;slave start; #启动同步数据库的线程&lt;/pre&gt;</description><pubDate>Sun, 01 Jan 2006 10:15:31 +0800</pubDate></item><item><title>su命令的详细用法</title><link>http://loveyan.com/post/9.html</link><description>&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;1.命令作用&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;su的作用是变更为其它使用者的身份，超级用户除外，需要键入该使用者的密码。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;2.使用方式&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;su [-fmp] [-c command] [-s shell] [--help] [--version] [-] [USER [ARG]]&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;3.参数说明&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;-f ， –fast：不必读启动文件（如 csh.cshrc 等），仅用于csh或tcsh两种Shell。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;-l ， –login：加了这个参数之后，就好像是重新登陆一样，大部分环境变量(例如HOME、SHELL和USER等)都是以该使用者(USER)为主，并&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;且工作目录也会改变。如果没有指定USER，缺省情况是root。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;-m， -p ，–preserve-environment：执行su时不改变环境变数。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;-c command：变更账号为USER的使用者，并执行指令（command）后再变回原来使用者。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;–help 显示说明文件&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;–version 显示版本资讯&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;USER：欲变更的使用者账号，&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;ARG: &amp;nbsp;传入新的Shell参数。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;4.例子&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;su -c ls root 变更帐号为 root 并在执行 ls 指令后退出变回原使用者。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;su [用户名]&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;a&amp;gt;在root用户下, 输入 su 普通用户. 则切换至普通用户, 从root切换到变通用户不需要密码&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;b&amp;gt;在普通用户下, 输入 su [用户名]&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;提示 password:&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;输入用户的PASSWORD, 则切换至该用户&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;扩展阅读一:Linux下 su命令与su - 命令有什么区别？&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;su 是切换到其他用户，但是不切换环境变量（比如说那些export命令查看一下，就知道两个命令的区别了）&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;su - 是完整的切换到一个用户环境&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;所以建议大家切换用户的时候,尽量使用 su - &amp;nbsp;linuxso 这样 否则可能发现某些命令执行不了&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;扩展阅读二:su和sudo的区别&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;由于su 对切换到超级权限用户root后，权限的无限制性，所以su并不能担任多个管理员所管理的系统。如果用su 来切换到超级用户来管理系统，也不能明确哪些工作是由哪个管理员进行的操作。特别是对于服务器的管理有多人参与管理时，最好是针对每个管理员的技术特长和 管理范围，并且有针对性的下放给权限，并且约定其使用哪些工具来完成与其相关的工作，这时我们就有必要用到 sudo。&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;通过sudo，我们能把某些超级权限有针对性的下放，并且不需要普通用户知道root密码，所以sudo 相对于权限无限制性的su来说，还是比较安全的，所以sudo 也能被称为受限制的su ；另外sudo 是需要授权许可的，所以也被称为授权许可的su；&lt;/p&gt;&lt;p style=&quot;text-indent: 2em; text-align: left;&quot;&gt;sudo 执行命令的流程是当前用户切换到root（或其它指定切换到的用户），然后以root（或其它指定的切换到的用户）身份执行命令，执行完成后，直接退回到当前用户；而这些的前提是要通过sudo的配置文件/etc/sudoers来进行授权；&lt;/p&gt;</description><pubDate>Mon, 29 Aug 2005 17:01:28 +0800</pubDate></item><item><title>SHELL精简学习资料</title><link>http://loveyan.com/post/8.html</link><description>&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;一、用户登陆进入系统后的系统环境变量：&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$HOME 使用者自己的目录&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$PATH 执行命令时所搜寻的目录&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$TZ 时区&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$MAILCHECK 每隔多少秒检查是否有新的信件&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$PS1 在命令列时的提示号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$PS2 当命令尚未打完时，Shell 要求再输入时的提示号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$MANPATH man 指令的搜寻路径&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;二、特殊变量：&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$0 这个程序的执行名字&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$n 这个程序的第n个参数值，n=1..9&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$* 这个程序的所有参数&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$# 这个程序的参数个数&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$$ 这个程序的PID&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$! 执行上一个指令的PID&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;$? 执行上一个指令的返回值&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;三、shell中的变元：&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;* 任意字符串&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;? 一个任意字符&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;[abc] a, b, c三者中之一&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;[a-n] 从a到n的任一字符&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;四、几个特殊字符表示&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;\b 退回&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;\c 打印一行时没有换行符 这个我们经常会用到&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;\f 换页&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;\r 回车&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;\t 制表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;\v 垂直制表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;\\ 反斜线本身&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;五、判断文件的属性&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;格式：-操作符 filename&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-e 文件存在返回1， 否则返回0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-r 文件可读返回1,否则返回0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-w 文件可写返回1,否则返回0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-x 文件可执行返回1,否则返回0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-o 文件属于用户本人返回1, 否则返回0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-z 文件长度为0返回1, 否则返回0.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-f 文件为普通文件返回1, 否则返回0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-d 文件为目录文件时返回1, 否则返回0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;六、测试字符串&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;字符串1 = 字符串2　当两个字串相等时为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;字符串1 != 字符串2 当两个字串不等时为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-n 字符串　 　　　 当字符串的长度大于0时为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-z 字符串　　　　　 当字符串的长度为0时为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;字符串　　　　　　 当串字符串为非空时为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;七、测试两个整数关系&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;数字1 -eq 数字2　　　　 两数相等为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;数字1 -ne 数字2　　　　 两数不等为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;数字1 -gt 数字2　　　　 数字1大于数字2为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;数字1 -ge 数字2 　　　 数字1大于等于数字2为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;数字1 -lt 数字2　　　　 数字1小于数字2为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;数字1 -le 数字2　　　　 数字1小于等于数字2为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;八、逻辑测试&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-a 　 　　　　与&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;-o　　　　　或&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;!　　　　　　非&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;今天介绍shell特殊字符的引用&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;===============================&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;===============================&lt;/span&gt;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;shell中的特殊字符有&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;1、$ 美元符&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;2、\ 反斜杠&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;3、` 反引号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;4、&amp;quot;　双引号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;5、&amp;lt; ,&amp;gt;;,*,?,[,]&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;下面我一一举列说明&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;一、$符号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;1、echo $? 显示的是上一条指令退出状态&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;2、echo &amp;quot;$?&amp;quot; 效果同上&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;3、echo &amp;#39;$?&amp;#39; 显示的是$?&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;4、echo \$? 显示的是$?&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;5、echo &amp;quot;\$?&amp;quot; 显示的是$?&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　大家可能已经看出　$符号在双引号中具有特殊意义　双引号对$符号不起作用&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;而单引号可以将特殊字符的的特殊意义屏蔽掉，使其能显示为字符本身，反斜&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;杠也可以将特殊字符的特殊含义屏蔽掉，使特殊字符失去特殊含义。&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;二、\　反斜杠&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　反斜杠的作用是将特殊符号字符的特殊含义屏蔽掉，使其还是原字符&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;A＝1234&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo \$A 显示为$A 如果不加\将显示为1234&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo \` 显示为`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo \&amp;quot; 显示为双引号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo \\ 显示为\&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;三、` 反引号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　反引号的功能是命令替换，将反引号中的字符串做为命令来执行，我们在用shell编程时经常用的到　将系统命令的执行结果赋给一个变量&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;A=`date`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo $A 显示的不是date而是当时的时间串&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;比如有一文件A的内容如下　&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;ABCDEFG&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;1234456&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;abcdefg&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;B=`cat A|grep 234` # 检索文件A中含有字符串234的行&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo $B 将显示为1234456&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;$B&amp;quot; 将显示为什么？&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;\$B&amp;quot; 将显示为什么？读者自己试试&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;四、&amp;quot; 双引号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　在系统中有些特殊字符，为避免引用这些特殊字符　往往用双引号或单引号将这些特殊字符引起来，使其不具有特殊含义。&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　但有一部分特殊字符在引号中还是具有特殊含义，用双引号引起来是不起作用的。本文中所列的前四个特殊字符在双引号中还是特殊字符。为了使其不具有特殊含义一是用单引号引进来二是用\反斜线使其失去作用。&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　比如我们想原样输出这些特殊字符&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;&amp;quot;&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;$&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;\&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;`&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　以上不是你所期望的结果，因为双引号对它们不起作用，你只能这样才能输出这些特殊字符的原形&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;#39;&amp;quot;&amp;#39;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;#39;$&amp;#39;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;#39;\&amp;#39;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;#39;`&amp;#39;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;或&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;\&amp;quot;&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;\$&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;\\&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;\`&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;将分别显示为　&amp;quot; $ \ `&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;五、其它特殊字符&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　大家注意到除了前四个特殊字符外我将其它的特殊字符都放在一块，这是因为前四个特殊字符在双引号中还是具有特殊含义，所以单独拿出来讲，除此以外的特殊字符如果你要输出这些特殊字符的原形，你就可以用双引号或单引号引起来使其失去特殊含义。&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;&amp;lt; ,&amp;gt;;,*,?,[,]对shell有特殊含义，但你可以用双引号引起来输入这些原形&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;　　讲了这么多大家是不是已经注意到所有的特殊字符在单引号中失去特殊含义，如果你要输出特殊字符原形但又记不清那些特殊字符在双引号中不能输出原形，建议你干脆用单引号引起来。&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;今天介绍条件测试语句&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;一、if 条件语句　&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;格式：&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if 条件表达式&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then #当条件为真时执行以下语句&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;else #为假时执行以下语句&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if　语句也可以嵌套使用&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if 条件表达式1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if 条件表达式2&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;else&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if 条件表达式3&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;else&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;else&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;你可以进行多层嵌套　一个if语句一定要跟一个fi　表示该层条件结束　　否则会造成语法错误&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;结合前面讲的　举例如下：&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;这里先讲一个条件语句中用到的命令test　表示测试test后面的条件是否为真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if test -f &amp;quot;$1&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;lpr $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;else&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if test -d &amp;quot;$1&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;cd $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;lpr $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;else&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;$1不是文件或目录&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;以上的例子还可以改成如下所示&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if test -f &amp;quot;$1&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;lpr $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;elif test -d &amp;quot;$1&amp;quot; #elif　同else if&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;(cd $1;lpr $1)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;else&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;$1不是文件或目录&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;以上的例子不知您是否看懂是什么意思吗？&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;假如我们现在将这个例子保存为prfile&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;chmod +x prfile&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;执行刚才的程序&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;./prfile aaa&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;这个例子是检查你的输入的参数是否是一个文件　如果是就打印　如果是一个目录　先转目录再打印　如果即不是文件也不是目录给出提示&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;二、多重条件测试语句case&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;格式：&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;case 字串　in&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;模式) 命令列表;;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;模式) 命令列表;;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;....&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;esac&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;多重条件语句是以case 开始以esac结束　中间可以有多个条件列表　功能是测试字串和和里面的模式有没有匹配的,有就执行里面的命令列表　模式也可以是*号　表示任意字串，每个模式里面的最后要心;;双引号结束，否则会发生语法错误。&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;现举例如下：&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;case $1 in&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;*.c)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;cc $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;;;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;*.txt)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;lpr $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;;;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;*)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;未知的类型&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;esac&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;假如将以上内容保存在文件abc中&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;chmod +x abc&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;执行　./abc a.c 　 将会对文件a.c进行编译&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;执行 ./abc readme.txt　将会把文件通过打印机&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;假如我将以上内容改一下，你是否会知道它的执行结果？&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;case $1 in&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;*)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;cc $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;;;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;*.txt)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;lpr $1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;;;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;*.c)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;未知的类型&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;esac&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;今天介绍循环语句&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;一. while 循环&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;while 命令格式&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;while 条件表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;do&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;done&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;执行过程&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;shell首先执行条件表,如果条件表的最后一条语句的退出状态为零,则执行盾环体内的命令&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;表,执行完后,再检查条件表,如果退出状态为零将继续执行,如此循环往复直到条件表的&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;最后一条语句的退出状态非零. 退出状态为零就是条件为真True.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;举例说明 假如shell文件的内容如下:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;Sum=0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;i=0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;while true #true是系统的关键词 表示真&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;do&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;i=`expr $i + 1`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;Sum=`expr $Sum + $i`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;if [ $i = &amp;quot;100&amp;quot; ]&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;then&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;break;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;fi&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;done&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo $i $Sum&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;最后这个程序显示的是 100 5050&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;这个程序的运算就是将1到100加起来&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;下面将这个程序再改动一下&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;Sum=0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;i=0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;while [ $i != &amp;quot;100&amp;quot; ]&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;do&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;i=`expr $i + 1`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;Sum=`expr $Sum + $i`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;done&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo $i $Sum&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;改动后的程序运算结果和上面是一样 但程序比上面的要简练&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;在这个循环中还可以以until做为测试条件 它正好与while测试的条件相反,也就是当条件为假时将继续执行循环体内的语句,否则就退出循环体,下面还用这个例子.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;Sum=0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;i=0&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;until [ $i = &amp;quot;100&amp;quot; ]&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;do&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;i=`expr $i + 1`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;Sum=`expr $Sum + $i`&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;done&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo $i $Sum&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;当i不等于100时循环 就是当条件为假时循环,否则就退出,而第一个例子是当i不等于100&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;时循环,也就是测试条件为真时循环.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;二.for 循环&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令格式:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;for 变量 in 名字列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;do&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令列表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;done&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;这里的名字列表是一个由空格分隔的字符串列表,shell在执行for循环时每次依次从名字表&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;中取出一个字符串赋给循环变量作为变量的值.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;在写for语句时,也可以省略in 名字列表部分,这表示用当前的位置参数来代替这时的名&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;字列表.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;下面举个例子&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;比如在你的电脑中有两个目录,一个是aa,一个是bb在这两个目录中有5个相同的文件,但其&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;中一个目录中的一个或多个文件刚刚修改过,现在我忘记刚才改的是那几个文件 了,那么我靠梢员冉弦幌抡饬礁瞿柯嫉奈募椭懒?程序如下:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;for File in a1 a2 a3 a4 a5&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;do&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;diff aa/$File bb/$File&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;done&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;下面再举一个不带名字列表的例子&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;for File&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;do&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo $Filw&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;done&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;文件内容保存在a.sh中 并可执行&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;我们在执行这个shell程序时命令行如下:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;a.sh a1 a2 a3 a4 a5&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;执行结果如下:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;a1&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;a2&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;a3&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;a4&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;a5&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;大家从这个例子中可以看到命令行的参数被逐一读入一次&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;三.循环控制语句&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;break 命令不执行当前循环体内break下面的语句从当前循环退出.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;continue 命令是程序在本循体内忽略下面的语句,从循环头开始执行.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;一,命令组合:圆括号和花括号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;shell中有两种方法将命令组合在一起:圆括号和花括号.圆括号使shell创建一个子shell&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;来读取并执行括起来的名命令.左括号和右括号不论出现在命令行中的什么位置,shell都会&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;认为它们具有特殊的组合意义的.只有用双引号将它们括起来引用,才表示圆括号或花括号&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;的原义.例如:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo a(b)&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;将出现语法上的错误,要想输出a(b)字符串 只能括起来&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo &amp;quot;a(b)&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;或echo a&amp;quot;(&amp;quot;b&amp;quot;&amp;quot;&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;这样才能被shell正确解释.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;利用组合命令有什么作用呢?&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;一,用圆括号组合命令&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;圆括号的组合命令可以创建子进程运行组合程序,建立子进程的功能是很有用的,因为&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;子shell在组合命令中的种种操作都不会影响到当前shell的各变量的值.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;例如:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;子进程在执行组合命令时改变了工作目录,并在新的工作目录下执行一系例命令,执行&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;完后它可以不必返回原工作目录,因为子进程工作目录的改变不会影响到当前工作目录.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;创建子进程后将当前的环境也同样传给子shell,当前shell中用export输出到环境中的&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;各变量在子shell中同样有效.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;花括号也可以将命令组合在一起.左 右花括号只有作为一条命令的第一个字出现时,&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;shell才它们含有特殊含义.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;与圆括号不同的是花括号并不创建子shell,只是由当前的shell来读取并执行括起来的&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;命令.有时用户希望使用一组命令的顺序输出作为另一组命令的输入,此时用花括号是很方&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;便的.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;不论是用圆括号不是花括号,退出状态都是等于最后一条括起来的命令的退出状态.&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;二,可以在当前shell中执行的命令&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;用户在使用shell时一定要了解那些是可以在当前shell中执行的命令 那些不可以&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;可以在当前shell中执行的命令有:&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;break case cd continue&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;echo eval exec exit&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;export for if read&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;readonly return set shift&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;test times trap umask&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;until wait while&amp;nbsp;&lt;/span&gt;&lt;br style=&quot;color: rgb(102, 102, 102); font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; white-space: normal; widows: 2; background-color: rgb(255, 255, 255);&quot;/&gt;&lt;span style=&quot;color: #666666; font-family: Arial, Verdana; font-size: 12px; font-variant-ligatures: normal; orphans: 2; widows: 2; background-color: #FFFFFF;&quot;&gt;: {}&lt;/span&gt;</description><pubDate>Sun, 28 Aug 2005 16:52:38 +0800</pubDate></item></channel></rss>