Advertisement

07.02.2008 at 06:17AM PDT, ID: 23533416
[x]
Attachment Details

IIS 6.0 and below: ISAPI filter bahaves weird with GetServerVariable in PreprocHeaders

Asked by ciuly in Microsoft IIS Web Server, Delphi Programming, Internet and Delphi Programming

Hi,

I've been fiddling with this for a while now. In IIS 7.0 it works fine, but not below that.
On IIS 6.0 for example, when I call GetServerVariable on APPL_PHYSICAL_PATH I get a return code of 13 (which maps to ERROR_INVALID_DATA which is nowhere in the docs I read)
when I call GetServerVariable with APPL_MD_PATH, PATH_INFO or PATH_TRANSLATED, it returns an empty string.
again, all the above work fine in IIS 7.0

INSTANCE_META_PATH and URL returns ok.

I'm working on an url rewrite filter, which now has a configuration file per site and possible per directory. something like apaches .htaccess, but this is a filter config file.
I need the root of the site on disk so I can translate the url root to a physical path and read the config.
all this must be done in preproc headers as I need the config before I rewrite (or not, depending on some config entries) the url.

If there is no configuration option or other ways of making the getservervariable to behave as in 7.0, how can I get the root directory of a site or virtual folder, working on all IIS versions, or at least below 7.0?Start Free Trial
[+][-]07.04.2008 at 02:14AM PDT, ID: 21931867

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.04.2008 at 02:16AM PDT, ID: 21931873

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.04.2008 at 02:22AM PDT, ID: 21931898

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.04.2008 at 02:42AM PDT, ID: 21931999

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.04.2008 at 02:51AM PDT, ID: 21932033

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.04.2008 at 02:55AM PDT, ID: 21932047

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.04.2008 at 03:01AM PDT, ID: 21932076

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.14.2008 at 03:53AM PDT, ID: 21996961

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Microsoft IIS Web Server, Delphi Programming, Internet and Delphi Programming
Sign Up Now!
Solution Provided By: ciuly
Participating Experts: 1
Solution Grade: A
 
 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_EXPERT_20070906