add_action( 'wp_enqueue_scripts', function () {
if ( !current_user_can( 'manage_options' ) ) {
wp_enqueue_script('oncopy_addlink', '/path/to/script.js');
}
});
const divider = '-';
const symbol = 'x';
let x = symbol;
let prefix = divider;
let suffix = divider;
for (let i = 0; i < 2; i++) {
prefix += x + divider;
suffix = divider + x + suffix;
x += symbol;
}
let result = prefix + x + suffix;
console.log(result);
кнопка кнопка
кнопка
const gmExample = {
"south": 43.106491921792255,
"west": 76.71745650634767,
"north": 43.4065384633472,
"east": 77.13974349365236
};
const dgExample= {
"northEast": [
76.92894332280319,
43.25695003829279
],
"southWest": [
76.92825667730312,
43.256449960663694
]
};
const gm = {
"south": dgExample.southWest[1],
"west": dgExample.southWest[0],
"north": dgExample.northEast[1],
"east": dgExample.northEast[0]
};
const dg = {
"northEast": [
gmExample.east,
gmExample.north
],
"southWest": [
gmExample.west,
gmExample.south
]
};
$('div.filtr form ul li').click(function(){
if ( $(this).hasClass('sf-field-sort_order') ) {
return;
}
});
var isChecked = $("#form-check").is(":checked"); var isChecked2 = $("#form-check__quest").is(":checked");
treeInterest[i].checked ?
childCheckbox.forEach((elem) => (elem.checked = true)) :
childCheckbox.forEach((elem) => (elem.checked = false));
на treeInterest[i].checked ?
childCheckbox.forEach((elem) => {elem.checked = true; elem.indeterminate = false;}) :
childCheckbox.forEach((elem) => {elem.checked = false;elem.indeterminate = false;});