Changeset 747 for trunk/lib/App.inc.php


Ignore:
Timestamp:
Aug 27, 2021 2:27:14 AM (3 years ago)
Author:
anonymous
Message:

Set default mysql connection charset to utf8mb4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/lib/App.inc.php

    r746 r747  
    14941494     *                                          -false  <-- To not carry any queries. If URL already has queries those will be retained.
    14951495     * @param   bool    $always_include_sid     Force session id to be added to Location header.
    1496      */
    1497     public function dieURL($url, $carry_args=null, $always_include_sid=false)
     1496     * @param   int     $http_response_code     The HTTP response code to include with the Location header. Use 303 when the redirect should be GET, or
     1497     *                                          use 307 when the redirect should use the same method as the original request.
     1498     */
     1499    public function dieURL($url, $carry_args=null, $always_include_sid=false, $http_response_code=303)
    14981500    {
    14991501        if (!$this->running) {
     
    15091511        $url = $this->url($url, $carry_args, $always_include_sid);
    15101512
    1511         // Should we send a "303 See Other" header here instead of relying on the 302 sent automatically by PHP?
    15121513        if (!headers_sent($h_file, $h_line)) {
    1513             header(sprintf('Location: %s', $url));
     1514            header(sprintf('Location: %s', $url), true, $http_response_code);
    15141515            $this->logMsg(sprintf('dieURL: %s', $url), LOG_DEBUG, __FILE__, __LINE__);
    15151516        } else {
Note: See TracChangeset for help on using the changeset viewer.