mirror of
https://github.com/flarum/framework.git
synced 2025-02-21 07:50:24 +08:00
Redirect using configured base URL
This commit is contained in:
parent
3e804ca0b5
commit
b194f07a72
@ -1,4 +1,4 @@
|
||||
<?php
|
||||
<?php
|
||||
/*
|
||||
* This file is part of Flarum.
|
||||
*
|
||||
@ -13,6 +13,7 @@ namespace Flarum\Support;
|
||||
use Psr\Http\Message\ServerRequestInterface as Request;
|
||||
use Zend\Diactoros\Response\EmptyResponse;
|
||||
use Zend\Diactoros\Response\RedirectResponse;
|
||||
use Flarum\Core;
|
||||
|
||||
abstract class Action
|
||||
{
|
||||
@ -37,6 +38,8 @@ abstract class Action
|
||||
*/
|
||||
protected function redirectTo($url)
|
||||
{
|
||||
$url = Core::config('base_url') . $url;
|
||||
|
||||
$content = sprintf('
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
Loading…
x
Reference in New Issue
Block a user