最新下载
热门教程
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
实现网址的自动识别
时间:2022-07-02 12:08:25 编辑:袖梨 来源:一聚教程网
public static string Auto(string str)
//========================//
// www.
// http://
// ftp://
// [email protected]
// mms://
//========================//
{
Reg = new Regex("([^]=>])(http://*[*A-Za*-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"$1");
Reg = new Regex("^(http://*[*A-Za*-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"");
Reg = new Regex("(http://*[*A-Za*-z0-9./=?%-&_~`@':+!]+)$");
str = Reg.Replace(str,"");
Reg = new Regex("([^]=>])(ftp://[A-Za-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"$1");
Reg = new Regex("^(ftp://[A-Za-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"");
Reg = new Regex("(ftp://[A-Za-z0-9./=?%-&_~`@':+!]+)$");
str = Reg.Replace(str,"");
Reg = new Regex("([^]=>])(mms://[A-Za-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"$1");
Reg = new Regex("^(mms://[A-Za-z0-9./=?%-&_~`@':+!]+)");
//========================//
// www.
// http://
// ftp://
// [email protected]
// mms://
//========================//
{
Reg = new Regex("([^]=>])(http://*[*A-Za*-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"$1");
Reg = new Regex("^(http://*[*A-Za*-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"");
Reg = new Regex("(http://*[*A-Za*-z0-9./=?%-&_~`@':+!]+)$");
str = Reg.Replace(str,"");
Reg = new Regex("([^]=>])(ftp://[A-Za-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"$1");
Reg = new Regex("^(ftp://[A-Za-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"");
Reg = new Regex("(ftp://[A-Za-z0-9./=?%-&_~`@':+!]+)$");
str = Reg.Replace(str,"");
Reg = new Regex("([^]=>])(mms://[A-Za-z0-9./=?%-&_~`@':+!]+)");
str = Reg.Replace(str,"$1");
Reg = new Regex("^(mms://[A-Za-z0-9./=?%-&_~`@':+!]+)");
相关文章
- 迅雷会员激活码免费领取渠道-迅雷会员激活码2026最新合集 03-07
- Zlibrary中文镜像站-zlibrary电子书下载 03-07
- 漫画歪歪-歪歪漫画首页入口 03-07
- libvio免费看剧指南-libvio追剧网页版官网直达入口 03-07
- twitter网页版免登录体验-twitter网页极速畅览 03-07
- 微信视频号官网网页版-视频号助手电脑版登录 03-07