<?php
class Zend_View_Helper_Message{
	public function message($data = array()){
		$result = '';
		if(!empty($data)){
			foreach($data as $tmp){
				if($tmp['typ'] == 'error'){	
					$result .= '<div class="msg msg-error">';
					$result .= '<p><strong>'.$tmp['sprava'].'</p>';
					$result .= '<a href="#" class="close">Zatvor</a>';
					$result .= '</div>';		 																
				}else{
					$result .= '<div class="msg msg-ok">';
					$result .= '<p><strong>'.$tmp['sprava'].'</strong></p>';
					$result .= '<a href="#" class="close">Zatvor</a>';
					$result .='</div>';					
				}				
			}
		}		
		return $result;
	}
}
?>