/** * remove an array of files from a document head part * @param string head part type script/style etc * @param array of scripts to remove * @return null */ public function removeDocumentHeadPart($type, $remove) { $document =& JFactory::getDocument(); $docscripts =& FabrikHelperHTML::getDocumentHeadPart('scripts'); $keep = FArrayHelper::array_key_diff($docscripts, $remove); if (!defined('KOOWA')) { $type = '_' . $type; $document->{$type} = null; $document->{$type} = $keep; } else { $document->setHeadData(array($type => $keep)); } }