3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $factor = 1.34; $higher_res = 2100; $lower_res = 300; $divisions = 70; for($i = $higher_res; $i >= $lower_res; $i = $i - $divisions){ echo "@media screen and (max-width:".$i."px) { .span12, .container{width: ". intval($i/ $factor) ."px !important;} }"; }
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
@media screen and (max-width:2100px) { .span12, .container{width: 1567px !important;} }@media screen and (max-width:2030px) { .span12, .container{width: 1514px !important;} }@media screen and (max-width:1960px) { .span12, .container{width: 1462px !important;} }@media screen and (max-width:1890px) { .span12, .container{width: 1410px !important;} }@media screen and (max-width:1820px) { .span12, .container{width: 1358px !important;} }@media screen and (max-width:1750px) { .span12, .container{width: 1305px !important;} }@media screen and (max-width:1680px) { .span12, .container{width: 1253px !important;} }@media screen and (max-width:1610px) { .span12, .container{width: 1201px !important;} }@media screen and (max-width:1540px) { .span12, .container{width: 1149px !important;} }@media screen and (max-width:1470px) { .span12, .container{width: 1097px !important;} }@media screen and (max-width:1400px) { .span12, .container{width: 1044px !important;} }@media screen and (max-width:1330px) { .span12, .container{width: 992px !important;} }@media screen and (max-width:1260px) { .span12, .container{width: 940px !important;} }@media screen and (max-width:1190px) { .span12, .container{width: 888px !important;} }@media screen and (max-width:1120px) { .span12, .container{width: 835px !important;} }@media screen and (max-width:1050px) { .span12, .container{width: 783px !important;} }@media screen and (max-width:980px) { .span12, .container{width: 731px !important;} }@media screen and (max-width:910px) { .span12, .container{width: 679px !important;} }@media screen and (max-width:840px) { .span12, .container{width: 626px !important;} }@media screen and (max-width:770px) { .span12, .container{width: 574px !important;} }@media screen and (max-width:700px) { .span12, .container{width: 522px !important;} }@media screen and (max-width:630px) { .span12, .container{width: 470px !important;} }@media screen and (max-width:560px) { .span12, .container{width: 417px !important;} }@media screen and (max-width:490px) { .span12, .container{width: 365px !important;} }@media screen and (max-width:420px) { .span12, .container{width: 313px !important;} }@media screen and (max-width:350px) { .span12, .container{width: 261px !important;} }