wpDiscuz 7 API Documentation

  1. Home
  2. Docs
  3. wpDiscuz 7 API Documentation
  4. Actions
  5. wpdiscuz_front_scripts
Generic selectors
Exact matches only
Search in title
Search in content
Post Type Selectors

wpdiscuz_front_scripts

This action can be used for loading some scripts or styles on the front-end pages where the wpDiscuz is loaded.

Changelog

since 7.0.0 version

Parameters

$options (type: WpdiscuzOptions object) – the object of the wpDiscuz options

Usage

add_action("wpdiscuz_front_scripts", function ($options) {
    wp_enqueue_script("custom-script", "CUSTOM_FILE_URL", [], null, $options->general["isLoadScriptsInFooter"]);
});

Was this article helpful to you? Yes No