Skip to content

Instantly share code, notes, and snippets.

View muravikov's full-sized avatar

Muravikov muravikov

View GitHub Profile
@muravikov
muravikov / 1.php
Created October 1, 2025 12:48
Запрос к REST API Битрикс
<?php
/// enums
$enums = [
['value'='value1'],
['value'='value2'],
/// ...
['value'='value40'],
];
/// запрос
$params = [
@muravikov
muravikov / js huck.js
Created January 5, 2022 20:40
one line js command
// Разрешить операции копирования и вставки на странице:
javascript:(function(w){var%20arr=['contextmenu','copy','cut','paste','mousedown','mouseup','beforeunload','beforeprint'];for(var%20i=0,x;x=arr[i];i++){if(w['on'+x])w['on'+x]=null;w.addEventListener(x,function(e){e.stopPropagation()},true)};for(var%20j=0,f;f=w.frames[j];j++){try{arguments.callee(f)}catch(e){}}})(window);
// Сделать доступными заблокированные поля:
javascript:(function(){function process(tag){var i,l,els=document.getElementsByTagName(tag);for(i=0,l=els.length;i<l;i++){els[i].readOnly = null;els[i].disabled = null;}}process('input');process('select');process('textarea');process('button');})()
// Показать значения, скрытые за «звёздочками»:
javascript:(function(){var%20s,F,j,f,i;%20s%20=%20"";%20F%20=%20document.forms;%20for(j=0;%20j<F.length;%20++j)%20{%20f%20=%20F[j];%20for%20(i=0;%20i<f.length;%20++i)%20{%20if%20(f[i].type.toLowerCase()%20==%20"password")%20s%20+=%20f[i].value%20+%20"\n";%20}%20}%20if%20(s)%20alert("Passwords%20in%20