This file contains 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
<?php | |
/********* DO NOT COPY THE PARTS ABOVE THIS LINE *********/ | |
/* Change Yoast SEO Prev/Next URL on some pages | |
* Credit: Yoast Team | |
* Last Tested: Jun 10 2017 using Yoast SEO 4.9 on WordPress 4.8 | |
*/ | |
add_filter( 'wpseo_next_rel_link', 'custom_change_wpseo_next' ); |
This file contains 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
<?php | |
/*********************************************************************** | |
A simple PHP function that will correctly uppercase Greek language | |
with proper spelling rules (removing accents in uppercased letters). | |
This is a server-side alternative to CSS uppercase() for Greek. | |
Greek CSS uppercase() is not working right on some browsers. | |
You can fix this by using javascript (increases browser load time) or | |
in server side by using this function here. |
This file contains 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
if (document.querySelector("link[rel='canonical']")) { | |
// Get current URL | |
var url = document.URL; | |
// If query string, get it and append to current URL | |
if (location.search) { | |
var query = location.search; | |
} else { | |
var query = ''; |
This file contains 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
<!--[if gt IE 9]><!--> | |
<img src="img/wordmark.svg" onerror="this.src=img/wordmark.png;this.onerror=null;"> | |
<!--<![endif]--><!--[if lte IE 9]> | |
<img src="img/wordmark.png"> | |
<![endif]--> |
This file contains 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
# CSS/JS auto-versioning | |
RewriteEngine On | |
RewriteRule ^(.*)\.[\d]{10}\.(css|js)$ $1.$2 [L] |
This file contains 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($){ | |
$.fn.Tabs=function(speed){ /* tabs transition speed parameter */ | |
return this.each(function(){ | |
/* define/cache variables */ | |
var tabs=$(this), | |
tabsLabels=tabs.children("ul"), | |
tabLabel=tabsLabels.find("a"), | |
tabsContent=tabs.children("div"), | |
tabLink, | |
tabsLoader=tabsContent.children(".ajax-loader"); /* define ajax loader element */ |
This file contains 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
/* | |
For some reason, the change() event only fires when the input field loses focus. | |
Binding to other options ('change keypress paste focus textInput input') will | |
fire the event several times, which is bad. The below code works even when | |
content is pasted into the text field, and only fires once as expected. | |
*/ | |
$('#search-form .term').bind('input', function(){ | |
console.log('this actually works'); | |
}); |