index.html
7.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
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<title>二维码生成 - {$site.name}</title>
<link href="__CDN__/assets/libs/bootstrap/dist/css/bootstrap.min.css" rel="stylesheet">
<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
<script src="http://apps.bdimg.com/libs/html5shiv/3.7/html5shiv.min.js"></script>
<script src="http://apps.bdimg.com/libs/respond.js/1.4.2/respond.js"></script>
<![endif]-->
</head>
<body>
<div class="container">
<h2>二维码生成</h2>
<hr>
<div class="well">
<form action="" method="post">
<div class="row">
<div class="col-md-4">
<div class="form-group">
<label class="control-label">文本内容</label>
<input type="text" name="text" class="form-control" placeholder="" value="http://www.example.com">
</div>
<div class="form-group">
<label class="control-label">标签</label>
<input type="text" name="label" placeholder="" class="form-control" value="示例文字">
</div>
<div class="form-group">
<label class="control-label">Logo</label>
<div class="form-inline">
<div class="radio">
<label>
<input type="radio" name="logo" id="logoyes" value="1">
显示(Logo地址在代码中修改)
</label>
</div>
<div class="radio">
<label>
<input type="radio" name="logo" id="logono" value="0" checked>
不显示
</label>
</div>
</div>
</div>
<div class="form-group">
<input type="submit" class="btn btn-info" />
<input type="reset" class="btn btn-default" />
</div>
</div>
<div class="col-md-2">
<div id="toastTypeGroup">
<label>标签水平位置</label>
<div class="form-group radio">
<label><input type="radio" name="labelalignment" value="left">左</label>
</div>
<div class="form-group radio">
<label><input type="radio" name="labelalignment" checked value="center">中</label>
</div>
<div class="form-group radio">
<label><input type="radio" name="labelalignment" value="right">右</label>
</div>
</div>
</div>
<div class="col-md-2">
<div class="form-group">
<div class="form-group">
<label class="control-label">前景色</label>
<input type="text" name="foreground" placeholder="" class="form-control" value="#000000">
</div>
<div class="form-group">
<label class="control-label">背景色</label>
<input type="text" name="background" placeholder="" class="form-control" value="#ffffff">
</div>
<div class="form-group">
<label class="control-label">大小</label>
<input type="number" name="size" placeholder="" class="form-control" value="300">
</div>
<div class="form-group">
<label class="control-label">内边距</label>
<input type="number" name="padding" placeholder="" class="form-control" value="10">
</div>
</div>
</div>
<div class="col-md-3">
<div class="form-group">
<label class="control-label">Logo大小</label>
<input type="number" name="logosize" placeholder="" class="form-control" value="50">
</div>
<div class="form-group">
<label class="control-label">标签大小</label>
<input type="number" name="labelfontsize" placeholder="" class="form-control" value="14">
</div>
<div class="form-group">
<div id="positionGroup">
<label>容错级别</label>
<div class="form-group radio">
<label>
<input type="radio" name="errorcorrection" value="low">低
</label>
</div>
<div class="form-group radio">
<label>
<input type="radio" name="errorcorrection" value="medium" checked="">中等
</label>
</div>
<div class="form-group radio">
<label>
<input type="radio" name="errorcorrection" value="quartile">高
</label>
</div>
<div class="form-group radio">
<label>
<input type="radio" name="errorcorrection" value="high">超高
</label>
</div>
</div>
</div>
</div>
</div>
</form>
</div>
<input type="text" class="form-control" id='qrcodeurl' />
<img src="" alt="" id='qrcodeimg' />
</div>
<script src="__CDN__/assets/libs/jquery/dist/jquery.min.js"></script>
<script type="text/javascript">
$(function () {
$("form").submit(function () {
$("#qrcodeimg").prop("src", "{:addon_url('qrcode/index/build',[],false)}?" + $(this).serialize());
$("#qrcodeurl").val("{:addon_url('qrcode/index/build',[],false,true)}?" + $(this).serialize());
return false;
});
$("form").trigger('submit');
});
</script>
</body>
</html>