php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #66981 HTTP_HOST sould NOT have the port number
Submitted: 2014-03-29 16:29 UTC Modified: 2014-03-29 16:50 UTC
From: gontijo dot douglas at gmail dot com Assigned:
Status: Closed Package: Built-in web server
PHP Version: 5.5.10 OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: gontijo dot douglas at gmail dot com
New email:
PHP Version: OS:

 

 [2014-03-29 16:29 UTC] gontijo dot douglas at gmail dot com
Description:
------------
$_SERVER['HTTP_HOST'] value sould NOT have the port number added.

Test script:
---------------
<?php
echo $_SERVER['HTTP_HOST'];
// Expects localhost
// Outputs localhost:4035


// php -S 127.0.0.1:4035



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2014-03-29 16:50 UTC] gontijo dot douglas at gmail dot com
-Status: Open +Status: Closed
 [2014-03-29 16:50 UTC] gontijo dot douglas at gmail dot com
My bad. The ports should be added by the sent headers.

Sorry.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Fri Jul 04 17:01:35 2025 UTC