473,320 Members | 1,865 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Can you *set* Apache credentials from PHP?

Is it possible to *set* Apache credentials via PHP? I know you can
read Apache credentials from PHP, but I want PHP to tell Apache that a
session is authenticated.

Essentially, I want to do with an HTML form what Apache accomplishes
with a pop-up window.

Why? Because in addition to authenticating them, I need some other
information, and having (1) a pop-up window that auths them to Apache,
then (2) an HTML form to capture the additional info, would be awkward
from a usability perspective.

Deane

Jul 6 '07 #1
2 1527
>Is it possible to *set* Apache credentials via PHP? I know you can
>read Apache credentials from PHP, but I want PHP to tell Apache that a
session is authenticated.
You cannot set credentials in Apache. You set credentials in a browser,
which presents them to Apache (and eventually to PHP).
>Essentially, I want to do with an HTML form what Apache accomplishes
with a pop-up window.
Apache does not do pop-up windows. Browsers do pop-up windows.
>Why? Because in addition to authenticating them, I need some other
information, and having (1) a pop-up window that auths them to Apache,
then (2) an HTML form to capture the additional info, would be awkward
from a usability perspective.
Information you can set in a browser include cookies, parameters on a URL,
and indirectly you can use session data.

Jul 6 '07 #2
us****@isotopeREEMOOVEmedia.com wrote:
On Fri, 06 Jul 2007 20:40:34 -0000, Deane <de**********@gmail.comwrote:
>Is it possible to *set* Apache credentials via PHP? I know you can
read Apache credentials from PHP, but I want PHP to tell Apache that a
session is authenticated.

Essentially, I want to do with an HTML form what Apache accomplishes
with a pop-up window.

Why? Because in addition to authenticating them, I need some other
information, and having (1) a pop-up window that auths them to Apache,
then (2) an HTML form to capture the additional info, would be awkward
from a usability perspective.

Check out http://us.php.net/features.http-auth
Did you actually read this? It doesn't do anything like what he wants.

That's because it can't be done. Authentication/Authorization is
strictly between the browser and the webserver. PHP doesn't get
involved at all.

However, you can create your own authentication mechanism using session
and collect and store whatever data you want. It's pretty easy, really.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================
Jul 7 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: dave | last post by:
Hello, I'm really hoping someone can help here, i am very frustrated on this issue. If this were my linux box i'd commit myself for insanity, this setup is so frustrating! Ok, done rambling,...
1
by: conradwt | last post by:
Hi, I was wondering, is it possible to use an Apache embedded login instead of the popup dialog when using an .htaccess file? BTW, I will be using PHP and plan to use mod_auth_db{m}. If anyone has...
0
by: Helmut Tessarek | last post by:
Hi, This is just an info. Maybe someone finds it useful. I've written an Apache module using IBM DB2 as the backend database for storing user and group information. The module is designed for...
0
by: Remigiusz Samosiuk | last post by:
Hi to everyone. In our firm intranet we decided to move from PHP to ASP.NET and my task is to integrate old PHP services (apache on linux) with new server (IIS). All our php services are in...
6
by: ABC | last post by:
Follow my project, the connection database will not use Trused Connection from web server to database server. How to set DAAB's connection string with No Credentials Access?
1
by: ad | last post by:
When we new a web Service, the default in IIS is Allow Anonymous and Integrated Windows Authentication , we just use : WebService.webClass myWC= new WebService.webClass(); and then we can access...
1
by: Jersay Ballot | last post by:
http://www.experts-exchange.com/Web/Web_Servers/Apache/Q_21986629.html I found the link but it doesn't seem to help at all. I'd like to use 2 directories as root ones at the same time. If this is...
1
by: valpal | last post by:
I'd like to post database query results on a HTML page. I use Activestate Perl and DBI; my SQL server is SQL 2005, which I can only log in to using my NT authentication. My problem is with...
3
by: sandromani | last post by:
Hello, I am working at a webbased file browser, where users will be able to access, rename, delete, etc files and folders. My question is, what is the best way to handle permissions /...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.