Skip to content

Instantly share code, notes, and snippets.

@Wockeez
Wockeez / .block
Created June 2, 2022 07:00 — forked from clhenrick/.block
Custom tiles in Google Maps
license: apache-2.0
@Wockeez
Wockeez / nginx.conf
Created March 10, 2022 07:30 — forked from Stanback/nginx.conf
Example Nginx configuration for adding cross-origin resource sharing (CORS) support to reverse proxied APIs
#
# CORS header support
#
# One way to use this is by placing it into a file called "cors_support"
# under your Nginx configuration directory and placing the following
# statement inside your **location** block(s):
#
# include cors_support;
#
# As of Nginx 1.7.5, add_header supports an "always" parameter which
@Wockeez
Wockeez / gist:ad57ee281837dc353474fef4ab647152
Last active January 24, 2022 12:56 — forked from realmyst/gist:1262561
Склонение числительных в javascript
function declOfNum(number, titles) {
cases = [2, 0, 1, 1, 1, 2];
return titles[ (number%100>4 && number%100<20)? 2 : cases[(number%10<5)?number%10:5] ];
}
use:
declOfNum(count, ['найдена', 'найдено', 'найдены']);
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
@Wockeez
Wockeez / mail.php
Created May 8, 2021 10:44 — forked from sharkyak/mail.php
axios vue mail post
<?php
$to = "[email protected]"; // адрес куда отправлять письмо
$subject = "Отправка формы с сайта"; // заголовок письма
$_POST = json_decode(file_get_contents('php://input'), true);
foreach($_POST as $key => $value)
{ $fields .= $key.": ".$value." \r\n"; }
$message = $subject." \r\n".$fields;
$headers = "Content-type: text/plain; charset=utf-8 \r\n";
@Wockeez
Wockeez / Regions.json
Created March 30, 2021 11:58 — forked from max107/Regions.json
Russia regions with coords. Регионы россии с координатами границ.
{
"Алтайский край": {
"0": [
[
54.469437,
85.079468
],
[
54.195824,
85.44720500000001
@Wockeez
Wockeez / loading.css
Created January 12, 2021 08:19 — forked from colbyfayock/loading.css
CSS Loading Animation
/**
* Loading Animation Snippet
*/
.loading {
color: transparent;
background: linear-gradient(100deg, #eceff1 30%, #f6f7f8 50%, #eceff1 70%);
background-size: 400%;
animation: loading 1.2s ease-in-out infinite;
}