Add custom variable to cms block in magento

Cms content :: Hello {{variable1}},

Thanks we will contact you.


Make This function in any of your helper file.

public function getFilterContent($html = '')
		if($html != ''){
			$array = array();
			$array['variable1'] = 'customername';
			$array['variable2'] = 'Team'; /* you can set any no of variable like this */
			// loading the filter which will get the array we created and parse the block content
			$filter = Mage::getModel('cms/template_filter');
			/* @var $filter Mage_Cms_Model_Template_Filter */
			// return the filtered block content.
			return $filter->filter($html);