@param Faq $faq
@param int $absolute

@return string
431255
public function getArticleShowPermalink(Faq $faq, $absolute = 1)
    {
        return $this->getContainer()->get('router')->generate($this->getArticleShowRoute(), $this->getArticleShowRouteParameters($faq), $absolute);
    }
265686
public function floatDiffInMonths($date = null, $absolute = true)
    {
        $start = $this;
        $end = $this->resolveCarbon($date);
        $ascending = ($start <= $end);
        $sign = $absolute || $ascending ? 1 : -1;
        if (!$ascending) {
            $_end = $start;
            $start = $end;
            $end = $_end;
            unset($_end);
        }
        $monthsDiff = $start->diffInMonths($end);
        /** @var Carbon|CarbonImmutable $floorEnd */
        $floorEnd = $start->copy()->addMonths($monthsDiff);

        if ($floorEnd >= $end) {
            return $sign * $monthsDiff;
        }

        /** @var Carbon|CarbonImmutable $startOfMonthAfterFloorEnd */
        $startOfMonthAfterFloorEnd = $floorEnd->copy()->addMonth()->startOfMonth();

        if ($startOfMonthAfterFloorEnd > $end) {
            return $sign * ($monthsDiff + $floorEnd->floatDiffInDays($end) / $floorEnd->daysInMonth);
        }

        return $sign * ($monthsDiff + $floorEnd->floatDiffInDays($startOfMonthAfterFloorEnd) / $floorEnd->daysInMonth + $startOfMonthAfterFloorEnd->floatDiffInDays($end) / $end->daysInMonth);
    }
417786
public function getUrl( $absolute = TRUE ){
		$url	= new ADT_URL( getEnv( 'REQUEST_URI' ) );
		if( $absolute ){
			$url->setScheme( getEnv( 'REQUEST_SCHEME' ) );
			$url->setHost( getEnv( 'HTTP_HOST' ) );
		}
		return $url;
	}
549661
public function setAbsolute($absolute)
    {
        $this->absolute = (bool)$absolute;
        if (($this->absolute) && ($this->isRelative())) {
            $this->setRelative(false);
        }
        return $this;
    }
793120
public function reorderDisplay(Faq $faq, int $newIndex)
    {
        $this->reorder('order_to_display')
            ->withPrimaryKey($faq->getId())
            ->toNewIndex($newIndex)
            ->executeOn($this->connection);

        $faq->orderToDisplay = $newIndex;
    }
1322860
public function moduleAsset($asset, $module = null, $absolute = false)
    {
        return $this->createAssetPath($asset, $module, $absolute, true);
    }
1211752
protected function generateStandardUrl(array $urlParameters = array(), $absolute = false)
    {
        $urlParameters = $this->addRequestVariablesToUrlParameters($urlParameters);

        $anchor = '';
        if ($this->hasAnchor())
        {
            $anchor = '#'.$this->getAnchor();
        }

        return $this->getRouter()->generate($this->getRouteName(), $urlParameters, $absolute) . $anchor;
    }
506081
public function apply($absolutePath)
    {
        $info = pathinfo($absolutePath);

        if (isset($info['extension']) && false !== strpos(strtolower($info['extension']), 'pdf') && file_exists($absolutePath)) {
            // If it doesn't exist yet, extract the first page of the PDF
            $previewFilename = $this->getPreviewFilename($absolutePath);
            if (!file_exists($previewFilename)) {
                $this->imagick->readImage($absolutePath . '[0]');
                $this->imagick->setImageFormat('jpg');
                $this->imagick->mergeImageLayers(\Imagick::LAYERMETHOD_FLATTEN);
                $this->imagick->writeImage($previewFilename);
                $this->imagick->clear();
            }

            $absolutePath = $previewFilename;
        }

        return $absolutePath;
    }
1185537
protected static function absolute($relativeURL) {
    $protocol = 'http';
    $url = $protocol.'://'.rtrim($_SERVER['HTTP_HOST'],'/');
    
    $url .= $relativeURL;
    
    return $url;
  }
1299320
public function handle($absolutePath, $relativePath)
    {
        $safePath = $this->safePath($relativePath);
        $this->encodeStimulusImages($absolutePath);

        $info = $this->getItemSource()->add($absolutePath, basename($absolutePath), $safePath);
        \common_Logger::i('Stimulus file \'' . $absolutePath . '\' copied.');

        return $info;
    }
1036039
protected function absoluteUrl()
    {
        if (! Str::startsWith($this->url, ['http', 'https'])) {
            return URL::to($this->url);
        }

        return $this->url;
    }
1286580
public function relativize(string $absolutePath): string
    {
        $relativePath = \str_replace($this->workingDirectory, '.', $absolutePath);

        return \is_dir($absolutePath) ? \rtrim($relativePath, \DIRECTORY_SEPARATOR) . \DIRECTORY_SEPARATOR : $relativePath;
    }
449644
public function getPreviousUrl($absolute = false)
    {
        return $this->hasPrevious() ? $this->getUrl($this->getPrevious(), $absolute) : null;
    }
787679
public function getArticlesIndexPermalink(array $parameters = [], $absolute = 1)
    {
        return $this->getContainer()->get('router')->generate($this->getArticlesIndexRoute(), $this->getArticlesIndexRouteParameters($parameters), $absolute);
    }
1333688
function afficheFaq()
    {
        $html = '';
        $t = new Template('modules/archi/templates/');
        $t->set_filenames(array('faq'=>'faq.tpl'));
        
        $t->assign_vars(array('urlEnregistrement'=>$this->creerUrl('', 'inscription')));
        $t->assign_vars(array('urlRecherche'=>$this->creerUrl('', 'recherche', array('submit'=>'Rechercher', 'motcle'=>''))));
        ob_start();
        $t->pparse('faq');
        $html .= ob_get_contents();
        ob_end_clean();
        
        return $html;
    }
1010577
public function relativizePath($absolutePath): string
    {
        $absolutePath = $this->normalizeSlashes($absolutePath);

        // see if the path is even in the root
        if (false === strpos($absolutePath, $this->rootDirectory)) {
            return $absolutePath;
        }

        $absolutePath = $this->realPath($absolutePath);

        // str_replace but only the first occurrence
        $relativePath = ltrim(implode('', explode($this->rootDirectory, $absolutePath, 2)), '/');
        if (0 === strpos($relativePath, './')) {
            $relativePath = substr($relativePath, 2);
        }

        return is_dir($absolutePath) ? rtrim($relativePath, '/').'/' : $relativePath;
    }
311493
public static function to_absolute_attribute($attribute, $content, $base_url = null)
    {
        return preg_replace('/('.$attribute.'=[\'"])\//', '$1'.rtrim($base_url, '/').'/', $content);
    }