View gist:27eab397b788cd24a186
img-responsive { | |
width: auto\9; | |
max-width: 100%; | |
height: auto; | |
} |
View youtube
var tag = document.createElement('script'); | |
tag.src = "https://www.youtube.com/iframe_api"; | |
var firstScriptTag = document.getElementsByTagName('script')[0]; | |
firstScriptTag.parentNode.insertBefore(tag, firstScriptTag); | |
var player; | |
function onYouTubeIframeAPIReady() { | |
player = new YT.Player('player', { | |
videoId: '67_D99r4KVg', | |
events: {} | |
}); |
View popap video
(function() { | |
$('.popap-video').hide('fast') | |
$('.trigger').click(function(event) { | |
event.stopPropagation(); | |
$('.popap-video').not($(this).next()).fadeOut('fast'); | |
$(this).next().fadeToggle(); | |
}) | |
})(); |
View search substring url
(function() { | |
var location = document.location.pathname; | |
var filterOption = '_text_'; | |
if (location.indexOf(filterOption) > -1) { | |
} | |
})(); |
View hide empty element
$(":empty").parent().hide(); | |
$(":empty").hide(); |
View uniform list item v1
ul { | |
text-align: justify; | |
} | |
ul li { | |
display: inline-block; | |
} | |
ul:after { | |
width: 100%; | |
height: 0px; | |
visibility: hidden; |
View st 3 snippets scope
https://gist.github.com/iambibhas/4705378 | |
Here is a list of scopes to use in Sublime Text 2 snippets - | |
ActionScript: source.actionscript.2 | |
AppleScript: source.applescript | |
ASP: source.asp | |
Batch FIle: source.dosbatch | |
C#: source.cs | |
C++: source.c++ |
View max Height
var maxHeight = 0; | |
$("div").each(function(){ | |
if ($(this).height() > maxHeight) { maxHeight = $(this).height(); } | |
}); | |
$("div").height(maxHeight); |
View git config
[filter "lfs"] | |
[filter "lfs"] | |
clean = git-lfs clean %f | |
smudge = git-lfs smudge %f | |
required = true | |
[core] | |
autocrlf = false | |
safecrlf = false | |
editor = 'C:/Program Files/Sublime Text 3/sublime_text.exe' -w | |
[alias] |
OlderNewer