function set_wwwroot($wwwroot) {
        global $CFG, $DB;

        $hostinfo = $DB->get_record('mnet_host', array('wwwroot'=>$wwwroot));

        if ($hostinfo != false) {
            $this->populate($hostinfo);
            return true;
        }
        return false;
    }
function set_wwwroot($wwwroot) {
        global $CFG, $DB;

        $hostinfo = $DB->get_record('mnet_host', array('wwwroot'=>$wwwroot));

        if ($hostinfo != false) {
            $this->populate($hostinfo);
            return true;
        }
        return false;
    }
function set_wwwroot ( $ wwwroot ) { global $ CFG , $ DB ; $ hostinfo = $ DB -> get_record ( 'mnet_host' , array ( 'wwwroot' => $ wwwroot ) ) ; if ( $ hostinfo != false ) { $ this -> populate ( $ hostinfo ) ; return true ; } return false ; }
Load information from db about an mnet peer into this object's properties

@param string $wwwroot - address of peer whose details we want to load
@return bool - indication of success or failure
Load information from db about an mnet peer into this object s properties