Improved .visually-hidden
Theorically bulletproof CSS class for visually hide anything and keep it accessible to ATs.
Each YouTube video has 4 generated images. They are predictably formatted as follows: | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/0.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/1.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/2.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/3.jpg | |
The first one in the list is a full size image and others are thumbnail images. The default thumbnail image (ie. one of 1.jpg, 2.jpg, 3.jpg) is: | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/default.jpg |
(function($){ | |
$(document).ready(function(){ | |
/** | |
* This part handles the highlighting functionality. | |
* We use the scroll functionality again, some array creation and | |
* manipulation, class adding and class removing, and conditional testing | |
*/ | |
var aChildren = $("header ul.menu li").children(); // find the a children of the list items |
// Event on form submission success | |
// You can paste this script to Form's custom JS Box | |
$form.on('fluentform_submission_success', function() { | |
// You can run your own JS and will be run on successful form submission | |
}); |
<?php | |
/** | |
* Get all the user ID's for the specified user roles | |
* | |
* @param array $role | |
* @return array User ID's | |
*/ | |
function get_all_user_ids_by_user_roles($role) | |
{ |
Easy Scrollspy setup for BB theme users running full Bootstrap 4 or anyone using Bootstrap 4 with BB.
For BB theme, enable full bootstrap 4 under customize > General > Layout (Or load it from CDN on a single page if not using it sitewide)
JS file add to BB page JS directly or load via external file in footer defered.
Currently using it with PowerPack's Table of Contents module, but this could be used for any list/menu of links, just change the data-target attribute.
I referred to this documentation when setting up