forked from surmoun/Short_Video-API
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
182 lines (162 loc) · 5.96 KB
/
index.html
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
<!DOCTYPE html>
<html>
<head>
<title>抖音去水印</title>
<meta name="referrer" content="never">
<meta charset="UTF-8">
<meta content='抖音,短视频,去水印,删水印,原始视频,去LOGO,删LOGO,原视频' name='Keywords'>
<meta name="viewport"
content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
<meta content='抖音一键去水印,粘贴抖音分享链接,一键获取原始视频下载地址!' itemprop='description' name='Description'>
<link rel="stylesheet" href="static/css/element.css">
<style>
body,
html {
padding: 0;
margin: 0;
background-color: #f5f5f5;
/*overflow: hidden;*/
}
* {
font-family: consolas, PingFang SC, Microsoft YaHei;
}
[v-cloak] {
visibility: hidden !important;
}
.search {
text-align: center;
padding-top: 120px;
z-index: 99;
}
.search .form {
width: 80%;
max-width: 500px;
margin-top: 30px;
}
.search .logo {
text-align: center;
display: block;
font-size: 44px;
color: #999;
font-weight: bold;
}
.search .logo img {
width: 400px;
}
.search .link {
margin-top: 20px;
}
.success {
text-align: center;
padding-top: 20px;
z-index: 99;
}
.about{
position:fixed;
right:20px;
left:20px;
bottom:30px;
text-align: center;
}
</style>
</head>
<body>
<div id="app" v-cloak v-loading.fullscreen.lock="fullscreenLoading">
<div class="search">
<div class="logo">
<font color=orangered>D</font>ouyin <font color=orangered>C</font>lear
</div>
<el-input autoFocus="true" id="keyword" ref="keyword" v-model="keyword" placeholder="请粘贴抖音复制的链接..."
class="form" size="large">
<el-button slot="append" icon="el-icon-search" @click="doPost">去水印</el-button>
</el-input>
</div>
<div class="success" v-show="successShow">
<div style="color: rgb(49, 112, 143);padding: 15px">
{{type}}
<p v-if="type=='photo'">
<!--{{successMessage}}-->
<img v-for="(item,i) in successMessage" :src=item height="200px" width="200px"style=""/>
</p>
<p v-else-if="type=='movie'">
<!--{{successMessage}}-->
<video width="320" height="240" controls>
<source :src=successMessage type="video/mp4">
</video>
</p>
</div>
<p v-if="type=='movie'">
<el-button v-if="!needRefresh" type="success"><a :href="videoUrl"
style="text-decoration:none;color: #ffffff" target="_blank">查看视频</a></el-button>
<el-button v-if="needRefresh" class="copy" type="primary" v-clipboard:copy="videoUrl"
v-clipboard:success="onCopySuccess" v-clipboard:error="onCopyError">复制链接</el-button>
</p>
<el-button type="danger" @click="clear">清空</el-button>
</div>
</div>
</body>
<script src="static/js/vue-2.6.10.min.js"></script>
<script src="static/js/axios.min.js"></script>
<script src="static/js/element.js"></script>
<script src="static/js/vue-clipboard.min.js"></script>
<script>
new Vue({
el: '#app',
data() {
return {
keyword: '',
fullscreenLoading: false,
videoUrl: '',
successShow: false,
successMessage: '',
needRefresh: false,
type:''
}
},
created() {
},
updated() { },
methods: {
doPost() {
var that = this;
that.fullscreenLoading = true;
axios.post('https://www.ujrv.cn/api/jxindex.php?url='+that.keyword)
.then(function (response) {
that.successShow= false;
that.fullscreenLoading = false;
console.log(response.data);
if (response.status == 200) {
that.successShow = true;
that.videoUrl = response.data.message.video_url;
that.successMessage = response.data.message.video_url;
that.type = response.data.message.type;
that.needRefresh = false;
} else if (response.data.code == 301) {
that.successShow = true;
that.videoUrl = response.data.data;
that.successMessage = response.data.msg;
that.needRefresh = true;
} else {
that.$message.error(response.data.msg);
}
})
.
catch(function (error) {
console.log(error)
that.$message.error('出现异常,你可以控制台查看错误');
});
},
clear() {
this.keyword = '';
this.successShow = false
},
onCopySuccess(e) {
this.$message({ message: '复制成功!', type: 'success' });
},
onCopyError(e) {
this.$message.error('复制失败!');
}
}
});
</script>
</html>