Last active
December 20, 2015 22:19
-
-
Save tristanlins/6204376 to your computer and use it in GitHub Desktop.
[Avisota 2 Example] how to use the dependency injection container
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
global $container; | |
// access the avisota subscription manager | |
/** @var \Avisota\Contao\SubscriptionManager $subscriptionManager */ | |
$subscriptionManager = $container['avisota.subscription']; | |
// subscribe global | |
$subscriptionManager->subscribe('[email protected]'); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment