public function getPagesIndex($nb = 11, $absolute = false)
    {
        $space = ($nb - 1) / 2;
        $start = $this->getCurPage() - $space;
        $end = $this->getCurPage() + $space;
        if ($start < 1 && $end > $this->getNbPages()) {
            $start = 1;
            $end = $this->getNbPages();
        } elseif ($start < 1) {
            $start = 1;
            $end = $nb - 1;
        } elseif ($end > $this->getNbPages()) {
            $end = $this->getNbPages();
            $start = $end - $nb + 1;
        }

        if ($start < 1) {
            $start = 1;
        }
        if ($end > $this->getNbPages()) {
            $end = $this->getNbPages();
        }

        $ret = array();
        for ($i = $start; $i <= $end; ++$i) {
            $ret[$i] = array(
                $this->getUrl($i, $absolute),
                $i == $this->getCurPage(),
            );
        }

        return $ret;
    }