protected function ago()
    {
        $threshold = $this->getParameter('threshold');

        if (($this->getParameter('value') == null || $this->getParameter('value') == "0"))
            return '';
        elseif (($this->getParameter('value') != null) && $this->getParameter('value') instanceof Meta) {
            $dateTime = $this->getParameter('value');
            $dateTime = $dateTime->MetaValue;
        } elseif (($this->getParameter('value') != null) && $this->getParameter('value') instanceof Date)
            $dateTime = $this->getParameter('value');
        elseif (($this->getParameter('value') == null) || $this->getParameter('value') == 'now')
            $dateTime = $this->DateFactory->newLocalDate('@'.time());
        else{

            try {

                $dateTime = $this->DateFactory->newLocalDate($this->getParameter('value'));

            }catch(DateException $e)
            {
                return '';
            }

        }

        $datetime = $this->DateFactory->toLocalDate($dateTime);

        $now = time();

        if($now >= $datetime->toUnix())
        {
            $ago = $now - $datetime->toUnix();
        } else {
            $ago = $datetime->toUnix() - $now;
        }

        if($threshold != null && $ago > (intval($threshold)*60)) {
            return $this->format();
        }

        $text = '';
            if ($ago < 60)
                $text .= 'less than a minute';
            elseif ($ago < 120)
                $text .= 'about a minute';
            elseif ($ago < (60*60))
                $text .= ceil($ago/60) . ' minutes';
            elseif ($ago < (120*60))
                $text .= 'about an hour';
            elseif ($ago < (24*60*60))
                $text .= ceil($ago/(60*60)) . ' hours';
            elseif ($ago < (48*60*60))
                $text .= '1 day';
            else
                $text .= ceil($ago / (24*60*60)).' days';

        if($now >= $datetime->toUnix())
        {
            $text .= ' ago';
        } else {
            $text .= ' from now';
        }

        return $text;
    }