Skip to content

Instantly share code, notes, and snippets.

Avatar
👋

Vladimir Progreccor progreccor

👋
View GitHub Profile
@progreccor
progreccor / icon.js
Last active Sep 8, 2021 — forked from proweb/icon.js
VK и OK иконки для Yootheme Pro
View icon.js
UIkit.icon.add('vk','<svg height="20px" style="enable-background:new 0 0 20 20;" version="1.1" viewBox="0 0 512 512" width="20px" xml:space="preserve" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"><g id="comp_x5F_364-vk"><g><path d="M475.515,137.899c3.16-10.674,0-18.53-15.2-18.53h-50.297c-12.809,0-18.702,6.746-21.861,14.261 c0,0-25.617,62.422-61.825,102.899c-11.698,11.699-17.078,15.457-23.482,15.457c-3.158,0-8.027-3.758-8.027-14.432v-99.655 c0-12.809-3.588-18.53-14.176-18.53h-79.075c-8.027,0-12.809,5.978-12.809,11.528c0,12.125,18.104,14.943,19.983,49.101v74.123 c0,16.225-2.904,19.212-9.308,19.212c-17.079,0-58.581-62.678-83.174-134.409c-4.952-13.919-9.821-19.555-22.715-19.555H43.25 c-14.346,0-17.25,6.746-17.25,14.261c0,13.32,17.079,79.502,79.502,166.945c41.587,59.689,100.167,92.056,153.453,92.056 c32.022,0,35.951-7.173,35.951-19.555c0-57.045-2.903-62.425,13.152-62.425c7.428,0,20.237,3.757,50.127,32.534 c34.155,34.158,39.792,49.445,58.92,49.445h50.297c14.347,0,21.606-7.173,17.421
@progreccor
progreccor / карта сайта яндекса
Created Jul 18, 2021
карта сайта яндекса
View карта сайта яндекса
<p class="uk-hidden@s uk-text-center uk-margin-top">Передвинуть карту можно двумя пальцами</p>
<div id="YMapsID" class="uk-img-preserve" style="width: 100%; height: 600px; padding: 0; margin: 0;"></div>
<script src="https://api-maps.yandex.ru/2.1/?lang=ru-RU&amp;coordorder=latlong" type="text/javascript"></script>
<script type="text/javascript">// <![CDATA[
var map;
ymaps.ready(function () {
var isMobile = window.matchMedia("only screen and (max-width: 760px)");
//Создание карты и задание свойств
map = new ymaps.Map("YMapsID", {
center: [59.91957123, 30.35279517],
@progreccor
progreccor / bitrix.php
Last active Nov 26, 2020
интеграция bitrix24 и radicalform
View bitrix.php
<?php
defined('_JEXEC') or die;
// формируем URL в переменной $queryUrl
$queryUrl = 'https://[ваше_название].bitrix24.ru/rest/[идентификатор_пользователя]/[код_вебхука]/crm.lead.add.json';
//проверяем существование передаваемых переменных
if(isset($source['name']))
{
@progreccor
progreccor / alert.js
Last active Nov 7, 2019
vertically center alert at uikit2
View alert.js
/*
Vertically center alert window on UIKIT 2
*/
UIkit.modal.alert('My message!', {
center: true
});
View amocrm.php
<?php
defined('_JEXEC') or die;
#Массив с параметрами, которые нужно передать методом POST к API системы
$login="test@yandex.ru";
$api_key='2672fefef7b71620b86d1a8b90f6ab1e' ; #ключ фейковый - замените на свой
$subdomain='test2'; #Наш аккаунт - поддомен
@progreccor
progreccor / mc.menu
Last active Jul 15, 2019
installer of phpmyadmin into the current directory for mc
View mc.menu
shell_patterns=0
+ d /var/www/html & ! d /var/www/html/ & t d
1 архив сайта
GREEN='\033[0;32m'
LGREEN='\033[1;32m'
RED='\033[0;31m'
WHITE='\033[0m'
echo -e "Создаем архив сайта ${GREEN}%f${WHITE}"
if [ ! -z "`mysql -uroot -p${MYSQLPASS} -qfsBe "SELECT SCHEMA_NAME FROM INFORMATION_SCHEMA.SCHEMATA WHERE SCHEMA_NAME='%f'" 2>&1`" ]
@progreccor
progreccor / downloadlatestJoomla.sh
Last active Apr 3, 2019
Download latest Joomla release in to the directory and untar it
View downloadlatestJoomla.sh
GREEN='\033[0;32m'
RED='\033[0;31m'
WHITE='\033[0m'
site=test.ru
directory="/var/www/html"
adr=$( curl -s https://api.github.com/repos/joomla/joomla-cms/releases/latest | grep browser_download_url.*Stable-Full_Package.tar.gz | awk '{ print $2 }' | tr -d \" )
cd $directory
wget $adr
tar xvzf *Stable-Full_Package.tar.gz -C $directory/$site
rm $directory/*Stable-Full_Package.tar.gz
@progreccor
progreccor / joomla-ajax.js
Created Feb 25, 2019 — forked from Septdir/joomla-ajax.js
Ajax request for joomla
View joomla-ajax.js
let request = new XMLHttpRequest(),
requestUrl = '', // Указываем url запроса
formData = new FormData(); // Перадаем <form> или просто добавляем ниже через append что нужно
request.open('POST', requestUrl);
request.send(new URLSearchParams(formData));
request.onreadystatechange = function () {
if (this.readyState === 4 && this.status === 200) {
let response = false;
try {