public static function addSystemScript($script, $dir = 'js')
	{
		if ($dir != 'js')
		{
			$script = $dir . '/' . $script;
		}

		$asset = new Javascript('system', $script);

		if ($asset->exists())
		{
			if ($document = self::app('document'))
			{
				$document->addScript($asset->link());
			}
		}
	}
public static function addSystemScript($script, $dir = 'js')
	{
		if ($dir != 'js')
		{
			$script = $dir . '/' . $script;
		}

		$asset = new Javascript('system', $script);

		if ($asset->exists())
		{
			if ($document = self::app('document'))
			{
				$document->addScript($asset->link());
			}
		}
	}
public static function addSystemScript ( $ script , $ dir = 'js' ) { if ( $ dir != 'js' ) { $ script = $ dir . '/' . $ script ; } $ asset = new Javascript ( 'system' , $ script ) ; if ( $ asset -> exists ( ) ) { if ( $ document = self :: app ( 'document' ) ) { $ document -> addScript ( $ asset -> link ( ) ) ; } } }
Adds a linked script from the system to the page

@param   string  $script  Script name (optional, uses module name if left blank)
@param   string  $dir     Asset directory to look in
@return  void
Adds a linked script from the system to the page