On your getValue();
function, make sure you return $value['Setting']['value']
, so that on your calling function, you can just do echo $value;
For instance, I have this in my controller:
public function myFunction(){
...
$value = $this->MyModel->getName($id);
$this->set('value', $value);
}
...and I have this in my model to get the name value:
public function getName($id){
$value = $this->find('first', array(
'conditions' => array(
'id' => $id
)
));
return $value['MyModel']['name'];
}
...and so in your view, you can do:
echo $value;