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
Search in posts
Search in pages


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


since 7.0.0 version


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


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