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
| if (window.devicePixelRatio > 1) { | |
| /* highDPI display */ | |
| } | |
| if (window.devicePixelRatio >= 2) { | |
| /* retina display */ | |
| } |
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
| /** | |
| * Full Height Sections | |
| * This function will expand the sections to the 100% of browser window height. | |
| * | |
| * Author: Zeshan Ahmed | |
| * Author URI: http://www.zeshanahmed.com/ | |
| * | |
| * Replace '#banner' with your targeted element's selector. | |
| */ |
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
| /* Additional Styling */ | |
| #bottom-arrow { | |
| position: absolute; | |
| width: 52px; /* Width of arrow image */ | |
| height: 32px; /* Height of arrow image */ | |
| left: 50%; | |
| margin-left: -26px; /* Horizontally centered, should be half of the 'width' */ | |
| background: url(path/to/arrow/file.png) no-repeat center center; | |
| z-index: 10; | |
| text-indent: -9999px; /* To visually hide the text inside the button */ |
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
| /** | |
| * Converts XML to JSON | |
| * Source: https://davidwalsh.name/convert-xml-json | |
| */ | |
| function xmlToJson(xml) { | |
| // Create the return object | |
| var obj = {}; | |
| if (xml.nodeType == 1) { // element |
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 runUACLCLoop() { | |
| setTimeout(function() { | |
| // Check if something is found on the page. | |
| if ( jQuery('.class_name').is(':visible') ) { // change it to another condition | |
| // Run the same function again to create the loop. | |
| runUACLCLoop(); | |
| // If nothing is found, then run the else statement. |
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
| /** | |
| * | |
| * Convert URLs in String to Anchor Links | |
| * | |
| * Help taken from: | |
| * http://stackoverflow.com/a/34732417 | |
| * | |
| * Author: Zeshan Ahmed | |
| * Author URI: http://www.zeshanahmed.com/ | |
| * |
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
| <?php // Don't copy this line if you are inserting in a file that has it already. | |
| /** | |
| * ACF Options Page | |
| * | |
| * Instructions: | |
| * Add more languages to the array below: $languages | |
| * | |
| * @author: Zeshan Ahmed <https://zeshanahmed.com/> | |
| */ |
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
| /* Component: Languages */ | |
| .languages__item { | |
| text-transform: uppercase; | |
| color: #899099; | |
| font-size: 13px; | |
| font-size: 1.3rem; | |
| line-height: 1.15; | |
| } | |
| .languages__item--current { | |
| color: #212121; |