Page 1 of 1

PHP code in httd.conf (APACHE WEB SERVER)

Posted: Mon Jun 02, 2008 5:45 am
by pradeep.bondla
Hi,
I am using APACHE 2.0 HTTP web server.
My requirement is....
1) I need to set a userId to a header variable (say pradeepId to set to REMOTE_USER)
2) I need redirect to some other site with this Header variable.
what I did in httpd.conf document

Code: Select all

<IfModule mod_headers.c>
       Header add REMOTE_USER pradeepId
       Header unset REMOTE_USER
</IFModule>
and after that

Redirect / http://<host>:50100/irj/portal

Now the problem is.... :cry:
I am able to redirect to the some other portal
But Header variable has not been set.
Did I make any mistake. Please send the PHP code to set the Header variable and send it to someother portal.

regards
Pradeep :banghead:

Re: PHP code in httd.conf (APACHE WEB SERVER)

Posted: Mon Jun 02, 2008 6:21 am
by onion2k
Posting the same topic in 3 folders is unnecessary. Don't do it again.

Re: PHP code in httd.conf (APACHE WEB SERVER)

Posted: Mon Jun 02, 2008 6:33 am
by pradeep.bondla
yes I know its not the right way....
But what to do? I am not a PHP user till now... and got a assignment on this... I have to solve it by evening...
that is why I posted in 3 places...