HorusKol
HorusKol

Reputation: 8706

Detect which other modules are enabled in a new Drupal module

I'm creating a Drupal module which doesn't necessarily depend on other modules, but could offer other options if, for example, the Path module is enabled.

What I'd like to know, and can't seem to find by searching, is whether it is possible to detect which modules are currently enabled from another module so that that module can offer options which use those modules?

Upvotes: 6

Views: 2832

Answers (1)

ceejayoz
ceejayoz

Reputation: 180023

You can also check like this:

if(function_exists('a_function_you_know_the_module_provides')) { }

Upvotes: 14

Related Questions