private function _mozifyMosaic()
	{
		//get image resource
		$resource = imagecreatefromstring(file_get_contents($this->imageUrl));

		//get the class
		$class = $this->getCssClassName();

		//build mosaic html
		$mosaic  = '<table width="' . $this->imageWidth . '" height="' . $this->imageHeight . '" cellspacing="0" cellpadding="0" border="0" bgcolor="#fefefe" class="' . $class . '">';
		$mosaic .= '<tbody>';
		for ($y = 0; $y < $this->imageHeight; $y+=$this->mosaicSize)
		{
			$mosaic .= '<tr>';
			for ($x = 0; $x < $this->imageWidth; $x+=$this->mosaicSize)
			{
				$color = imagecolorat($resource, $x, $y);
				$rgba = imagecolorsforindex($resource, $color);
				//$rgba['alpha'] = $rgba['alpha'];
				$color_string = $this->_rgb2hex($rgba);
				$mosaic .= '<td width="' . $this->mosaicSize . '" bgcolor="' . $color_string . '"><b></b></td>' . PHP_EOL;
			}
			$mosaic .= '</tr>' . PHP_EOL;
		}
		$mosaic .= '</tbody>';
		$mosaic .= '</table>';
		return $mosaic;
	}
private function _mozifyMosaic()
	{
		//get image resource
		$resource = imagecreatefromstring(file_get_contents($this->imageUrl));

		//get the class
		$class = $this->getCssClassName();

		//build mosaic html
		$mosaic  = '<table width="' . $this->imageWidth . '" height="' . $this->imageHeight . '" cellspacing="0" cellpadding="0" border="0" bgcolor="#fefefe" class="' . $class . '">';
		$mosaic .= '<tbody>';
		for ($y = 0; $y < $this->imageHeight; $y+=$this->mosaicSize)
		{
			$mosaic .= '<tr>';
			for ($x = 0; $x < $this->imageWidth; $x+=$this->mosaicSize)
			{
				$color = imagecolorat($resource, $x, $y);
				$rgba = imagecolorsforindex($resource, $color);
				//$rgba['alpha'] = $rgba['alpha'];
				$color_string = $this->_rgb2hex($rgba);
				$mosaic .= '<td width="' . $this->mosaicSize . '" bgcolor="' . $color_string . '"><b></b></td>' . PHP_EOL;
			}
			$mosaic .= '</tr>' . PHP_EOL;
		}
		$mosaic .= '</tbody>';
		$mosaic .= '</table>';
		return $mosaic;
	}
private function _mozifyMosaic ( ) { //get image resource $ resource = imagecreatefromstring ( file_get_contents ( $ this -> imageUrl ) ) ; //get the class $ class = $ this -> getCssClassName ( ) ; //build mosaic html $ mosaic = '<table width="' . $ this -> imageWidth . '" height="' . $ this -> imageHeight . '" cellspacing="0" cellpadding="0" border="0" bgcolor="#fefefe" class="' . $ class . '">' ; $ mosaic .= '<tbody>' ; for ( $ y = 0 ; $ y < $ this -> imageHeight ; $ y += $ this -> mosaicSize ) { $ mosaic .= '<tr>' ; for ( $ x = 0 ; $ x < $ this -> imageWidth ; $ x += $ this -> mosaicSize ) { $ color = imagecolorat ( $ resource , $ x , $ y ) ; $ rgba = imagecolorsforindex ( $ resource , $ color ) ; //$rgba['alpha'] = $rgba['alpha']; $ color_string = $ this -> _rgb2hex ( $ rgba ) ; $ mosaic .= '<td width="' . $ this -> mosaicSize . '" bgcolor="' . $ color_string . '"><b></b></td>' . PHP_EOL ; } $ mosaic .= '</tr>' . PHP_EOL ; } $ mosaic .= '</tbody>' ; $ mosaic .= '</table>' ; return $ mosaic ; }
Create a mosaic

@return  string
Create a mosaic