我在js小提琴中引用代码:
Jsfiddle工作正常
<style>
.item {
display: inline-block;
width: 180px;
height: 120px;
border: thin solid #000;
margin: 0.25em;
}
.item .title {
font-weight: bold;
word-wrap: break-word;
}
.item {
overflow: hidden;
}
.hidden {
display: none;
}
#top {
position: fixed;
width: 100%;
height: 80px;
padding: 4px;
text-align: center;
background: #FFF;
}
#top h1 {
font-size: 2em;
margin-bottom: 0.5em;
}
#search {
width: 60%;
margin: 0 auto;
padding: 0.25em;
text-align: center;
}
#results {
padding-top: 90px;
text-align: center;
}
.icon:before {
font-size: 3em;
color: #4466DD;
}
</style>
</head>
<body>
<div id="top">
<h1>Programming Languages</h1>
<input type="text" id="search" value="" placeholder="Search..." />
</div>
<div id="results"></div>
<script>..................
my_list = ['2-7', '10-22', '22-50', '50-70',
'2-7', '10-22', '22-50', '50-70',
'2-7', '10-22', '22-50', '50-70']
list_2 = []
for item in my_list:
first, second = item.split('-')
list_2.append([float(first), float(second)])
但是当我编写相同的代码并在此网站(http://indianwaterpurifiers.online/)中托管时,请参阅视图源,网格未在浏览器中呈现。
HTML文件有什么问题?