Here we are going to write about how to get system configuration value in your custom file or anywhere else.
Inside the header data file we have add this code
create Data.php file in Magemonkeys/General/Helper/
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
public function __construct( \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig ) { $this->_scopeConfig = $scopeConfig; } public function getConfig($config_path) { return $this->_scopeConfig->getValue( $config_path, \Magento\Store\Model\ScopeInterface::SCOPE_STORE ); } |
In phtml file – add below for call helper function
1 2 |
$systemconfval = $this->helper('Magemonkeys\General\Helper\Data')->getConfig('sectionid/groupid/fieldid'); echo $systemconfval; |
Well, after performing above changes, value will be shown. Hope that helps!
If you want get query string params in controller file,...
Create di.xml and add the below code Magemonkey/Redirect/etc/frontend/di.xml [crayon-628465db9a221636730813/] Create...
You can try below code to change local date to...
Step 1: First you need to add registration.php file in...
Step1 : Override message.js in current theme file on the...