Skip to content

Instantly share code, notes, and snippets.

@vikt82
vikt82 / clear_input.txt
Created March 11, 2015 18:29
clear input
---------------------- Отчистка поля ввода ---------------------------------
<div class=""><input type="text" name="" value="Login..." class="f_input" onblur="if(this.value=='') this.value='Login...';" onfocus="if(this.value=='Login...') this.value='';" /></div>
@vikt82
vikt82 / hightlight_navigation.txt
Created March 11, 2015 18:31
подсветка навигации
---------------------- Подсветка навигации ---------------------------------
Источник_ http://demiart.ru/forum/journal.php?user=1551377&comm=212211
( <body onload="highlight()">
<script language="JavaScript" type="text/javascript">highlight()</script>
<ul>
<li class="nav"><a href="coding.html">Программирование</a></li>
<li class="nav"><a href="design.html">Дизайн</a></li>
<li class="nav"><a href="page-proofs.html">Верстка</a></li>
<li class="nav"><a href="prices.html">Цены</a></li>
@vikt82
vikt82 / link_color.txt
Created March 11, 2015 18:33
ссылка изменяющая цвета
@vikt82
vikt82 / column_height.txt
Created March 11, 2015 18:33
колонки одинаковой высоты
Колонки одинаковой высоты
$(document).ready(function(){
//set the starting bigestHeight variable
var biggestHeight = 0;
//check each of them
$('.equal_height').each(function(){
//if the height of the current element is
//bigger then the current biggestHeight value
if($(this).height() > biggestHeight){
@vikt82
vikt82 / зкщсуте_ыскщдд.txt
Created March 11, 2015 18:35
определение процентов скрола
опредиления процентов скролаы
var tmp = getScrollXY();
var fullHeight = $('body').height();
var perec = tmp[1] * 100/ fullHeight;
console.log(perec + '%');
function getScrollXY() {
var scrOfX = 0, scrOfY = 0;
if( typeof( window.pageYOffset ) == 'number' ) {
@vikt82
vikt82 / show-hight.txt
Created March 11, 2015 18:36
проказывает при навидении и прячет при отводе
показывает при навидении мышки и прячет при отводе
<script>
$('#show-menu')
.mouseenter(function() {
$('.other-drop').show();
})
.mouseleave(function() {
$('.other-drop').hide();
});
</script>
@vikt82
vikt82 / wp_style.css
Created February 10, 2016 16:48
wp_style.css
/*
Theme Name:
Theme URI:
Author:
Author URI:
Description:
Version:
License:
License URI:
Tags:
set-font-size(value) {
font-size: value; /* добавляем PX как подстраховку */
if (value is inherit) {
/* делаем если нет значения для шрифта */
} else {
font-size: remify(value);
}
}
@vikt82
vikt82 / .vimrc
Created February 27, 2020 08:40 — forked from alexey-goloburdin/.vimrc
set nocompatible " be iMproved, required
filetype off " required
" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')
" let Vundle manage Vundle, required
@vikt82
vikt82 / cloudSettings
Last active July 13, 2020 15:51
Visual Studio Code Settings Sync Gist
{"lastUpload":"2020-07-03T14:25:11.061Z","extensionVersion":"v3.4.3"}