getdata
public partial class GetData : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
//string path = Server.MapPath("~/css/css.css");
//using (StreamReader sr = new StreamReader(path))
//{
// string all_code = sr.ReadToEnd();
// ArrayList my_list = new ArrayList();
// //string p = @"http://([\w-]+\.)+[\w-]+(/[\w- ./?%&=]*)?";
// string p = @"background\:url\((?<ImgUrl>.*?)\)";
// //string p = @"(?<=\b(?:src\s*=\s*['""]?|background:\s*.*?\burl\b\()(?!http:))/?([^'""\s\)]+)";
// Regex re = new Regex(p, RegexOptions.IgnoreCase);
// MatchCollection mc = re.Matches(all_code);
// for (int i = 0; i <= mc.Count - 1; i++)
// {
// bool _foo = false;
// string name = "http://d1mr.com/" + mc[i].ToString().TrimEnd(')').Replace("background:url(", "");
// //string name = mc[i].ToString();
// foreach (string list in my_list)
// {
// if (name == list)
// {
// _foo = true;
// break;
// }
// }//过滤
// if (!_foo)
// {
// try
// {
// WebClient wc = new WebClient();
// wc.DownloadFile(name, Server.MapPath("~/images") + @"\" + Path.GetFileName(name));
// }
// catch (Exception ex)
// {
// }
// //images
// //Response.Write(name + "\n");
// }
// }
//}
//string path = Server.MapPath("~/images1");
//foreach (string item in Directory.GetFiles(path))
//{
// //string pageHtml = LeYour.Common.WebCatcher.GetPageData("http://localhost:3333/经典香氛_美容健康_YOKA时尚网.htm");
// string pageHtml = LeYour.Common.WebCatcher.GetPageData("http://localhost:3333/shoumm/" + Path.GetFileName(item));
// Regex searchTitle = new Regex("<title>(?<title>[\\s\\S]*?)<\\/title>", RegexOptions.IgnoreCase);
// Match oM = searchTitle.Match(pageHtml);
// if (oM.Success)
// {
// Response.Write(oM.Groups["title"].Value.Trim());
// string matchEvents = "<table width=\"600\" border=\"0\" cellpadding=\"3\".*?</table>";
// string Content = Regex.Match(pageHtml, matchEvents, RegexOptions.Singleline).Value;
// if (!string.IsNullOrEmpty(Content))
// {
// ICommon common = CommonProxy.GetProxy("MeiRong.MeiRong_Temp", "ID");
// Dictionary<string, object> dict = new Dictionary<string, object>();
// dict.Add("Title", oM.Groups["title"].Value.Trim());
// dict.Add("Content", Content);
// dict.Add("CreateTime", DateTime.Now);
// common.Insert(dict);
// //Response.Write(Events);
// }
// }
//}
//string matchEvents = "(<table width=\"600\" border=\"0\" cellpadding=\"3\".*?</table>)(?:\\s*<div align=\"center\">)";
// string path = Server.MapPath("~/hufu[1].txt");
// using (StreamReader sr = new StreamReader(path))
// {
// string all_code = sr.ReadToEnd();
// ArrayList my_list = new ArrayList();
// string p = @"http://([\w-]+\.)+[\w-]+(/[\w- ./?%&=]*)?";
// Regex re = new Regex(p, RegexOptions.IgnoreCase);
// MatchCollection mc = re.Matches(all_code);
// for (int i = 0; i <= mc.Count - 1; i++)
// {
// bool _foo = false;
// string name = mc[i].ToString();
// foreach (string list in my_list)
// {
// if (name == list)
// {
// _foo = true;
// break;
// }
// }//过滤
// if (!_foo)
// {
// try
// {
// WebClient wc = new WebClient();
// wc.DownloadFile(name, Server.MapPath("~/images") + @"\" + Path.GetFileName(name));
// }
// catch
// {
// }
// //images
// //Response.Write(name + "\n");
// }
// }
// }
}
getdata的更多相关文章
- dataTransfer.getData()在dragover,dragenter,dragleave中无法获取数据的问题
做拖拽相关效果时,想在ondragover时给被拖拽元素添加一些样式,于是在dragover事件的函数中通过dataTransfer.getData()获取在dragstart中设置的数据,然而发现d ...
- [DFNews] GetData也出取证软件了
从事计算机取证的应该都听说过MIP(Mount Image Pro).VFC仿真和Recover My Files,上述三个应用比较广泛的软件都是GetData公司的产品.GetData现在也推出了自 ...
- EasyUI datagrid数据表格的函数getData返回来的是什么
EasyUI datagrid数据表格的函数getData返回来的是什么? 他返回来的是这么一个对象: Object { rows=[10], total=15} 其中rows就是每一行的数据,是这些 ...
- 在jQuery.getData中renderCallback使用不同创建方式的结果
JavaScript 中需要创建函数的话,有两种方法:函数声明.函数表达式,各自写法如下:// 方法一:函数声明function foo() {}// 方法二:函数表达式var foo = funct ...
- 用jquery设置的值,miniui.getData取不到
用jquery设置的值,miniui.getData取不到
- android 手机拍照返回 Intent==null 以及intent.getData==null
手机拍照第一种情况:private void takePicture(){ Intent intent = new Intent(MediaStore.ACTION_IMAGE_CAPTURE);Si ...
- :c#的remoting里,CallContext.GetData获得的对象老是空的?该怎么处理
寻求帮助:c#的remoting里,CallContext.GetData获得的对象老是空的?如题,检查了很多次了,也比对了msdn里的例子,没觉得有问题啊..为什么老是得到的null的?不知道哪里出 ...
- 9.使用GetData,Children实现对ZNode的监控
一. zookeeper中的watcher 1. exists :监控的是[znode]的CUD 的操作 2. getdata 的时候注册的watcher[U,D 监控]update delete ...
- js【面向过程编程】、好、 【init()、 GetData()、 bindData()、bindDom、 bindEvent()、buyProduct()、AddProductToCart()】*****************
1. 一般页面开发方式 [可读性差.可维护性差]------初级开发工程师 一般页面编写方法 var name = 'iphone8' var description = '手机中的战斗机 ' var ...
随机推荐
- Android Studio如何添加override
而Android Studio如何添加呢?方法如下: 右键(或者Alt + Insert) --- Generate... ---- Override Method... 或者 Implement ...
- Hadoop学习地址
hortonworks: http://zh.hortonworks.com/hdp/downloads/ http://zh.hortonworks.com/hadoop-tutorial/supe ...
- [转]PO和VO、关于延迟加载(lazy)和强制加载(Hibernate.initialize(Object proxy) )
摘自http://www.cnblogs.com/kelin1314/archive/2009/11/13/1602778.html PO和VO PO 即Persistence Object VO 即 ...
- Struts2 - Interceptor中取得ActionName、Namespace、Method
在Struts2的Interceptor中取得当前执行对应的ActionName.Namespace.Method方法: 可以使用: System.out.println(invocation.get ...
- UI—代理简单使用
代理:又叫委托 通俗的说是自己不能办的事 委托给别人去办.比如UITextField,UIAlertView都使用了代理 写代理的步骤: 1.声明代理里面的协议方法(@protocl) 2.声明协议的 ...
- SPOJ #691. Hotel Floors
A typical flood-fill algorithm application (BFS). Not very complex, except only 1 tip: instead of se ...
- shell和vim的配色
shell的默认配色 mac,需要用iTerm2, 选自带的solarized即可 debian ,选择自带的 solarized dark vim配色 git clone git://github. ...
- SVN服务器几种备份策略---重点svnsync备份---OK
配置管理的一个重要使命是保证数据的安全性,防止服务器应硬盘损坏.误操作造成数据无法恢复的灾难性后果.因此制定一个完整的备份策略非常重要. 一般来说,备份策略应规定如下几部分内容:备份频度.备份方式.备 ...
- (三)java的数据类型
java是一种强类型的语言,所谓强类型,意味着每个变量都要有确定的类型,每个表达式也要有明确的类型,包括传递的某些参数.java中从大的方面分有两大数据类型,分别是基本数据类型和引用数据类型,基本数据 ...
- 导航栏4种效果---原生js
<!doctype html> <html> <head> <meta charset="utf-8"> <title> ...