简体   繁体   English

jquery 3.5.1 移动 css 格式未显示在使用 vs 代码的实时服务器预览中

[英]jquery 3.5.1 mobile css formating not showing in live server preview with vs code

I'm trying to use the jquery css stylesheet, but I can't seem to get it to format anything at all.我正在尝试使用 jquery css 样式表,但我似乎无法让它格式化任何东西。 I'm using the live preview extension in VSCode, and the css is from the jquery website.我在 VSCode 中使用实时预览扩展,css 来自 jquery 网站。

<!DOCTYPE html>
<html>

<head>
    <title>Physics Simulator App</title>
    <link rel="stylesheet" href="css\jquery.mobile-1.4.5.min.css">
    <script src="scripts\jquery-3.5.1.min.js">  </script>
    <script src="scripts\jquery.mobile-1.4.5.min.js">  </script>
    <script type='text/javascript' src='scripts\Week 2 homework.js'>  </script>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>

<body>
    <div data-role="page">
        <div data-role="navbar">
            <ul>
                <li><a href="week 1 homework.html"> Information</a> </li>
                <li><a href="Week 2 App.html" class="ui-btn-active ui-state-persist"> Interface</a> </li>
            </ul>
        </div>
        <div data-role="header">Binary Operators Demo</div>
        <div data-role="content">
            <label for="input">A</label>
            <input type="checkbox" name="inputA" id="inputA">
            <br />
            <label for="input">B</label>
            <input type="checkbox" name="inputB" id="inputB">
            <br />
            <button onclick="AND();">AND</button>
            <button onclick="OR();">OR</button>
            <button onclick="NOT();">NOT</button>
            <button onclick="XOR();">XOR</button>
        </div>
        <table id="data">
            <tr>
                <td>Result: </td>
                <td id="resultA"></td>

            </tr>
        </table>
        <div data-role="footer">
            <small>binary operations demo app</small>
        </div>
    </div>
</body>

</html>

I don't think I'm missing anything in terms of brackets, and the file paths work for my own css files.我认为我在括号方面没有遗漏任何东西,并且文件路径适用于我自己的 css 文件。 I've tried adding 'data-theme="a"' to my page bracket, but nada.我已经尝试将 'data-theme="a"' 添加到我的页括号中,但是 nada. I just get this.我只是明白这个。 result结果

Is it a version issue or?是版本问题还是?

Friend, I may have misunderstood you for not mastering English very well.朋友,我可能误会了你英语不好。 But as I understand it, your problem is with jquery.mobile.css?但据我了解,您的问题是 jquery.mobile.css? Try using the CDN.尝试使用 CDN。 I copied your code and replaced the with the CDN (I didn't find this Week 2 homework.js).我复制了你的代码并用 CDN 替换了它(我没有找到这个 Week 2 homework.js)。 Replace the with the CDN and do this test: Insert this code block:将 替换为 CDN 并进行此测试:插入此代码块:

        <div class = "ui-grid-d">
            <div class = "ui-block-a">
                <a href="#" class="ui-btn ui-corner-all ui-shadow"> button </a> <br>
                <span> any info </span>
            </div>
        </div>

It uses the style of jquery.mobile.css, if it works the problem could be in your import of the files.它使用 jquery.mobile.css 的样式,如果它有效,问题可能出在您导入的文件中。 Two tips, avoid spaces in the file names, (Week 2, it could be Week_2_homework), and in the <label for = ""> do not point " input ", point the name you gave to the input or the id .两个小技巧,在文件名,避免空间(2周,也可能是Week_2_homework),并在<label for = "">不点“ input ”,点你给的名字inputID。 If I was wrong about your problem, answer that I try to help you.如果我对您的问题有误,请回答我会尽力帮助您。 Reggards问候

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 实时预览在任何代码编辑器中均不显示CSS背景 - Live Preview not showing css background in any Code Editor CSS 未保存在 Live Server 中(VS CODE) - CSS not saving in Live Server (VS CODE) CSS背景图像未在chrome中显示,但在vs live服务器上工作 - css background images are not showing in chrome but working on vs live server vs代码中的实时服务器 - live server in vs code 为什么 HTML 背景图像没有显示在 VS Code 的实时服务器中? - Why HTML background images not showing in live server in VS Code? 我的可视化代码编辑器未在实时预览中显示包含的 CSS - My Visual- Code-Editor is not showing the included CSS in the Live preview 当我尝试通过实时服务器运行 html 代码时,它显示服务器在端口 5500 启动,但未能在浏览器预览中打开 - When i try to run html code through live server it is showing server started at port 5500 but failed failed to open in browser preview Visual Studio Code 实时服务器不显示图像 - Visual Studio Code Live Server not showing images 图像和 css 没有加载到浏览器上,除了在 VS Code 中设置为实时服务器的默认浏览器 - Images and css not loading on browsers other than the one set as default for live server in VS Code VS Code Live Server Extension 在使用 CSS 网格布局时不显示背景 colors - VS Code Live Server Extension not displaying background colors when using CSS Grid layout
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM