标题css / bootstrap问题,很奇怪

我不明白这里发生了什么。</ p>

这是我的 文件数据“结构”:</ p>

</ p>

这里是我的文件夹的内容“ css“</ p>

</ p>

所以,在我的程序中:这个文件”estudiante.php“, “editar.php”和“hola.php”获得相同的标题。 看看:</ p>

 &lt; head&gt; 
&lt; meta name =“viewport”content =“width = device-width,initial-scale = 1”&gt; \ n&lt; script src =“http://code.jquery.com/jquery-2.1.1.min.js”&gt;&lt; / script&gt;
&lt; meta name =“viewport”content =“width = device -width,initial-scale = 1“&gt;
&lt; link rel =”stylesheet“href =”https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css“integrity = “sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va + PmSTsz / K68vbdEjh4u”crossorigin =“anonymous”&gt;
&lt; link rel =“stylesheet”href =“https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap-theme .min.css“integrity =”sha384-rHyoN1iRsVXV4nD0JutlnGaslCJuC7uwjduW9SVrLvRYooPp2bWYgmgJQIXwl / Sp“crossorigin =”anonymous“&gt;
&lt; script src =”https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min .js“integrity =”sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa“crossorigin =”anonymous“&gt;&lt; / script&gt;

&lt; / head&gt;
< / code> </ pre>

问题是我无法从“css”文件夹链接文件“estilos.css”,因为我在检查inspect元素工具时遇到了一些错误 chrome:</ p>

</ p>

但这很奇怪,因为我在我的标题上写了这一行: </ p>

 &lt; meta name =“viewport”content =“width = device-width,initial-scale = 1”&gt; 
</ code> </ pre> \ n

该行使我的页面响应,但这些命令在我的estilos.css文件中..我不明白,看看:</ p>

</ p>

因此,estilos.css没有出现在我的代码中,但标题使用了内容并使我的网站响应? 我不明白这个伙伴:( </ p>
</ div>

展开原文

原文

I do not understand what is going on here.

This is my file-data "structure":

enter image description here

Over here is the content of my folder "css"

enter image description here

So, in my program: this files"estudiante.php","editar.php" and "hola.php" got the same header. Take a look:

    <head>
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <script src="http://code.jquery.com/jquery-2.1.1.min.js"></script>
        <meta name="viewport" content="width=device-width, initial-scale=1">
        <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
        <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap-theme.min.css" integrity="sha384-rHyoN1iRsVXV4nD0JutlnGaslCJuC7uwjduW9SVrLvRYooPp2bWYgmgJQIXwl/Sp" crossorigin="anonymous">
        <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>


</head>

The problem is that i could not link the file "estilos.css" from the "css" folder because i was given some errors while i was checking the inspect element tool using chrome:

enter image description here

But it is strange, because i wrote this line on my header:

<meta name="viewport" content="width=device-width, initial-scale=1">

That line makes my page responsive, but those commands are in my estilos.css file.. i don get it, take a look:

enter image description here

So, estilos.css doesnt appear in my code but the header uses the content and makes my website responsive?. I dont understand this mates :(

dongluan2612
dongluan2612 我没有在HTML中看到<link>到estilos.css。你正在使用的路径是什么?你可能在开头有一个斜杠,这使得浏览器从localhost上的项目文件夹中看到一个文件夹。我猜你正在使用href=“/css/estilos.css”而不是href=“css/estilos.css”(开头没有/)。FWIW,删除重复的<meta>标记。
3 年多之前 回复

1个回答



仔细检查文件命名约定。 看起来你正在隐藏文件扩展名,因为 bootstrap </ code>, bootstrap.min </ code>等最后没有 .css </ code>,但是 estilos.css </ code>可以。 您的文件实际上可能名为 estilos.css.css </ code>而您不知道。</ p>

https://www.howtogeek.com/205086/beginner-how-to-make-windows- show-file-extensions / </ p>
</ div>

展开原文

原文

Double-check your file naming conventions. It looks like you're hiding file extensions, since bootstrap, bootstrap.min, etc don't have .css on the end, but estilos.css does. It's possible your file is actually named estilos.css.css and you aren't aware.

https://www.howtogeek.com/205086/beginner-how-to-make-windows-show-file-extensions/

dsgnze6572
dsgnze6572 很好的观察! 错过了我自己。
3 年多之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问
相关内容推荐