This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

mrdavidbwaters4160
mrdavidbwaters4160

Hey, I want to pull in the same thing as $_SERVER['REQUEST_URI'] using Twig and {{ app.request.uri }} doesn't work, any suggestions? i.e. <link ... href=" http://this.url<?=$_SERVER['REQUEST_URI']?>"/>

gergo85
gergo85

Markup: <link ... href="<?= $domain.'/'.$url ?>">

Code:

function onStart()
{
    $this['domain'] = Request::root();
    $this['url'] = Request::path();
}

Last updated

1-2 of 2

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.