<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Appsettings_model extends CI_Model {

    public function __construct() {
        parent::__construct();
    }


 function getappsettings($name) {
        $this->db->select('CONTENT');
                $this->db->where('NAME', 'AppSettings');
        $data=$this->db->get('RESOURCES')->row();
        $xml = simplexml_load_string(htmlspecialchars_decode($data->CONTENT));
        foreach ($xml as $key0 => $value) {
                        foreach ($value->attributes() as $attributeskey0 => $attributesvalue1) {
                            if ($key0 == $name) {
                                 return $attributesvalue1;
                            }
                        }
        }
        return null;
       
    }

}