利用网易免费短地址接口开发的短网址缩短服务
演示地址:
http://3.tbip.sinaapp.com/
伪静态规则
RewriteEngine on
RewriteRule ^(.*)$ index.php?id=$1 [L]
- define('REWRITE', '0'); //是否启用伪静态 1为启用0为不启用
- define('IS_SINA', '0'); //是否sina sae 1为启用0为不启用
- define('API_KEY', '2e409ff7a967418aa5e4dd15051702ba'); //API key请自行申请
- $weburl=getenv('SERVER_NAME').dirname(getenv('SCRIPT_NAME'));
- $weblink=REWRITE?"http://".$weburl."/":"http://".$weburl."/?";
- if($_GET['url']){
- $data=duanurl($_GET['url']);
- $shorturls=str_replace('126.am/',$weblink,$data->url);
- }else if(count($_GET)>0){
- $headurl=getenv("QUERY_STRING");echo "<script>location.href='http://126.am/".$headurl."'</script>";
- }
- ?>?
- 网易免费短地址
- a:link {color:#666;}
- a:visited {text-decoration: none;color: #333;}
- a:hover {text-decoration: none; color: #333;}
- a:active {text-decoration: none;color: #CCC;}
- body{margin:0px;background:url(bg_body.jpg) repeat-x;height:100%;text-align: center;}
- .warp{margin:0 auto;width:620px;}img{border:none;}.c{clear:both;}.l{float:left;}.r{float:right;}ul,li{list-style:none;}
- .main{margin:0 auto;width:620px;}
- .logo{margin:20px auto;text-align:center;}
- .logo a{font-size:50px}
- .main p{text-align:center;color:#999;font-size:14px;}
- .area{padding:10px;background:#f1f7f8;border:1px solid #cfe0e0;}
- .text_are{float:left;width:440px;height:36px;padding:5px 0;border:1px solid #c6c6c6;font-size:16px;background:#ffffe6;}
- .text_btn{float:left;margin-top:-1px;width:86px;height:36px;border:1px solid #c6c6c6;background:#f8f8f8;}
- .list{float:left;margin-top:-1px;padding:9px;border:1px solid #cfe0e0;background:#FFF;font-size:12px;color:#999;}
- .list td{padding:3px 5px;border-bottom:1px solid #e1edef;height:30px;}
- .more a{color:#333;text-decoration:none;}
- .footer{margin-top:15px;font-size:11px;color:#CCC;text-align:center;}
-
-
-
- <script>var bdShare_config = {"type":"large","color": "blue","uid":"533431","share" :"yes"};<li>document.getElementById("bdlike_shell").src="http://bdimg.share.baidu.com/static/ js/like_shell.js?t=" + new Date(). getHours();<li></script>
|
本網站聲明
本文內容由網友自願投稿,版權歸原作者所有。本站不承擔相應的法律責任。如發現涉嫌抄襲或侵權的內容,請聯絡admin@php.cn
作者最新文章
-
2024-10-22 09:46:29
-
2024-10-13 13:53:41
-
2024-10-12 12:15:51
-
2024-10-11 22:47:31
-
2024-10-11 19:36:51
-
2024-10-11 15:50:41
-
2024-10-11 15:07:41
-
2024-10-11 14:21:21
-
2024-10-11 12:59:11
-
2024-10-11 12:17:31