Skip to content
Navigation Menu
{{ message }}
forked from supercooc/QREncoder
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
342 lines (330 loc) · 17.7 KB
/
Copy pathindex.php
File metadata and controls
342 lines (330 loc) · 17.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
<?php
function Goto301($URL)
{
if(strtolower($_SERVER['HTTP_HOST']) != strtolower($URL))
{
header('HTTP/1.1 301 Moved Permanently');
header('Location: http://'.$URL.$_SERVER['REQUEST_URI']);
exit();
}
}
Goto301("www.qrencoder.org");
?>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="keywords" content="闪尼二维码在线生成器,QREncoder,二维码,二维条形码,QR,Quick Response,生成" />
<meta name="description" content="QREncoder可以将文本、网址、电话、短信、邮件甚至名片等信息快速转换为二维条形码。二维条形码,简称二维码或QR(Quick Response)码,英文翻译为:Dimensional Bar Code。它可以存储数字、文本或者URL地址等信息。二维条形码解码需要专用的解码器,通常带有摄像头的手机都带有能够读取二维条形码的应用,如果您不明白某些参数的具体含义,请保持默认。" />
<meta name="author" content="kandisheng" />
<title>闪尼二维码在线生成器 - ShareAny QREncoder</title>
<!--
<link rel="shortcut icon" type="image/vnd.microsoft.icon" href="favicon.png">
<link href="style/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="script/jquery-1.7.1.min.js"></script>
<script language="javascript" type="text/javascript" src="script/bootstrap-tab.js"></script>
<script language="javascript" type="text/javascript" src="script/bootstrap-alert.js"></script>
-->
<!---->
<link rel="shortcut icon" type="image/vnd.microsoft.icon" href="http://qrencoder.sinaapp.com/favicon.png">
<link href="http://lib.sinaapp.com/js/bootstrap/2.0.3/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="http://lib.sinaapp.com/js/jquery/1.7.2/jquery.min.js"></script>
<script language="javascript" type="text/javascript" src="http://qrencoder.sinaapp.com/script/bootstrap-tab.js"></script>
<script language="javascript" type="text/javascript" src="http://qrencoder.sinaapp.com/script/bootstrap-alert.js"></script>
<!---->
<script language="javascript" type="text/javascript">
/*引用代码请说明出处,谢谢。*/
/*
url="http://qrencoder.sinaapp.com";
url1="http://qrencoder.sinaapp.com/";
if(location.href!=url && location.href!=url1)
{
this.location = url;
window.location.href= url;
}
*/
function share(title,content,url,img)
{
str="";
str+="<div class='btn-group'>";
str+="<a title='分享到新浪微博' class='btn btn-success' target='_blank' href='http://v.t.sina.com.cn/share/share.php?pic="+img+"&title="+title+"&url="+url+"&rcontent="+content+"'>分享到</a>";
str+="<a title='分享到新浪微博' class='btn btn-danger' target='_blank' href='http://v.t.sina.com.cn/share/share.php?pic="+img+"&title="+title+"&url="+url+"&rcontent="+content+"'>新浪微博</a>";
str+="<a title='分享到腾讯微博' class='btn btn-primary' target='_blank' href='http://v.t.qq.com/share/share.php?title="+title+"&pic="+img+"&url="+url+"'>腾讯微博</a>";
str+="<a title='分享到QQ空间和朋友网' class='btn btn-warning' target='_blank' href='http://sns.qzone.qq.com/cgi-bin/qzshare/cgi_qzshare_onekey?title="+title+"&pics="+img+"&url="+url+"'>QQ</a>";
//str+="<a class='btn' target='_blank' href='http://share.renren.com/share/buttonshare.do?title="+title+"&link="+url+"&rcontent="+content+"'>人人网</a>";
//str+="<a class='btn' target='_blank' href='http://www.kaixin001.com/repaste/share.php?rtitle="+title+"&rurl=="+url+"&rcontent="+content+"'>开心网</a>";
//str+="<a class='btn' target='_blank' href='http://www.douban.com/recommend/?title="+title+"&url="+url+"&rcontent="+content+"'>豆瓣</a>";
str+="</div>";
return str;
}
function tzcc()
{
this.location="#top";
window.location.href="#top";
document.getElementById('imagewidth').focus();
document.getElementById('imagewidth').select();
}
function checkurl(url)
{
if(!(url.substring(0,7)=="http://" || url.substring(0,8)=="https://"))
{
neirong="http://"+url;
}
else
{
neirong=url;
}
return neirong;
}
function hideall()
{
document.getElementById('noticefirst').style.display="none";
document.getElementById('notice').style.display="none";
document.getElementById('noticeerror').style.display="none";
document.getElementById('showqr').style.display="none";
}
function shengcheng(neirong)
{
document.getElementById('showqr').style.display="none";
document.getElementById('notice').style.display="none";
document.getElementById('noticeerror').style.display="none";
document.getElementById('noticefirst').innerHTML="<div class='progress progress-striped active'><div class='bar' style='width: 100%;'></div></div><div>正在生成二维码,请稍后……</div>";
document.getElementById('noticefirst').style.display="block";
imagewidth=document.getElementById('imagewidth').value;
imageheight=document.getElementById('imageheight').value;
imagebm=document.getElementById('imagebm').value;
imagerc=document.getElementById('imagerc').value;
imagemargin=document.getElementById('imagemargin').value;
if(imagemargin=="")
{
imagemargin="4";
}
if(imagewidth*imageheight>=300000)
{
hideall();
document.getElementById('noticeerror').innerHTML="尺寸太大!请 <a class='btn' onclick='tzcc()' href='#top' title='重新输入尺寸'>重新输入尺寸</a>";
document.getElementById('noticeerror').style.display="block";
tzcc();
}
else
{
image="https://chart.googleapis.com/chart?cht=qr&chs="+imagewidth+"x"+imageheight+"&choe="+imagebm+"&chld="+imagerc+"|"+imagemargin+"&chl="+neirong;
document.getElementById('showqr').innerHTML="<img style='margin-bottom:20px;' title='您的二维码' alt='图片加载失败,请重新生成' src='"+image+"' />";
var img = new Image();
img.src = image;
img.onload = function()
{
hideall();
document.getElementById('showqr').style.display="block";
document.getElementById('notice').innerHTML="<p>二维码生成成功! <a class='btn' href='"+image+"' target='_blank' title='立即下载'>立即下载</a> </p><p>"+share("我的二维码,用QREncoder制作的!QREncoder可以将文本、网址、电话、短信、邮件甚至名片等信息快速转换为二维条形码。","我的二维码,用QREncoder制作的!QREncoder可以将文本、网址、电话、短信、邮件甚至名片等信息快速转换为二维条形码。","http://qrencoder.sinaapp.com",encodeURIComponent(image))+"</p>";
document.getElementById('notice').style.display="block";
};
img.onerror = function()
{
hideall();
document.getElementById('noticeerror').innerHTML="二维码生成失败,可能是您输入的内容太多或者网速太慢,请重新生成。";
document.getElementById('noticeerror').style.display="block";
};
}
}
function shengchengtext()
{
neirong=document.getElementById('qrtext').value;
shengcheng(neirong);
}
function shengchengurl()
{
neirong=document.getElementById('qrurl').value;
neirong=checkurl(neirong);
shengcheng(neirong);
}
function shengchengtel()
{
neirong="tel:"+document.getElementById('qrtel').value;
shengcheng(neirong);
}
function shengchengsms()
{
neirong="sms:"+document.getElementById('qrsms').value;
neirong+=":"+document.getElementById('qrsmsnr').value
shengcheng(neirong);
}
function shengchengemail()
{
neirong="mailto:"+document.getElementById('qremail').value;
shengcheng(neirong);
}
function shengchengcard()
{
neirong="MECARD:N:"+document.getElementById('qrcardname').value+";";
neirong+="ADR:"+document.getElementById('qrcardadd').value+";";
neirong+="TEL:"+document.getElementById('qrcardtel').value+";";
neirong+="EMAIL:"+document.getElementById('qrcardmail').value+";";
neirong+="URL:"+checkurl(document.getElementById('qrcardurl').value)+";";
neirong+="NOTE:"+document.getElementById('qrcardnote').value+";";
//neirong+="TIL:"+"til"+";";//职位
//neirong+="DIV:"+"div"+";";//部门
//neirong+="COR:"+"COR"+";";//公司
neirong+=";";
shengcheng(neirong);
}
</script>
</head>
<body>
<div id="top"></div>
<div class="container">
<div class="navbar navbar-fixed-top">
<div class="navbar-inner">
<div class="container">
<ul class="nav">
<a class="brand" href="#" title="QREncoder">QREncoder</a>
<li class="divider-vertical"></li>
<li class="active000"><a href="#" title="闪尼二维码在线生成器">闪尼二维码在线生成器</a></li>
<li><a href="https://github.com/ShareAny/QREncoder" target="_blank" title="源代码">源代码</a></li>
<li><a href="http://www.shareany.com/about/" target="_blank" title="关于">关于</a></li>
<li class="divider-vertical"></li>
<li style="margin-top:10px;">
<!-- JiaThis Button BEGIN -->
<div id="ckepop">
<a href="http://www.jiathis.com/share?uid=895708" class="jiathis jiathis_txt" target="_blank"><img src="http://v3.jiathis.com/code/images/btn/v1/jiathis1.gif" border="0" /></a>
<!--<a class="jiathis_counter_style_margin:3px 0 0 2px"></a>-->
</div>
<!-- JiaThis Button END -->
</li>
</ul>
<ul class="nav pull-right">
<!--
<li class="divider-vertical"></li>
-->
<li>
<!--
<form action="http://www.googlecn.org/" method="get" name="formsearch" target="_blank" class="navbar-search pull-left">
<input type="text" name="s" id="s" class="search-query" placeholder="搜索" title="搜索">
<input class="search-query" type="submit" value="搜索" title="搜索">
</form>
-->
<form action="http://www.googlecn.org/" method="get" name="formsearch" target="_blank" class="navbar-search pull-left">
<input type="text" name="s" id="s" class="search-query" style="margin-top:-4px;" placeholder="在此输入要搜索的内容" title="在此输入要搜索的内容">
<input class="btn btn-primary" style="margin-top:1px;" type="submit" value="谷歌搜索" title="谷歌搜索">
</form>
</li>
</ul>
</div>
</div>
</div>
<div style="margin-top:60px;"></div>
<!--[if lte IE 6]>
<div class="alert alert-error">QREncoder不支持IE6及以下版本的浏览器,请及时<a href="http://chrome.google.com" target="_blank" title="升级您的浏览器">升级您的浏览器</a>。</div>
<![endif]-->
<div class="alert alert-success">
<a class="close" data-dismiss="alert" href="#" title="关闭">×</a>
<h4 class="alert-heading">QREncoder</h4>
<div style="text-indent:2em; margin-top:10px;">二维条形码,简称二维码或QR(Quick Response)码,英文翻译为:Dimensional Bar Code。它可以存储数字、文本或者URL地址等信息。二维条形码解码需要专用的解码器,通常带有摄像头的手机都带有能够读取二维条形码的应用,QREncoder可以将文本、网址、电话、短信、邮件甚至名片等信息快速转换为二维条形码。如果您不明白某些参数的具体含义,请保持默认。</div>
</div>
<div class="row">
<div class="span3">
<form id="thisform" name="thisform" method="post" action="" class="well">
<div class="alert alert-info" style="padding:10px; text-align:center; margin-bottom:10px;"><h4>全局设置</h4></div>
<label for="imagewidth">图片宽度(单位:像素):</label><input title="图片宽度(单位:像素)" style="width:170px;" name="imagewidth" type="text" id="imagewidth" value="547" size="5" maxlength="3" />
<label for="imageheight">图片高度(单位:像素):</label><input title="图片高度(单位:像素)" style="width:170px;" name="imageheight" type="text" id="imageheight" value="547" size="5" maxlength="3" />
<label for="imagemargin">图片边距(单位:像素):</label><input title="图片边距(单位:像素)" style="width:170px;" name="imagemargin" type="text" id="imagemargin" value="0" size="5" maxlength="3" />
<label for="imagebm">编码模式:</label>
<select name="imagebm" id="imagebm" style="width:180px;" title="编码模式">
<option value="UTF-8" selected="selected">UTF-8</option>
<option value="Shift_JIS">Shift_JIS</option>
<option value="ISO-8859-1">ISO-8859-1</option>
</select>
<label for="imagerc">容错等级:</label>
<select name="imagerc" id="imagerc" style="width:180px;" title="容错等级">
<option value="L">L(7%)</option>
<option value="M">M(15%)</option>
<option value="Q">Q(25%)</option>
<option value="H">H(30%)</option>
</select>
</form>
</div>
<div class="span5">
<div class="tabbable" style="height:340px;">
<ul class="nav nav-tabs">
<li class="active"><a href="#text" data-toggle="tab" title="文本">文本</a></li>
<li><a href="#url" data-toggle="tab" title="网址">网址</a></li>
<li><a href="#email" data-toggle="tab" title="邮件">邮件</a></li>
<li><a href="#tel" data-toggle="tab" title="电话">电话</a></li>
<li><a href="#sms" data-toggle="tab" title="短信">短信</a></li>
<li><a href="#card" data-toggle="tab" title="名片">名片</a></li>
</ul>
<div class="tab-content">
<div class="tab-pane active" id="text">
<form>
<p><textarea style="width:370px;" id="qrtext" name="qrtext" cols="" rows="14" class="span3" placeholder="请输入文本内容" title="请输入文本内容"></textarea></p>
<p><input type="button" name="tj" id="tj" value="立即生成二维码" onclick="shengchengtext()" class="btn btn-primary btn-large" title="立即生成二维码" /></p>
</form>
</div>
<div class="tab-pane" id="url">
<form>
<p>网址:<input style="width:331px;" name="qrurl" type="text" id="qrurl" value="" class="span3" placeholder="请输入网址" title="请输入网址" /></p>
<p><input type="button" name="tj1" id="tj1" value="立即生成二维码" onclick="shengchengurl()" class="btn btn-primary btn-large" title="立即生成二维码" /></p>
</form>
</div>
<div class="tab-pane" id="tel">
<form>
<p>电话号码:<input style="width:305px;" name="qrtel" type="text" id="qrtel" value="" class="span3" placeholder="请输入电话号码" title="请输入电话号码" /></p>
<p><input type="button" name="tj4" id="tj4" value="立即生成二维码" onclick="shengchengtel()" class="btn btn-primary btn-large" title="立即生成二维码" /></p>
</form>
</div>
<div class="tab-pane" id="sms">
<form>
<p>手机号码:<input style="width:305px;" name="qrsms" type="text" id="qrsms" value="" class="span3" placeholder="请输入手机号码" title="请输入手机号码" /></p>
<p>短信内容:<input style="width:305px;" name="qrsmsnr" type="text" id="qrsmsnr" value="" class="span3" placeholder="请输入短信内容" title="请输入短信内容" /></p>
<p><input type="button" name="tj5" id="tj5" value="立即生成二维码" onclick="shengchengsms()" class="btn btn-primary btn-large" title="立即生成二维码" /></p>
</form>
</div>
<div class="tab-pane" id="email">
<form>
<p>邮箱地址:<input style="width:305px;" name="qremail" type="text" id="qremail" value="" class="span3" placeholder="请输入邮箱地址" title="请输入邮箱地址" /></p>
<p><input type="button" name="tj2" id="tj2" value="立即生成二维码" onclick="shengchengemail()" class="btn btn-primary btn-large" title="立即生成二维码" /></p>
</form>
</div>
<div class="tab-pane" id="card">
<form>
<p>姓名:<input style="width:331px;" name="qrcardname" type="text" id="qrcardname" value="" class="span3" placeholder="请输入姓名" title="请输入姓名" /></p>
<p>电话:<input style="width:331px;" name="qrcardtel" type="text" id="qrcardtel" value="" class="span3" placeholder="请输入电话" title="请输入电话" /></p>
<p>邮箱:<input style="width:331px;" name="qrcardmail" type="text" id="qrcardmail" value="" class="span3" placeholder="请输入邮箱" title="请输入邮箱" /></p>
<p>网站:<input style="width:331px;" name="qrcardurl" type="text" id="qrcardurl" value="" class="span3" placeholder="请输入网址" title="请输入网址" /></p>
<p>地址:<input style="width:331px;" name="qrcardadd" type="text" id="qrcardadd" value="" class="span3" placeholder="请输入地址" title="请输入地址" /></p>
<p>备注:<input style="width:331px;" name="qrcardnote" type="text" id="qrcardnote" value="" class="span3" placeholder="请输入备注" title="请输入备注" /></p>
<p><input type="button" name="tj12" id="tj12" value="立即生成二维码" onclick="shengchengcard()" class="btn btn-primary btn-large" title="立即生成二维码" /></p>
</form>
</div>
</div>
</div>
</div>
<div class="span4">
<div id="noticefirst" class="alert alert-info">请点击"立即生成二维码"生成您的二维码。</div>
<div id="noticeerror" class="alert alert-error" style="display:none;">请点击"立即生成二维码"生成您的二维码。</div>
<div id="notice" class="alert alert-success" style="display:none;">请点击"立即生成二维码"生成您的二维码。</div>
<div id="showqr" style="text-align:center;"><img width="300" height="300" src="https://chart.googleapis.com/chart?cht=qr&chs=547x547&choe=UTF-8&chld=L|0&chl=http://qrencoder.sinaapp.com" title="http://qrencoder.sinaapp.com" /></div>
</div>
</div>
<div class="row">
<div class="span12">
<!--
<div class="well">
<div class="alert alert-info" style="padding:10px; text-align:center; margin-bottom:0px;"><h4>欢迎评论</h4></div>
<div id="pinglunla_here"></div><a href="http://pinglun.la/" id="logo-pinglunla">评论啦</a><script type="text/javascript" src="http://static.pinglun.la/md/pinglun.la.js" charset="utf-8"></script>
</div>
-->
<div class="alert alert-info" style="text-align:center">
CopyRight © <script language="JavaScript" type="text/javascript">document.write(new Date().getFullYear());</script> QREncoder All Rights Reserved.
</div>
</div>
</div>
<div style="display:none;">
<script type="text/javascript">var jiathis_config = {data_track_clickback:true};</script>
<script type="text/javascript" src="http://v3.jiathis.com/code/jia.js?uid=895708" charset="utf-8"></script>
<script type="text/javascript" src="http://tajs.qq.com/stats?sId=9680758" charset="UTF-8"></script>
<script src="http://s96.cnzz.com/stat.php?id=1041089&web_id=1041089" language="JavaScript"></script>
</div>
</body>
</html>
<!--By Candison November(http://www.kandisheng.com)-->
You can’t perform that action at this time.
