发现一个有意思的2020大学排行榜
程序员文章站
2024-03-12 20:02:08
...
突然发现某个网站有点意思,居然会把地域优势算进去……
大概猜了一下,代码应该是这么写的:
<div class="row mb-4">
<?php $n=0;?>
@foreach ($school_list as $s)
<div class="col-lg-4 col-md-6">
<div class="box-image-text">
<div class="image"><img src="https://www.stueye.com/upload/images/school/{{$s->schid}}.jpg" alt="..." width="200px" style="margin-left:20px;" class="img-fluid">
<div class="overlay d-flex align-items-center justify-content-center"><a href="/school/info/{{$s->schid}}" tar_get="_blank" class="btn btn-template-outlined-white"><i class="fa fa-chain"> </i>更多信息</a></div>
</div>
<div class="content">
<h4><a href="/school/info/{{$s->schid}}">No.<?php echo $start+$n;$n++;?> {{$s->name}}</a></h4>
<p style="text-align:left">
外部排名:<?php echo str_repeat('★',$s->rank_rank/100)?><br>
名校光环:<?php echo str_repeat('★',$s->level_rank)?><br>
生源质量:<?php echo str_repeat('★',$s->score_rank/100)?><br>
地域优势:<?php echo str_repeat('★',$s->city_rank)?><br>
综合评定:<?php echo str_repeat('★',$s->rank/350)?>
</p>
</div>
</div>
</div>
@endforeach
</div>