/login?zapros=123 -> /login.php?zapros=123
RewriteRule ^login$ login.php [L,QSA]
var x = {
key1: 12345678,
key2: "12345429",
key3: "2914180512305"
}
var f = Object.keys(x).filter(function(w) {
v = x[w];
if (typeof v !== "string") {
v = w.toString()
}
return w.match(/^1234\d{4}$/)
}).map(function(k) {
return x[k]
})
var x = {
key1: 12345678,
key2: "12345429",
key3: "2914180512305"
}, f = [];
Object.keys(x).forEach(function(k, v) {
if (typeof v !== "string") {
v = v.toString()
}
if (v.match(/^1234\d{4}$/)) f.push(v)
})
var x = [12341, 12342, 12345, 'sdfdf', 3123, 12346];
var f = x.filter(function(v){return (v >= 12340 && v <= 12349)});
console.log(f); // -> Array [ 12341, 12342, 12345, 12346 ]
$json = json_decode("тут жсон", true);
foreach ($json['season_episodes_count'] as $season) {
// $season -> ['season_number' => X, 'episodes_count' => Y]
// делай с этим что хочешь
}
@keyframes test {
0% {
width: 100px;
}
50% {
width: 150px;
}
100% {
width: 100px;
}
}
div.test {
animation: test 1s ease 0s infinite;
}
@keyframes test {
0% {
width: 100px;
}
100% {
width: 150px;
}
}
div.test {
animation: test 1s ease 0s infinite alternate;
}
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^(.*)$ index.php?q=$1 [QSA,L]