PHP $_ENV['REQUEST_URI'] - Not Available?

 
Post new topic   Reply to topic    Aprelium Forum Index -> PHP
View previous topic :: View next topic  
Author Message
modb
-


Joined: 22 Feb 2003
Posts: 5

PostPosted: Sat Feb 22, 2003 7:23 pm    Post subject: PHP $_ENV['REQUEST_URI'] - Not Available? Reply with quote

Hello Aprellium -
I've been using Abyss now for about 3 months, it's a very robust little application and it serving my needs well. I have one problem. I use the environment variable listed in the topic for a lot of my scripts when posting form data to the web server. However, I checked the phpinfo(); and it doesn't seen to exist with my current configuration. Is there something I'm missing or is the value just not available with Abyss? Could you suggest a workaround that is as secure as using $_ENV['REQUEST_URI']? I checked with a few people about this issue and they said if the server doesn't provide it, you can't use it. Is this true, and if so is there anything I or Aprellium can do to fix it?

I'm using PHP 4.3.1 and Abyss X1 1.1.2
_________________
modb.net - learn all you can and do it with pride
Back to top View user's profile Send private message
TheLinker
-


Joined: 05 Apr 2002
Posts: 165
Location: Oslo, Norway

PostPosted: Sat Feb 22, 2003 9:11 pm    Post subject: Reply with quote

If all you want to do is test on variable's to the script, you can use $_SERVER["QUERY_STRING"] instead... also look into the $_SERVER["argv"] which holds an array of the same information.
But still... I agree with you... Abyss should support the $_SERVER["REQUEST_URI"] variable.
Back to top View user's profile Send private message Visit poster's website
modb
-


Joined: 22 Feb 2003
Posts: 5

PostPosted: Sat Feb 22, 2003 9:22 pm    Post subject: Reply with quote

I don't want to have to send usernames and passwords via $_SERVER['QUERY_STRING'], that's why I used $_ENV['REQUEST_URI'] (Apache Equiv). Thanks for the reply, I'd still like to hear some feedback from Aprellium though, please.
_________________
modb.net - learn all you can and do it with pride
Back to top View user's profile Send private message
TheLinker
-


Joined: 05 Apr 2002
Posts: 165
Location: Oslo, Norway

PostPosted: Sat Feb 22, 2003 9:42 pm    Post subject: Reply with quote

I have never used $_ENV['REQUEST_URI'] for username/password scenarios, but I don't see the different from using $_SERVER['QUERY_STRING']. Will you not pass both username and password variables as a parameters in both cases ??

If you don't want to pass these parameters using either GET or POST, you need to activate the Basic Authentication functionality built in most webservers, also Abyss. This functionality will pass username/password in the http header instead.

But which ever method you choose to use, both the username and the password is sent in cleartext over the Internet connection. Using Basic Authentication or POST for retrieving the variables, is the only way of not adding the information to your script, and the query string.
Back to top View user's profile Send private message Visit poster's website
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Sun Feb 23, 2003 1:08 am    Post subject: Re: PHP $_ENV['REQUEST_URI'] - Not Available? Reply with quote

Abyss Web Server exports the environment variable SCRIPT_NAME which has the same value as REQUEST_URI in other servers.
For your convenience, we will also include REQUEST_URI it in the future versions of the server.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
modb
-


Joined: 22 Feb 2003
Posts: 5

PostPosted: Sun Feb 23, 2003 4:10 am    Post subject: Reply with quote

Maybe that's not my problem then. Form some reason when I try to POST via form, it doesn't seem to be sending the info to the server. Even though the logs show it as POST 200 OK

I'm going to delve into it some more, and see what I can find
_________________
modb.net - learn all you can and do it with pride
Back to top View user's profile Send private message
TheLinker
-


Joined: 05 Apr 2002
Posts: 165
Location: Oslo, Norway

PostPosted: Sun Feb 23, 2003 11:19 am    Post subject: Reply with quote

If you're using the POST method in the form, the correct way of receiving the values should be $_POST["username"] and $_POST["password"] , if "username" and "password" is the name of the textfield variables in your html form.
Back to top View user's profile Send private message Visit poster's website
castis
-


Joined: 27 Apr 2004
Posts: 1

PostPosted: Tue Apr 27, 2004 1:35 am    Post subject: Same... Reply with quote

ive had my site up for a while now, but uploading and uploading over and over again got old, so i moved to using a local server! abyss... and that was the first thing that i saw wrong, pretty much the only thing... glad to see it fixed in the next version...
Back to top View user's profile Send private message AIM Address
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Tue Apr 27, 2004 4:31 pm    Post subject: Re: Same... Reply with quote

castis,

We don't consider the lack of REQUEST_URI as doing something wrong. REQUEST_URI is not in the CGI standard. It is an Apache extension. Even IIS don't use it.
Abyss is conformant to the standard, not to Apache (and Apache must be also conformant to standards, but that's another issue).
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
modb
-


Joined: 22 Feb 2003
Posts: 5

PostPosted: Tue Apr 27, 2004 11:43 pm    Post subject: Reply with quote

Thanks for all the replys :)
I just use apache now :l
_________________
modb.net - learn all you can and do it with pride
Back to top View user's profile Send private message
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Wed Apr 28, 2004 4:01 pm    Post subject: Reply with quote

Do you really want to use Apache just because Abyss Web Server doesn't have that one function let me tell you what , from my Experiance with Apache , the whole thing just sucks , it handles phpBB In a bad way and PHP is hard to install not to mention adding aliases so you now want to use Apache after all this support from all of us :(

I spend most of my time in these forums
helping people with problems with MySQL
and other problems with PHP Issues!

We hate to see you go but if you want to choose the
darkside than be my guess , Abyss Web Server: Rules!
Back to top View user's profile Send private message Visit poster's website
modb
-


Joined: 22 Feb 2003
Posts: 5

PostPosted: Wed Apr 28, 2004 10:17 pm    Post subject: Reply with quote

I'm quite experienced with Linux, and with the influx of new virii/worms for the microsoft platform, linux just seems like the way to go. It's also a lot cheaper for me to run Linux than it is MS IIS. I still use Aprelium for some testing situations on Win32 but it just doesn't suit my needs for the kinds of things im working with on the Linux platform, on a full time basis. As far as I know, it doesn't have python support, which I need because of my Zope-based applications. Also, python on Win32, well... just forget that. I think Aprelium should add python support, and then I would certainly consider trying it out on a full time basis. Thanks again for all the comments and replys. TRUSTpunk, lets not be slandering software you don't know how to use, either :)

Once again, I still use Abyss, but it doesn't have python support so I wouldn't be able to use it full time.
_________________
modb.net - learn all you can and do it with pride
Back to top View user's profile Send private message
iNaNimAtE
-


Joined: 05 Nov 2003
Posts: 2381
Location: Everywhere you're not.

PostPosted: Wed Apr 28, 2004 11:12 pm    Post subject: Reply with quote

Actually, Abyss does have Python support. We recently found out how to do it in these forums. Search for "python support" and you'll find the thread I'm referring to.

Also, you say you're good with Linux? Someone posted a thread about FreeBSD in the "Bug Reports" section; maybe you can help him out. Linux and Unix are essentially similar... I searched all around for an answser to his question, but I couldn't find anything.
_________________
Bienvenidos!
Back to top View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Thu Apr 29, 2004 9:19 am    Post subject: Reply with quote

I don't mean to be rude Modb but I do know how to use Apache , If You want a small demonstration
of me setting up Apache on port 82 and installing PHP, Perl, and whatever I can get my hands on than I will !

Just to prove my point that I was
an Apache Web Server User !

Edit: I now have Apache Web Server setup for Mr. Modb
to see , want PHP ? Perhaps some Perl ? took me 5 min!

http://os17fan.cjb.net:82/

P.S. You see that Python version of Virtual Host Creator that
me and Eznetlinks created , its ran on Abyss Web Server

::Virtual Host Creator::
http://www.multiple-sites.tk

-------------------------------------------------------------------------------------

Modb , if you need help installing Python on Abyss Web Server
I could help you by creating a tutorial in the tutorials section , abyss
does support Python so please use it , its a really cool Web Server !
Back to top View user's profile Send private message Visit poster's website
Anonymoose
-


Joined: 09 Sep 2003
Posts: 2192

PostPosted: Thu Apr 29, 2004 12:13 pm    Post subject: Reply with quote

Careful TrustPunk you'll turn into Karasu with a childish rant like that. He never said you couldn't install it, any idiot can do that, click the exe/msi same as any other Windows program. He said you didn't know how to use it, which is a whole different ball game.

TRUSTpunk wrote:
from my Experiance with Apache , the whole thing just sucks


If you have problems understanding how to edit conf files rather than use a console style interface, that doesn't mean the program sucks, it means you need to stick to using things with a gui.

TRUSTpunk wrote:
it handles phpBB In a bad way and PHP is hard to install not to mention adding aliases


TRUSTpunk wrote:
I now have Apache Web Server setup for Mr. Modb
to see , want PHP ? Perhaps some Perl ? took me 5 min!


Make your mind up ;) There's no need to go to such lengths to prove someone wrong, especially when you're proving something they haven't questioned - spend the time helping others who still want to use Abyss, not ranting like a child who lost his dummy.
Back to top View user's profile Send private message
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Thu Apr 29, 2004 1:06 pm    Post subject: Reply with quote

Modb said that I didn't know how to use that software
I wasn't being mean really , I was just proving that I
do know how to use it , I have nothing against him !
Back to top View user's profile Send private message Visit poster's website
Anonymoose
-


Joined: 09 Sep 2003
Posts: 2192

PostPosted: Thu Apr 29, 2004 1:57 pm    Post subject: Reply with quote

And I have nothing against you :) Just pointing out that installing Apache doesn't mean you know how to use it, or rather use it well - all the additional options you have access to, controls, url rewriting etc.

As it stands at the moment, there's no denying the basic feature set of Apache has a lot more to offer than Abyss and it may seem confusing to use if you don't need all the options, but that doesn't mean it sucks :D Where Abyss excels is in usability for beginners and advanced users alike - hopefully the next version of Abyss will bring a hell of a lot of new features to the table and make it an even stronger competitor.

Nice tweak on the headers of your Apache install btw, was that deliberate?
Back to top View user's profile Send private message
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Thu Apr 29, 2004 3:11 pm    Post subject: Reply with quote

I was just trying to be funny lol !
Back to top View user's profile Send private message Visit poster's website
Anonymoose
-


Joined: 09 Sep 2003
Posts: 2192

PostPosted: Thu Apr 29, 2004 5:36 pm    Post subject: Reply with quote

I meant the actual headers your server is returning - only Apache, no version etc...
Back to top View user's profile Send private message
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Thu Apr 29, 2004 6:32 pm    Post subject: Reply with quote

Oh ok , yeah I setup my server signature for
Prod in my httpd.conf file , it works great!
Back to top View user's profile Send private message Visit poster's website
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Fri Apr 30, 2004 12:44 pm    Post subject: Reply with quote

modb,

Abyss Web Server has Python support since day 1. Abyss supports all languages that can be/are conforming to the CGI specification (the list counts at least 20 scripting languages) including Python, Rebol, TCL, C, C++, PHP, Perl, Ruby, Java, Basic and Visual Basic.
Python setup instructions are very similar to those of Perl. Please contact support@aprelium.com if you still can't set it up.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
kjus
-


Joined: 20 Aug 2007
Posts: 1

PostPosted: Mon Aug 20, 2007 2:51 pm    Post subject: Reply with quote

Please, is it possible to make the $_ENV array work? To not use e.g. $_SERVER instead of $_ENV? I'm asking because I see all these variables in phpinfo...
Back to top View user's profile Send private message
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Thu Aug 30, 2007 3:08 pm    Post subject: Reply with quote

kjus wrote:
Please, is it possible to make the $_ENV array work? To not use e.g. $_SERVER instead of $_ENV? I'm asking because I see all these variables in phpinfo...


What is the problem you have with $_ENV variables? What PHP interface are you using (CGI/ISAPI/or FastCGI)?
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> PHP All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group