X-Git-Url: https://git.mxchange.org/?p=core.git;a=blobdiff_plain;f=framework%2Fmain%2Fclasses%2Fresponse%2Fhtml%2Fclass_HtmlResponse.php;fp=framework%2Fmain%2Fclasses%2Fresponse%2Fhtml%2Fclass_HtmlResponse.php;h=4150ca9d7fc156415cf8779d07153530cb307b93;hp=ebfb0a261da8d9213d646107dcb0ee8d49f0457f;hb=08a0c865dd2c8ee0b6dbf96f4f07e9ee0ce0f02b;hpb=91de23a7cb7b4c51500d8ce1df76b8af8843cb0b diff --git a/framework/main/classes/response/html/class_HtmlResponse.php b/framework/main/classes/response/html/class_HtmlResponse.php index ebfb0a26..4150ca9d 100644 --- a/framework/main/classes/response/html/class_HtmlResponse.php +++ b/framework/main/classes/response/html/class_HtmlResponse.php @@ -81,13 +81,13 @@ class HtmlResponse extends BaseResponse implements Responseable { // Throw an exception here //* DEBUG: */ return; throw new ResponseHeadersAlreadySentException($this, self::EXCEPTION_HEADERS_ALREADY_SENT); - } // END - if + } // Shall we encrypt the cookie? if ($encrypted) { // Unsupported at the moment $this->partialStub('Encryption is unsupported at the moment.'); - } // END - if + } // For slow browsers set the cookie array element first $_COOKIE[$cookieName] = $cookieValue; @@ -95,7 +95,7 @@ class HtmlResponse extends BaseResponse implements Responseable { // Get all config entries if (is_null($expires)) { $expires = (time() + FrameworkBootstrap::getConfigurationInstance()->getConfigEntry('cookie_expire')); - } // END - if + } $path = FrameworkBootstrap::getConfigurationInstance()->getConfigEntry('cookie_path'); $domain = FrameworkBootstrap::getConfigurationInstance()->getConfigEntry('cookie_domain'); @@ -129,7 +129,7 @@ class HtmlResponse extends BaseResponse implements Responseable { if (headers_sent()) { // Throw an exception here throw new ResponseHeadersAlreadySentException($this, self::EXCEPTION_HEADERS_ALREADY_SENT); - } // END - if + } // Assign application data $this->getTemplateInstance()->assignApplicationData($applicationInstance); @@ -145,11 +145,11 @@ class HtmlResponse extends BaseResponse implements Responseable { // Is there a / in front of the relative URL? if (substr($url, 0, 1) == '/') { $url = substr($url, 1); - } // END - if + } // No, then extend it with our base URL $url = FrameworkBootstrap::getConfigurationInstance()->getConfigEntry('base_url') . '/' . $url; - } // END - if + } // Add redirect header $this->addHeader('Location', str_replace('&', '&', $url)); @@ -181,7 +181,7 @@ class HtmlResponse extends BaseResponse implements Responseable { // Remove it from array unset($_COOKIE[$cookieName]); - } // END - if + } } /** @@ -195,7 +195,7 @@ class HtmlResponse extends BaseResponse implements Responseable { if (isset($_COOKIE[$cookieName])) { // Update the cookie $this->addCookie($cookieName, $_COOKIE[$cookieName], false); - } // END - if + } } }