<?php

class CurrencyHelper {
	
	public static function centToEuroString($value) {

		$centInt = intval($value);
		$cents = '00';
		$euros = '0';
		if ($centInt >= 100) {
			$cents = intval(substr($value, strlen($value)-2));
			$euros = substr($value, 0, strlen($value)-2);
		} else {
			$cents = $value;
		}
		
		if($cents == 0) {
			$cents = '00';
		} else if ($cents < 10) {
			$cents = '0'.$cents;
		}
		
		return $euros.','.$cents.' €';
	}
}

?>