● 编译文件
工具栏 -> 配置用户工具 -> 用户工具
选择工具组1,添加工具,命令中选择一个批处理文件。
这个批处理文件编译相关cs文件
设置初始目录,这点很重要。
批处理文件:
@Echo Off
%systemRoot%\Microsoft.NET\Framework\v2.0.50727\csc.exe /t:library /out:.\MD5.dll .\*.cs
"C:\Program Files\Internet Explorer\iexplore.exe" http://localhost/
● 添加到工具栏
工具 -> 参数选择 -> 工具栏
按钮选择用户,工具栏选择标准,将指定的用户工具添加到右侧。
<a href="http://wpa.qq.com/msgrd?V=1&Uin=10000&Site=在线咨询&Menu=no" target="_blank"><img border="0" src="http://wpa.qq.com/pa?p=1:10000:1" alt="点击这里给我发消息"></a>
<div style="width:300px;">
<div id="Left" style="float:left;background-color:blue;">1<br/>3<br/>5<br/></div>
<div id="Right" style="float:right;background-color:red;">2</div>
</div>
<script language="javascript">
AdjustHeight();
function AdjustHeight()
{
var heightLeft = document.getElementById('Left').offsetHeight;
var heightRight = document.getElementById('Right').offsetHeight;
if (heightLeft > heightRight)
{
document.getElementById('Right').style.height = heightLeft;
}
else
{
document.getElementById('Left').style.height = heightRight;
}
}
</script>
=?gb2312?B?xOO6w6Oh?=
=? ?= 两个标记括起来
GB2312 是字符集
后面的一个 B 表示的是用的 Base64 编码
另一种方法是QP(Quote-Printable) 方法,通常缩写为“Q”方法,其原理是把一个 8 bit 的字符用两个16进制数值表示,然后在前面加“=”。所以我们看到经过QP编码后的文件通常是这个样子:=B3=C2=BF=A1=C7=E5=A3=AC=C4=FA=BA=C3=A3=A1。
实现鼠标经过显示层,鼠标离开不显示层的效果
几个关键点
1. position:relative、position:absolute
2. onmouseover、onmouseout
-------------------------
<style>
#DivCityFrame{ position: relative; z-index:20; }
#DivCity { position:absolute; top:15px; left:15px; width:200px; }
#DivCity { background:white; border:1px solid red; z-index:100; display:none;}
</style>
<div style="height:30px; background-color:#5507AA;"></div>
<table>
<tr>
<td width="300"></td>
<td>
<div id="DivCityFrame">
<span onmouseover="ShowDivCity();" onmouseout="HiddenDivCity();">显示城市</span>
<div id="DivCity" onmouseover="ShowDivCity();" onmouseout="HiddenDivCity();">
<ul><li>a</li><li>b</li><li>c</li><li>d</li></ul>
</div>
</td>
</tr>
</table>
<div style="height:30px; background-color:#5507AA;"></div>
<script>
function ShowDivCity()
{
document.getElementById("DivCity").style.display= "block";
}
function HiddenDivCity()
{
document.getElementById("DivCity").style.display = "none";
}
</script>
在用HttpWebRequest请求有些网页时,会发生“远程服务器返回错误: (501) 未实现。”
这个错误一般指服务器不支持HTTP方法所要求的客户。
可以试着给HttpWebRequest指定一个UserAgent。
如下:
httpWebRequest.UserAgent = "Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.2; Potu-WebBrowser www.potu.com; .NET CLR 1.1.4322; .NET CLR 2.0.50727)";