├── assets ├── img │ ├── dots.png │ └── favicon.ico ├── fonts │ ├── nucleo.eot │ ├── nucleo.ttf │ ├── nucleo.woff │ └── nucleo.woff2 ├── js │ ├── main.js │ ├── blk-design-system.min.js │ └── popper.min.js └── css │ └── nucleo-icons.css ├── README.md ├── api.php └── index.html /assets/img/dots.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuhuai66/pt-dwz/HEAD/assets/img/dots.png -------------------------------------------------------------------------------- /assets/fonts/nucleo.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuhuai66/pt-dwz/HEAD/assets/fonts/nucleo.eot -------------------------------------------------------------------------------- /assets/fonts/nucleo.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuhuai66/pt-dwz/HEAD/assets/fonts/nucleo.ttf -------------------------------------------------------------------------------- /assets/img/favicon.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuhuai66/pt-dwz/HEAD/assets/img/favicon.ico -------------------------------------------------------------------------------- /assets/fonts/nucleo.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuhuai66/pt-dwz/HEAD/assets/fonts/nucleo.woff -------------------------------------------------------------------------------- /assets/fonts/nucleo.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/xuhuai66/pt-dwz/HEAD/assets/fonts/nucleo.woff2 -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ### 开源目的 2 | 3 | 因为自己的业务需要短链,用别人的总有各种的不满意,就自己写了一个整合版的 4 | 5 | ### 在线演示 6 | 7 | [http://dwz.zhai78.com/][1] 8 | 9 | ### 样式预览 10 | 11 | ![预览图][2] 12 | 13 | ### 安装步骤 14 | 15 | 直接上传到你的空间即可,要求php环境 16 | 17 | ### 添加接口 18 | 19 | 1. index.html中,添加网址单选 20 | 2. api.php中,添加短链接口 21 | 22 | ### 联系本人 23 | 24 | > wx: xuhuai66 25 | 26 | 27 | [1]: http://dwz.zhai78.com/ 28 | [2]: https://s1.ax1x.com/2020/07/09/Un7NOe.png -------------------------------------------------------------------------------- /assets/js/main.js: -------------------------------------------------------------------------------- 1 | /* 2 | ========================================================= 3 | * PT短网址- v1.0.0 4 | ========================================================= 5 | * Product Page: https://github.com/xuhuai66/pt-dwz 6 | * Copyright 2020 Xuhuai (https://www.zhai78.com) 7 | * Coded by Xuhuai 8 | */ 9 | function getBoard() { 10 | navigator.clipboard.readText().then(text => { 11 | $("#inputContent").val(text); 12 | }).catch(err => { 13 | document.getElementById('errorTips').innerHTML = '您未授予权限获取您的剪切板内容'; 14 | $('#errPop').modal('show') 15 | }); 16 | } 17 | 18 | function initial() { 19 | document.getElementById('copyLink').innerText = '复制链接'; 20 | $('#resultBox').css('display', 'none'); 21 | $('#desBox').css('display', 'block'); 22 | $('#loadingBox').css('display', 'block'); 23 | } 24 | 25 | function checkUrl(url, type) { 26 | var url_test = /^(http|https):\/\/.*$/i.test(url); 27 | if (!url_test) { 28 | document.getElementById('errTip').innerText = '链接有误请检查后再提交'; 29 | $('#errPop').modal('show'); 30 | } else { 31 | initial() 32 | urlType = $('input[name=urlType]:checked').val(); 33 | $.post('/api.php', { type: type, kind: urlType, url: url }, function(data) { 34 | $('#loadingBox').css('display', 'none'); 35 | if (data.status == 1) { 36 | document.getElementById('resultLink').innerText = data.url; 37 | $('#resultBox').css('display', 'block'); 38 | $('#desBox').css('display', 'none'); 39 | } else { 40 | document.getElementById('errTip').innerText = '转换失败'; 41 | $('#errPop').modal('show'); 42 | } 43 | }); 44 | } 45 | } 46 | 47 | function setBoard() { 48 | var clipboard = new ClipboardJS("#copyLink"); 49 | clipboard.on("success", function(element) { //复制成功的回调 50 | document.getElementById('copyLink').innerText = '复制成功'; 51 | console.info("复制成功,复制内容: " + element.text); 52 | }); 53 | clipboard.on("error", function(element) { //复制失败的回调 54 | console.info(element); 55 | }); 56 | } 57 | $(function() { 58 | setBoard(); 59 | }); -------------------------------------------------------------------------------- /api.php: -------------------------------------------------------------------------------- 1 |
' }) }); 49 | var a = document.getElementById("square1"), 50 | t = document.getElementById("square2"), 51 | o = document.getElementById("square3"), 52 | n = document.getElementById("square4"), 53 | r = document.getElementById("square5"), 54 | l = document.getElementById("square6"), 55 | s = document.getElementById("square7"), 56 | i = document.getElementById("square8"); 57 | 0 != $(".square").length && $(document).mousemove(function(e) { posX = event.clientX - window.innerWidth / 2, posY = event.clientY - window.innerWidth / 6, a.style.transform = "perspective(500px) rotateY(" + .05 * posX + "deg) rotateX(" + -.05 * posY + "deg)", t.style.transform = "perspective(500px) rotateY(" + .05 * posX + "deg) rotateX(" + -.05 * posY + "deg)", o.style.transform = "perspective(500px) rotateY(" + .05 * posX + "deg) rotateX(" + -.05 * posY + "deg)", n.style.transform = "perspective(500px) rotateY(" + .05 * posX + "deg) rotateX(" + -.05 * posY + "deg)", r.style.transform = "perspective(500px) rotateY(" + .05 * posX + "deg) rotateX(" + -.05 * posY + "deg)", l.style.transform = "perspective(500px) rotateY(" + .05 * posX + "deg) rotateX(" + -.05 * posY + "deg)", s.style.transform = "perspective(500px) rotateY(" + .02 * posX + "deg) rotateX(" + -.02 * posY + "deg)", i.style.transform = "perspective(500px) rotateY(" + .02 * posX + "deg) rotateX(" + -.02 * posY + "deg)" }), blackKit.initNavbarImage(), $navbar = $(".navbar[color-on-scroll]"), scroll_distance = $navbar.attr("color-on-scroll") || 500, 0 != $(".navbar[color-on-scroll]").length && (blackKit.checkScrollForTransparentNavbar(), $(window).on("scroll", blackKit.checkScrollForTransparentNavbar)), $(".form-control").on("focus", function() { $(this).parent(".input-group").addClass("input-group-focus") }).on("blur", function() { $(this).parent(".input-group").removeClass("input-group-focus") }), $(".bootstrap-switch").each(function() { $this = $(this), data_on_label = $this.data("on-label") || "", data_off_label = $this.data("off-label") || "", $this.bootstrapSwitch({ onText: data_on_label, offText: data_off_label }) }), $(".carousel").carousel({ interval: !1 }) 58 | }), $collapse.length && ($collapse.on({ "hide.bs.collapse": function() { hideNavbarCollapse($collapse) } }), $collapse.on({ "hidden.bs.collapse": function() { hiddenNavbarCollapse($collapse) } })), $(document).on("click", ".navbar-toggler", function() { $toggle = $(this), 1 == blackKit.misc.navbar_menu_visible ? ($("html").removeClass("nav-open"), blackKit.misc.navbar_menu_visible = 0, $("#bodyClick").remove(), setTimeout(function() { $toggle.removeClass("toggled") }, 550)) : (setTimeout(function() { $toggle.addClass("toggled") }, 580), div = '', $(div).appendTo("body").click(function() { $("html").removeClass("nav-open"), blackKit.misc.navbar_menu_visible = 0, setTimeout(function() { $toggle.removeClass("toggled"), $("#bodyClick").remove() }, 550) }), $("html").addClass("nav-open"), blackKit.misc.navbar_menu_visible = 1) }), blackKit = { 59 | misc: { navbar_menu_visible: 0 }, 60 | checkScrollForTransparentNavbar: debounce(function() { $(document).scrollTop() > scroll_distance ? transparent && (transparent = !1, $(".navbar[color-on-scroll]").removeClass("navbar-transparent")) : transparent || (transparent = !0, $(".navbar[color-on-scroll]").addClass("navbar-transparent")) }, 17), 61 | initNavbarImage: function() { 62 | var e = $(".navbar").find(".navbar-translate").siblings(".navbar-collapse"), 63 | a = e.data("nav-image"); 64 | $(window).width() < 991 || $("body").hasClass("burger-menu") ? null != a && e.css("background", "url('" + a + "')").removeAttr("data-nav-image").css("background-size", "cover").addClass("has-image") : null != a && e.css("background", "").attr("data-nav-image", "" + a).css("background-size", "").removeClass("has-image") 65 | }, 66 | initDatePicker: function() { 0 != $datepicker.length && $datepicker.datetimepicker({ icons: { time: "tim-icons icon-watch-time", date: "tim-icons icon-calendar-60", up: "fa fa-chevron-up", down: "fa fa-chevron-down", previous: "tim-icons icon-minimal-left", next: "tim-icons icon-minimal-right", today: "fa fa-screenshot", clear: "fa fa-trash", close: "fa fa-remove" } }) }, 67 | initSliders: function() { 68 | var e = document.getElementById("sliderRegular"); 69 | 0 != $("#sliderRegular").length && noUiSlider.create(e, { start: 40, connect: [!0, !1], range: { min: 0, max: 100 } }); 70 | var a = document.getElementById("sliderDouble"); 71 | 0 != $("#sliderDouble").length && noUiSlider.create(a, { start: [20, 60], connect: !0, range: { min: 0, max: 100 } }) 72 | } 73 | }; 74 | //# sourceMappingURL=_site_kit_free/assets/js/kit-free.js.map -------------------------------------------------------------------------------- /assets/css/nucleo-icons.css: -------------------------------------------------------------------------------- 1 | /* -------------------------------- 2 | 3 | Nucleo Outline Web Font - nucleoapp.com/ 4 | License - nucleoapp.com/license/ 5 | Created using IcoMoon - icomoon.io 6 | 7 | -------------------------------- */ 8 | 9 | @font-face { 10 | font-family: 'Nucleo'; 11 | src: url('../fonts/nucleo.eot'); 12 | src: url('../fonts/nucleo.eot') format('embedded-opentype'), url('../fonts/nucleo.woff2') format('woff2'), url('../fonts/nucleo.woff') format('woff'), url('../fonts/nucleo.ttf') format('truetype'), url('../fonts/nucleo.svg') format('svg'); 13 | font-weight: normal; 14 | font-style: normal; 15 | } 16 | 17 | /*------------------------ 18 | base class definition 19 | -------------------------*/ 20 | 21 | .tim-icons { 22 | display: inline-block; 23 | font: normal normal normal 1em/1 'Nucleo'; 24 | vertical-align: middle; 25 | speak: none; 26 | text-transform: none; 27 | /* Better Font Rendering */ 28 | -webkit-font-smoothing: antialiased; 29 | -moz-osx-font-smoothing: grayscale; 30 | } 31 | 32 | .font-icon-detail { 33 | text-align: center; 34 | padding: 45px 0 30px; 35 | border: 1px solid #e44cc4; 36 | border-radius: .1875rem; 37 | margin: 15px 0; 38 | min-height: 168px; 39 | } 40 | 41 | .font-icon-detail i { 42 | color: #FFFFFF; 43 | font-size: 1.5em; 44 | } 45 | 46 | .font-icon-detail p { 47 | color: #e44cc4 !important; 48 | margin-top: 30px; 49 | padding: 0 10px; 50 | font-size: .7142em; 51 | } 52 | 53 | /*------------------------ 54 | change icon size 55 | -------------------------*/ 56 | 57 | .tim-icons-sm { 58 | font-size: 0.8em; 59 | } 60 | 61 | .tim-icons-lg { 62 | font-size: 1.2em; 63 | } 64 | 65 | /* absolute units */ 66 | 67 | .tim-icons-16 { 68 | font-size: 16px; 69 | } 70 | 71 | .tim-icons-32 { 72 | font-size: 32px; 73 | } 74 | 75 | /*---------------------------------- 76 | add a square/circle background 77 | -----------------------------------*/ 78 | 79 | .tim-icons-bg-square, 80 | .tim-icons-bg-circle { 81 | padding: 0.35em; 82 | } 83 | 84 | .tim-icons-bg-circle { 85 | border-radius: 50%; 86 | } 87 | 88 | /*------------------------ 89 | list icons 90 | -------------------------*/ 91 | 92 | /*------------------------ 93 | spinning icons 94 | -------------------------*/ 95 | 96 | .tim-icons-is-spinning { 97 | -webkit-animation: tim-icons-spin 2s infinite linear; 98 | -moz-animation: tim-icons-spin 2s infinite linear; 99 | animation: tim-icons-spin 2s infinite linear; 100 | } 101 | 102 | @-webkit-keyframes tim-icons-spin { 103 | 0% { 104 | -webkit-transform: rotate(0deg); 105 | } 106 | 100% { 107 | -webkit-transform: rotate(360deg); 108 | } 109 | } 110 | 111 | @-moz-keyframes tim-icons-spin { 112 | 0% { 113 | -moz-transform: rotate(0deg); 114 | } 115 | 100% { 116 | -moz-transform: rotate(360deg); 117 | } 118 | } 119 | 120 | @keyframes tim-icons-spin { 121 | 0% { 122 | -webkit-transform: rotate(0deg); 123 | -moz-transform: rotate(0deg); 124 | -ms-transform: rotate(0deg); 125 | -o-transform: rotate(0deg); 126 | transform: rotate(0deg); 127 | } 128 | 100% { 129 | -webkit-transform: rotate(360deg); 130 | -moz-transform: rotate(360deg); 131 | -ms-transform: rotate(360deg); 132 | -o-transform: rotate(360deg); 133 | transform: rotate(360deg); 134 | } 135 | } 136 | 137 | /*------------------------ 138 | rotated/flipped icons 139 | -------------------------*/ 140 | 141 | /*------------------------ 142 | icons 143 | -------------------------*/ 144 | 145 | .icon-alert-circle-exc::before { 146 | content: "\ea02"; 147 | } 148 | 149 | .icon-align-center::before { 150 | content: "\ea03"; 151 | } 152 | 153 | .icon-align-left-2::before { 154 | content: "\ea04"; 155 | } 156 | 157 | .icon-app::before { 158 | content: "\ea05"; 159 | } 160 | 161 | .icon-atom::before { 162 | content: "\ea06"; 163 | } 164 | 165 | .icon-attach-87::before { 166 | content: "\ea07"; 167 | } 168 | 169 | .icon-badge::before { 170 | content: "\ea08"; 171 | } 172 | 173 | .icon-bag-16::before { 174 | content: "\ea09"; 175 | } 176 | 177 | .icon-bank::before { 178 | content: "\ea0a"; 179 | } 180 | 181 | .icon-basket-simple::before { 182 | content: "\ea0b"; 183 | } 184 | 185 | .icon-bell-55::before { 186 | content: "\ea0c"; 187 | } 188 | 189 | .icon-bold::before { 190 | content: "\ea0d"; 191 | } 192 | 193 | .icon-book-bookmark::before { 194 | content: "\ea0e"; 195 | } 196 | 197 | .icon-bulb-63::before { 198 | content: "\ea0f"; 199 | } 200 | 201 | .icon-bullet-list-67::before { 202 | content: "\ea10"; 203 | } 204 | 205 | .icon-bus-front-12::before { 206 | content: "\ea11"; 207 | } 208 | 209 | .icon-button-pause::before { 210 | content: "\ea12"; 211 | } 212 | 213 | .icon-button-power::before { 214 | content: "\ea13"; 215 | } 216 | 217 | .icon-calendar-60::before { 218 | content: "\ea14"; 219 | } 220 | 221 | .icon-camera-18::before { 222 | content: "\ea15"; 223 | } 224 | 225 | .icon-caps-small::before { 226 | content: "\ea16"; 227 | } 228 | 229 | .icon-cart::before { 230 | content: "\ea17"; 231 | } 232 | 233 | .icon-chart-bar-32::before { 234 | content: "\ea18"; 235 | } 236 | 237 | .icon-chart-pie-36::before { 238 | content: "\ea19"; 239 | } 240 | 241 | .icon-chat-33::before { 242 | content: "\ea1a"; 243 | } 244 | 245 | .icon-check-2::before { 246 | content: "\ea1b"; 247 | } 248 | 249 | .icon-cloud-download-93::before { 250 | content: "\ea1c"; 251 | } 252 | 253 | .icon-cloud-upload-94::before { 254 | content: "\ea1d"; 255 | } 256 | 257 | .icon-coins::before { 258 | content: "\ea1e"; 259 | } 260 | 261 | .icon-compass-05::before { 262 | content: "\ea1f"; 263 | } 264 | 265 | .icon-controller::before { 266 | content: "\ea20"; 267 | } 268 | 269 | .icon-credit-card::before { 270 | content: "\ea21"; 271 | } 272 | 273 | .icon-delivery-fast::before { 274 | content: "\ea22"; 275 | } 276 | 277 | .icon-double-left::before { 278 | content: "\ea23"; 279 | } 280 | 281 | .icon-double-right::before { 282 | content: "\ea24"; 283 | } 284 | 285 | .icon-email-85::before { 286 | content: "\ea25"; 287 | } 288 | 289 | .icon-gift-2::before { 290 | content: "\ea26"; 291 | } 292 | 293 | .icon-globe-2::before { 294 | content: "\ea27"; 295 | } 296 | 297 | .icon-headphones::before { 298 | content: "\ea28"; 299 | } 300 | 301 | .icon-heart-2::before { 302 | content: "\ea29"; 303 | } 304 | 305 | .icon-html5::before { 306 | content: "\ea2a"; 307 | } 308 | 309 | .icon-image-02::before { 310 | content: "\ea2b"; 311 | } 312 | 313 | .icon-istanbul::before { 314 | content: "\ea2c"; 315 | } 316 | 317 | .icon-key-25::before { 318 | content: "\ea2d"; 319 | } 320 | 321 | .icon-laptop::before { 322 | content: "\ea2e"; 323 | } 324 | 325 | .icon-light-3::before { 326 | content: "\ea2f"; 327 | } 328 | 329 | .icon-link-72::before { 330 | content: "\ea30"; 331 | } 332 | 333 | .icon-lock-circle::before { 334 | content: "\ea31"; 335 | } 336 | 337 | .icon-map-big::before { 338 | content: "\ea32"; 339 | } 340 | 341 | .icon-minimal-down::before { 342 | content: "\ea33"; 343 | } 344 | 345 | .icon-minimal-left::before { 346 | content: "\ea34"; 347 | } 348 | 349 | .icon-minimal-right::before { 350 | content: "\ea35"; 351 | } 352 | 353 | .icon-minimal-up::before { 354 | content: "\ea36"; 355 | } 356 | 357 | .icon-mobile::before { 358 | content: "\ea37"; 359 | } 360 | 361 | .icon-molecule-40::before { 362 | content: "\ea38"; 363 | } 364 | 365 | .icon-money-coins::before { 366 | content: "\ea39"; 367 | } 368 | 369 | .icon-notes::before { 370 | content: "\ea3a"; 371 | } 372 | 373 | .icon-palette::before { 374 | content: "\ea3b"; 375 | } 376 | 377 | .icon-paper::before { 378 | content: "\ea3c"; 379 | } 380 | 381 | .icon-pencil::before { 382 | content: "\ea3d"; 383 | } 384 | 385 | .icon-pin::before { 386 | content: "\ea3e"; 387 | } 388 | 389 | .icon-planet::before { 390 | content: "\ea3f"; 391 | } 392 | 393 | .icon-puzzle-10::before { 394 | content: "\ea40"; 395 | } 396 | 397 | .icon-satisfied::before { 398 | content: "\ea41"; 399 | } 400 | 401 | .icon-scissors::before { 402 | content: "\ea42"; 403 | } 404 | 405 | .icon-send::before { 406 | content: "\ea43"; 407 | } 408 | 409 | .icon-settings-gear-63::before { 410 | content: "\ea44"; 411 | } 412 | 413 | .icon-settings::before { 414 | content: "\ea45"; 415 | } 416 | 417 | .icon-simple-add::before { 418 | content: "\ea46"; 419 | } 420 | 421 | .icon-simple-delete::before { 422 | content: "\ea47"; 423 | } 424 | 425 | .icon-simple-remove::before { 426 | content: "\ea48"; 427 | } 428 | 429 | .icon-single-02::before { 430 | content: "\ea49"; 431 | } 432 | 433 | .icon-single-copy-04::before { 434 | content: "\ea4a"; 435 | } 436 | 437 | .icon-sound-wave::before { 438 | content: "\ea4b"; 439 | } 440 | 441 | .icon-spaceship::before { 442 | content: "\ea4c"; 443 | } 444 | 445 | .icon-square-pin::before { 446 | content: "\ea4d"; 447 | } 448 | 449 | .icon-support-17::before { 450 | content: "\ea4e"; 451 | } 452 | 453 | .icon-tablet-2::before { 454 | content: "\ea4f"; 455 | } 456 | 457 | .icon-tag::before { 458 | content: "\ea50"; 459 | } 460 | 461 | .icon-tap-02::before { 462 | content: "\ea51"; 463 | } 464 | 465 | .icon-tie-bow::before { 466 | content: "\ea52"; 467 | } 468 | 469 | .icon-time-alarm::before { 470 | content: "\ea53"; 471 | } 472 | 473 | .icon-trash-simple::before { 474 | content: "\ea54"; 475 | } 476 | 477 | .icon-triangle-right-17::before { 478 | content: "\ea55"; 479 | } 480 | 481 | .icon-trophy::before { 482 | content: "\ea56"; 483 | } 484 | 485 | .icon-tv-2::before { 486 | content: "\ea57"; 487 | } 488 | 489 | .icon-upload::before { 490 | content: "\ea58"; 491 | } 492 | 493 | .icon-user-run::before { 494 | content: "\ea59"; 495 | } 496 | 497 | .icon-vector::before { 498 | content: "\ea5a"; 499 | } 500 | 501 | .icon-video-66::before { 502 | content: "\ea5b"; 503 | } 504 | 505 | .icon-volume-98::before { 506 | content: "\ea5c"; 507 | } 508 | 509 | .icon-wallet-43::before { 510 | content: "\ea5d"; 511 | } 512 | 513 | .icon-watch-time::before { 514 | content: "\ea5e"; 515 | } 516 | 517 | .icon-wifi::before { 518 | content: "\ea5f"; 519 | } 520 | 521 | .icon-world::before { 522 | content: "\ea60"; 523 | } 524 | 525 | .icon-zoom-split::before { 526 | content: "\ea61"; 527 | } 528 | 529 | .icon-refresh-01::before { 530 | content: "\ea62"; 531 | } 532 | 533 | .icon-refresh-02::before { 534 | content: "\ea63"; 535 | } 536 | 537 | .icon-shape-star::before { 538 | content: "\ea64"; 539 | } 540 | 541 | .icon-components::before { 542 | content: "\ea65"; 543 | } -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |174 |182 |175 | 本站生成的网址无暗链永久有效 176 |
181 |
请放心使用
177 | 178 | -By Xuhuai 179 | 180 |