Welcome Guest, Not a member yet? Register   Sign In
Charts Library
#12

[eluser]Phil Sturgeon[/eluser]
Small modification, your constructor should set the application dir automatically using APPPATH like so:

Code:
class Charts {

    var $obj;
    private $_ext_path;
    private $_img_path = "charts";

    function Charts()
    {
        $this->obj =& get_instance();
        $this->obj->load->helper('string');

                $this->_ext_path = APPPATH;

        include($this->_ext_path."/classes/pData.class");  
        include($this->_ext_path."/classes/pChart.class");
    }

// ......................

No point duplicating the config setting.


Messages In This Thread
Charts Library - by El Forum - 09-25-2008, 07:08 PM
Charts Library - by El Forum - 09-25-2008, 07:44 PM
Charts Library - by El Forum - 09-26-2008, 03:16 AM
Charts Library - by El Forum - 09-26-2008, 11:26 AM
Charts Library - by El Forum - 09-26-2008, 02:53 PM
Charts Library - by El Forum - 09-27-2008, 04:18 AM
Charts Library - by El Forum - 09-27-2008, 08:03 AM
Charts Library - by El Forum - 11-02-2008, 06:56 AM
Charts Library - by El Forum - 11-03-2008, 02:36 PM
Charts Library - by El Forum - 12-10-2008, 03:26 PM
Charts Library - by El Forum - 01-18-2009, 08:43 AM
Charts Library - by El Forum - 01-19-2009, 03:52 AM
Charts Library - by El Forum - 01-19-2009, 06:12 AM
Charts Library - by El Forum - 01-19-2009, 06:14 AM



Theme © iAndrew 2016 - Forum software by © MyBB