public function add($path,$type,$group='head',$priority=5,$slot=null,$params=null) {
		if (!isset($this->assets[$group]))
			$this->assets[$group]=array();
		if (!isset($this->assets[$group][$type]))
			$this->assets[$group][$type]=array();
		$asset = array(
			'path'=>$path,
			'type'=>$type,
			'slot'=>$slot
		) + ($params?:array());
		if (preg_match('/^(http(s)?:)?\/\/.*/i',$path)) {
			$asset['origin'] = 'external';
			$this->assets[$group][$type][$priority][]=$asset;
			return;
		}
		foreach ($this->f3->split($this->f3->get('UI')) as $dir)
			if (is_file($view=$this->f3->fixslashes($dir.$path))) {
				$asset['path']=ltrim($view,'./');
				$asset['origin']='internal';
				$this->assets[$group][$type][$priority][]=$asset;
				return;
			}
		// file not found
		if ($handler=$this->f3->get('ASSETS.onFileNotFound'))
			$this->f3->call($handler,array($path,$this));
		// mark unknown file as external
		$asset['origin'] = 'external';
		$this->assets[$group][$type][$priority][]=$asset;
	}