zend-router icon indicating copy to clipboard operation
zend-router copied to clipboard

Config option to set TreeRouteStack::baseUri

Open Erikvv opened this issue 6 years ago • 1 comments

In every project I see people working around the Url ViewHelper not working in console context.

If there was a config option like below we could have one standardized way of solving this.

<?php // config/autoload/server-url.local.php

return [
    'server_url' => 'https://example.com'
]

Example of my latest workaround: https://stackoverflow.com/a/52248041/1899162

Secondarily we could then also use this option to make the ServerUrl ViewHelper work in console context.

@weierophinney do you want this PR for this repository or for Zend\View?

Erikvv avatar Sep 09 '18 20:09 Erikvv

This repository has been closed and moved to laminas/laminas-router; a new issue has been opened at https://github.com/laminas/laminas-router/issues/3.

weierophinney avatar Dec 31 '19 22:12 weierophinney