BxContactConfig.php 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <?php defined('BX_DOL') or die('hack attempt');
  2. /**
  3. * Copyright (c) UNA, Inc - https://una.io
  4. * MIT License - https://opensource.org/licenses/MIT
  5. *
  6. * @defgroup Contact Contact
  7. * @ingroup UnaModules
  8. *
  9. * @{
  10. */
  11. bx_import('BxDolPrivacy');
  12. class BxContactConfig extends BxBaseModGeneralConfig
  13. {
  14. protected $_oDb;
  15. protected $_sEmail;
  16. /**
  17. * Constructor
  18. */
  19. public function __construct($aModule)
  20. {
  21. parent::__construct($aModule);
  22. $this->_aObjects = array(
  23. 'alert' => $this->_sName,
  24. 'form_contact' => $this->_sName . '_contact',
  25. 'form_display_contact_send' => $this->_sName . '_contact_send'
  26. );
  27. $this->_sEmail = '';
  28. }
  29. public function init(&$oDb)
  30. {
  31. $this->_oDb = &$oDb;
  32. $this->_sEmail = getParam('bx_contact_email');
  33. if(empty($this->_sEmail))
  34. $this->_sEmail = getParam('site_email');
  35. }
  36. public function getEmail()
  37. {
  38. return $this->_sEmail;
  39. }
  40. }
  41. /** @} */