Skip to content

Instantly share code, notes, and snippets.

@alex-boom
alex-boom / grid-different-col.html
Last active May 24, 2019 14:41
grid-different-col
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
<style>
/*
example https://jsfiddle.net/w6jx5z03/2/
*/
ul {
@alex-boom
alex-boom / star-raiting.html
Last active March 20, 2019 12:19
star-raiting
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>star raiting</title>
<style>
.star-ratings {
display: inline-block;
position: relative;
color: #c5c5c5;
@alex-boom
alex-boom / resize-orientationchange.js
Last active February 10, 2019 10:12
resize-orientationchange
jQuery(window).on('resize orientationchange', function(){
//code here
});
@alex-boom
alex-boom / img-style-width-height-ratio.js
Last active July 1, 2021 10:59
img-style-width-height-ratio
/*
init image height
*/
img
// рабочий вариант
jQuery(function () {
initImgHeight()
jQuery(window).on('resize orientationchange', function () {
initImgHeight();
@alex-boom
alex-boom / placehold-img.txt
Last active January 18, 2024 11:31
placehold-img
<img src="https://placehold.co/100x100" alt="image description">
<img src="<?php echo get_template_directory_uri() . '/img/warning.svg' ?>" alt="image description">
@alex-boom
alex-boom / replase-svg.js
Created January 17, 2019 10:51
replase-svg
jQuery('img').each(function(){
var $img = jQuery(this);
var imgID = $img.attr('id');
var imgClass = $img.attr('class');
var imgURL = $img.attr('src');
jQuery.get(imgURL, function(data) {
// Get the SVG tag, ignore the rest
var $svg = jQuery(data).find('svg');
@alex-boom
alex-boom / git-delate-idea.txt
Created January 17, 2019 08:02
git-delate-idea
git rm -r --cached .idea
@alex-boom
alex-boom / switcher-view.html
Created December 21, 2018 10:57
switcher-view
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>switcher view</title>
<style>
.switches.active {
color: red;
}
We couldn’t find that file to show.
@alex-boom
alex-boom / scrollbar-none.css
Created August 29, 2018 12:14
scrollbar-none
/* хром, сафари */
.carousel-box::-webkit-scrollbar { width: 0; }
/* ie 10+ */
.carousel-box { -ms-overflow-style: none; }
/* фф (свойство больше не работает, других способов тоже нет)*/
.carousel-box { overflow: -moz-scrollbars-none; }