Current time: 11-27-2024, 10:20 AM Hello There, Guest! (LoginRegister)


Post Reply 
_ENV["SERVER_PORT"] Returns wrong value
Author Message
danvanbass Offline
Newbie
*

Posts: 8
Joined: Apr 2008
Reputation: 0
Post: #1
Question _ENV["SERVER_PORT"] Returns wrong value
Hi Folks,

I have a problem with my php server values. I'm running a debian etch with ispcp rc4, fcgi and have ssl configured. Now following, I have a site on my Server that wants to access the _ENV["SERVER_PORT"] and _ENV["SERVER_PROTOCOLL] to check if someone is accessing the site with ssl or not. Now the issue is, that i always recieve Port 80 and protocoll http/1.1 as response to those variables (if i run phpinfo while connected per ssl i also recieve port 80 and http/1.1). what do i have to change in the config so that i recieve the correct information?

i guess it has to do with fcgi, but i don't quite get what i have to change..... i'm glad for any help....

cheers,

dan
08-22-2008 01:23 AM
Find all posts by this user Quote this message in a reply
RatS Offline
Project Leader
******

Posts: 1,854
Joined: Oct 2006
Reputation: 17
Post: #2
RE: _ENV["SERVER_PORT"] Returns wrong value
Try $_SERVER-Variables
08-22-2008 03:02 AM
Visit this user's website Find all posts by this user Quote this message in a reply
danvanbass Offline
Newbie
*

Posts: 8
Joined: Apr 2008
Reputation: 0
Post: #3
RE: _ENV["SERVER_PORT"] Returns wrong value
RatS Wrote:Try $_SERVER-Variables

Hi Rats,

unfortunatly i recieve the same information when i use $_SERVER-Variables... it still shows me HTTP/1.1 and Port 80 Sad any further hints?

thx, dan
08-22-2008 10:53 PM
Find all posts by this user Quote this message in a reply
Cube Offline
Member
***

Posts: 740
Joined: Apr 2007
Reputation: 9
Post: #4
RE: _ENV["SERVER_PORT"] Returns wrong value
I am using $_SERVER["SERVER_PORT"] without any problems.
08-22-2008 11:09 PM
Find all posts by this user Quote this message in a reply
danvanbass Offline
Newbie
*

Posts: 8
Joined: Apr 2008
Reputation: 0
Post: #5
RE: _ENV["SERVER_PORT"] Returns wrong value
Cube Wrote:I am using $_SERVER["SERVER_PORT"] without any problems.

well this answer doesn't really help Wink

so you see what i mean: https://admin.scb.ch/info.php

...back to my question, what do i have to change so i recieve the right information when using the $_SERVER variables??

thx, dan
08-23-2008 12:20 AM
Find all posts by this user Quote this message in a reply
RatS Offline
Project Leader
******

Posts: 1,854
Joined: Oct 2006
Reputation: 17
Post: #6
RE: _ENV["SERVER_PORT"] Returns wrong value
Das ist merkwürdig, ich habe es bei mir ohne Probleme getestet, hast du einen Proxy laufen, der HTTPS auf HTTP intern umleitet, würde das erklären.
08-23-2008 12:59 AM
Visit this user's website Find all posts by this user Quote this message in a reply
danvanbass Offline
Newbie
*

Posts: 8
Joined: Apr 2008
Reputation: 0
Post: #7
RE: _ENV["SERVER_PORT"] Returns wrong value
RatS Wrote:Das ist merkwürdig, ich habe es bei mir ohne Probleme getestet, hast du einen Proxy laufen, der HTTPS auf HTTP intern umleitet, würde das erklären.

nein hab ich nicht... ich hab eigentlich alles nach anleitung gemacht so wie es hier auf der site beschrieben ist.... muss ich irgendwo die variablen an fcgi weitergeben? was mach ich falsch? oder kann jemand von euch mal die konfig anschauen?

lg

dan
08-23-2008 01:31 AM
Find all posts by this user Quote this message in a reply
xister Offline
Member
*
Beta Team

Posts: 405
Joined: Oct 2006
Reputation: 6
Post: #8
RE: _ENV["SERVER_PORT"] Returns wrong value
English please ^^
08-23-2008 02:29 AM
Find all posts by this user Quote this message in a reply
Cube Offline
Member
***

Posts: 740
Joined: Apr 2007
Reputation: 9
Post: #9
RE: _ENV["SERVER_PORT"] Returns wrong value
Quote:well this answer doesn't really help
There are many things that do not work at all with fastcgi and that's why I wrote that. So you know at least that it is working normally.
08-23-2008 02:37 AM
Find all posts by this user Quote this message in a reply
danvanbass Offline
Newbie
*

Posts: 8
Joined: Apr 2008
Reputation: 0
Post: #10
RE: _ENV["SERVER_PORT"] Returns wrong value
xister Wrote:English please ^^

sorry for switching to german Wink

what i said is, that i don't have any proxy installed... i configured the server following the howtos here on isp-control.net.... i really appreciate any help and if someone of your team of experts would like to take a look at the configuration, i wouldn't mind....

any further suggestions? do i have to configure some part of fcgi, that the $SERVER variables deliver the right response?

thx, dan
08-23-2008 02:45 AM
Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 2 Guest(s)