src/FS/File/CSS/Combiner.php
public function combineFile( $fileUri )
	{
		$pathName	= dirname( realpath( $fileUri ) )."/";
		$fileBase	= preg_replace( "@\.css@", "", basename( $fileUri  ));
		
		if( !file_exists( $fileUri ) )
			throw new Exception( "Style File '".$fileUri."' is not existing." );
			
		$this->statistics	= array();
		$content	= file_get_contents( $fileUri );
	
		$content	= $this->combineString( $pathName, $content );
		$fileName	= $this->prefix.$fileBase.$this->suffix.".css";
		$fileUri	= $pathName.$fileName;
		$fileUri	= str_replace( "\\", "/", $fileUri );

		file_put_contents( $fileUri, $content );
		return $fileUri;
	}
public function combineFile( $fileUri )
	{
		$pathName	= dirname( realpath( $fileUri ) )."/";
		$fileBase	= preg_replace( "@\.css@", "", basename( $fileUri  ));
		
		if( !file_exists( $fileUri ) )
			throw new Exception( "Style File '".$fileUri."' is not existing." );
			
		$this->statistics	= array();
		$content	= file_get_contents( $fileUri );
	
		$content	= $this->combineString( $pathName, $content );
		$fileName	= $this->prefix.$fileBase.$this->suffix.".css";
		$fileUri	= $pathName.$fileName;
		$fileUri	= str_replace( "\\", "/", $fileUri );

		file_put_contents( $fileUri, $content );
		return $fileUri;
	}
public function combineFile ( $ fileUri ) { $ pathName = dirname ( realpath ( $ fileUri ) ) . "/" ; $ fileBase = preg_replace ( "@\.css@" , "" , basename ( $ fileUri ) ) ; if ( ! file_exists ( $ fileUri ) ) throw new Exception ( "Style File '" . $ fileUri . "' is not existing." ) ; $ this -> statistics = array ( ) ; $ content = file_get_contents ( $ fileUri ) ; $ content = $ this -> combineString ( $ pathName , $ content ) ; $ fileName = $ this -> prefix . $ fileBase . $ this -> suffix . ".css" ; $ fileUri = $ pathName . $ fileName ; $ fileUri = str_replace ( "\\" , "/" , $ fileUri ) ; file_put_contents ( $ fileUri , $ content ) ; return $ fileUri ; }
Combines all CSS Files imported in Style File, saves Combination File and returns File URI of Combination File.
@access		public
@param		string		$styleFile		File Name of Style without Extension (iE. style.css,import.css,default.css)
@param		bool		$verbose		Flag: list loaded CSS Files
@return		string
Combines all CSS Files imported in Style File saves Combination File and returns File URI of Combination File .