| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485 |
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
- <title>Document</title>
- <style>
- * {
- margin: 0;
- padding: 0;
- box-sizing: border-box;
- }
- body {
- user-select: none;
- width: 100%;
- height: 100%;
- }
- .title {
- box-shadow: 0 1px 6px #ccc;
- position: fixed;
- z-index: 10;
- right: 0;
- left: 0;
- height: 44px;
- padding-right: 10px;
- padding-left: 10px;
- border-bottom: 0;
- background-color: #f7f7f7;
- text-align: center;
- font-size: 17px;
- font-weight: 500;
- line-height: 44px;
- }
- .content {
- padding: 85px 15px 15px;
- }
- p {
- font-size: 14px;
- margin-top: 0;
- margin-bottom: 10px;
- color: #8f8f94;
- text-align: center;
- }
- </style>
- </head>
- <script>
- const id = window.location.href.split('?sId=')[1]
- const fetchUrl = window.location.href.includes('localhost:') ? 'https://ypbwg.4dage.com' : ''
- fetch(`${fetchUrl}/api/show/knowledge/cms/detail/${id}`)
- .then(response => response.json())
- .then(data => {
- const dataRes = data.data
- const titleDom = document.querySelector('.title')
- const contentDom = document.querySelector('.content')
- titleDom.innerHTML = dataRes.cName
- contentDom.innerHTML = dataRes.cContent
- });
- </script>
- <body>
- <!-- 标题 -->
- <div class="title"></div>
- <!-- 主要内容 -->
- <div class="content"></div>
- </body>
- </html>
|