Currently the CSS and JS files are loaded in hook_init for every node add and edit page even if that node doesn't use active select.

This patch only loads files when an node is using active select.

Comments

dragonwize’s picture

StatusFileSize
new2.05 KB

Forgot to pass node type in previous patch.

dragonwize’s picture

Title: Only load CSS and JS when needed » Intergration support and load files when needed

Moved the file loading to a seperate function to support integration with other modules.

Now other modules just call:

active_tags_enable_widget($id);

Where $id is either a string id of the element wrapper or an array of string ids.

This enables easy integration with modules like the popularly requested content_taxonomy module. #310135: Support for Content Taxonomy planned?

dragonwize’s picture

Forgot updated patch for last comment.

dragonwize’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.