word_count()

This can be useful for use with custom dimensions in Google Analytics on articles. Be sure to hook in custom fields so they can be included in the word count! It is recommended to add each custom field individually (rather than looping through all fields) to be sure that only contentful output is included. Read More »

is_analytics_allowed()

This checks several conditions to determine if analytics should be enabled for this rendering. Conditions that do not allow analytics: If "Do Not Track" header is present and the Nebula option is set to comply with that request If within the WordPress Customizer If the query string is present If the current IP address matches Read More »

is_do_not_track()

This looks for the HTTP header "HTTP_DNT" which may not be present in Microsoft Edge even when DNT is enabled. This feature, while technically supported in all browsers, is not consistently implemented across them yet. Remember: A return of "false" means the browser is allowing tracking. A return of "true" means the user has requested Read More »

limit_image_size()

Original size of this test image is 7360x4545. This image is loaded via the WYSIWYG editor from the media library. When this will not control output image sizes: This function listens for sizes to be used and limits them. Therefore there are plenty of situations where this will not limit output image sizes. If the Read More »

lazy_iframe()

This is a convenient alias of lazy_load(). Note: this function does not need to use echo as it prints immediately. This uses JavaScript to load iframes after the page has finished loading. Any iframes above the fold will be loaded immediately and any below the fold will wait for the user to scroll. These iframes Read More »

lazy_load()

Note: this function does not need to use echo as it prints immediately. This uses JavaScript to load HTML after the page has finished loading. Any element above the fold will be loaded immediately and any below the fold will wait for the user to scroll. This HTML is loaded in tags so if JavaScript Read More »

timer()

Timings are stored in and categories are separated into a array. Timings will automatically appear for developers, but the query string must be used for non-developers (or logged-out users). Server Timing API Timings are sent via the HTTP header and can be viewed in Chrome DevTools under Network by clicking the page resource and choosing Read More »