(?i)(football|soccer|fifa|eufa|footy|goal|free kick|penalty|offside|you blind ref|manchester united|united|man utd|mufc|man city|mcfc|real madrid|fergie|giggs|rooney)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
var circle = $("a.circle"), | |
circleOffset = $(circle).offset(), | |
parent = $(circle).parent('li,p,blockquote'), | |
parentOffset = $(parent).offset(); | |
// Find position of link | |
var relativeOffsetTop = parentOffset.top - cirlceOffset.top, | |
relativeOffsetLeft = parentOffset.left - cirlceOffset.left,; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isExternal(url) { | |
var match = url.match(/^([^:\/?#]+:)?(?:\/\/([^\/?#]*))?([^?#]+)?(\?[^#]*)?(#.*)?/); | |
if (typeof match[1] === "string" && match[1].length > 0 && match[1].toLowerCase() !== location.protocol) return true; | |
if (typeof match[2] === "string" && match[2].length > 0 && match[2].replace(new RegExp(":("+{"http:":80,"https:":443}[location.protocol]+")?$"), "") !== location.host) return true; | |
return false; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="toggle"> | |
<p>24 Results</p> | |
<a href="#">Rating<span></span></a> | |
</div> | |
<ul class="stay-list"> | |
<li> | |
<div> | |
<h3><a href="http://example.com">Title</a></h3> | |
<p>From £65.00</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$(window).load(function () { | |
$('.posts').masonry(); | |
$('.masonryWrap').infinitescroll({ | |
debug: true, // Remove this before going live | |
navSelector : "div#navigation", // selector for the paged navigation (it will be hidden) | |
nextSelector : "div#navigation a#nextPage", // selector for the NEXT link (to page 2) | |
itemSelector : ".entry", // selector for all items you'll retrieve | |
bufferPx : 10000, | |
extraScrollPx : 11000, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
a:link, a:visited, a:hover, a:active { | |
color:#000; | |
text-decoration: none; | |
} | |
a:hover { | |
text-decoration: underline; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# compass-to-docksend.rb (https://gist.github.com/samuelcotterall/5320424) | |
# | |
# Instructions: Put this at the end of config.rb | |
# Execute AppleScript inside Ruby. I stole this from here: http://porkrind.org/missives/calling-applescript-from-ruby/ | |
def osascript(script) | |
system 'osascript', *script.split(/\n/).map { |line| ['-e', line] }.flatten | |
end | |
# Send to Transmit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var userInfo = passport.deserializeUser(function(id){ | |
return id; | |
}); | |
User.findById(userInfo, function(err, user) { | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function cl_acf_set_language() { | |
return acf_get_setting('default_language'); | |
} | |
function get_global_option($name) { | |
echo acf_get_setting('current_language'); // it | |
add_filter('acf/settings/current_language', 'cl_acf_set_language'); | |
echo acf_get_setting('current_language'); // en | |
$option = get_field($name); | |
remove_filter('acf/settings/current_language', 'cl_acf_set_language'); | |
echo acf_get_setting('current_language'); // it |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$("#myformid").find("input, select").on('change', function(){ | |
$("#myElement").addClass("myclass"); | |
}); |