The `Other Variable` In The Conditions

 
Post new topic   Reply to topic    Aprelium Forum Index -> URL Rewriting
View previous topic :: View next topic  
Author Message
loloyd
-


Joined: 03 Mar 2006
Posts: 435
Location: Philippines

PostPosted: Thu Nov 15, 2007 1:56 pm    Post subject: The `Other Variable` In The Conditions Reply with quote

I was trying to add a condition wherein the requested path is not an Abyss alias but I couldn't find any Variable that would serve my purpose - certainly not REQUEST_URI, REQUEST_URL, nor REQUEST_FILENAME. So I got intrigued with the "Other" Variable. Does this "Other" Variable only refer to variables obtainable from phpinfo()? There is not much information on the contextual help pages on this topic. Maybe somebody can shed some insightful light on this.

Maybe I should post this as a feature suggestion? I mean - to add a variable named as "Web Server Alias" and the usual bunch of Operators can apply here (Matches with, Does not match with, =, <>, etc.). This would help in the ease of maintaining our URL rewriting rules.
_________________

http://home.loloyd.com/ is online if the logo graphic at left is showing.
Back to top View user's profile Send private message Visit poster's website
aprelium-beta
-


Joined: 24 Jun 2004
Posts: 383

PostPosted: Thu Nov 15, 2007 6:24 pm    Post subject: Re: The `Other Variable` In The Conditions Reply with quote

loloyd,

"Other variable" means any CGI variable that the server may export about a request. They are listed in the documentation in the CGI variables section. You could also dump them using a simple SSI page:

Code:
<PRE><!-- #printenv --></PRE>


loloyd wrote:
Maybe I should post this as a feature suggestion? I mean - to add a variable named as "Web Server Alias" and the usual bunch of Operators can apply here (Matches with, Does not match with, =, <>, etc.). This would help in the ease of maintaining our URL rewriting rules.


URL rewriting rules are checked/matches before doing any alias conversion. So what could this suggested variable help you test?
_________________
Beta Testing Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
loloyd
-


Joined: 03 Mar 2006
Posts: 435
Location: Philippines

PostPosted: Fri Nov 16, 2007 6:57 am    Post subject: Re: The `Other Variable` In The Conditions Reply with quote

(Post have been removed for putting foot in mouth - I apologize).
_________________

http://home.loloyd.com/ is online if the logo graphic at left is showing.


Last edited by loloyd on Fri Nov 16, 2007 7:19 am; edited 1 time in total
Back to top View user's profile Send private message Visit poster's website
loloyd
-


Joined: 03 Mar 2006
Posts: 435
Location: Philippines

PostPosted: Fri Nov 16, 2007 7:18 am    Post subject: Reply with quote

I may have erred in my previous illustration of the scenario - sorry about that.

In this example, imagine the many aliases I have to contend with, instead of simply having an equivalent condition like:
REQUEST_URI Doesn't match an alias

Simply specifying the following conditions does not work as it presumably should:

Variable|Operator|(value)
REQUEST_URI Is not a directory
REQUEST_URI Is not a file

The following condition basically represent my aliases table - so there is a redundancy of effort, specifying the names of virtual directories in my alias table and then specifying those aliases here:


_________________

http://home.loloyd.com/ is online if the logo graphic at left is showing.
Back to top View user's profile Send private message Visit poster's website
loloyd
-


Joined: 03 Mar 2006
Posts: 435
Location: Philippines

PostPosted: Fri Nov 16, 2007 7:27 am    Post subject: Reply with quote

Hmm... I think I solved my own [strikethrough]problem[/strikethrough] stupidity.

I tried the obscure REQUEST_URL variable and it appears to work. I don't think this variable is listed in any CGI specification.

---
Edit: OK, it's official. I've gotten crazy.

I was amazed at how REQUEST_URL was working so well - and so I removed my aliases in my conditions list. To my chagrin, however, my Drupal site then failed to work properly anymore.

I conclude that Drupal's way of supporting URL-Rewrites may not be "smoothly" compatible with Abyss's way. *Sigh*. Back to the old ways/drawing board for me.
_________________

http://home.loloyd.com/ is online if the logo graphic at left is showing.
Back to top View user's profile Send private message Visit poster's website
pkSML
-


Joined: 29 May 2006
Posts: 952
Location: Michigan, USA

PostPosted: Fri Nov 16, 2007 12:46 pm    Post subject: Reply with quote

Sounds like your whole site is based on aliases!
As a rule, I try not to use them. Many fewer headaches - especially when scripting (file paths vs. URL paths).

If you can, get rid of the aliases.
_________________
Stephen
Need a LitlURL?


http://CodeBin.yi.org
Back to top View user's profile Send private message Visit poster's website
loloyd
-


Joined: 03 Mar 2006
Posts: 435
Location: Philippines

PostPosted: Fri Nov 16, 2007 1:40 pm    Post subject: Reply with quote

I have to (rely on aliases), especially on intranet sites. Some of my intranet sites rely on voluminous shareable data spread on various hard drives - highlighting the need for aliases. Hey, I can't put them all in just one basket of a 160 GB right? :P
_________________

http://home.loloyd.com/ is online if the logo graphic at left is showing.
Back to top View user's profile Send private message Visit poster's website
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Sat Nov 17, 2007 1:10 pm    Post subject: Reply with quote

loloyd,

We get the idea. What you're asking for could be solved by having the option to check a URL rewriting rule after resolving the aliases and mapping paths (the checks . That would be a nice addition to the URL rewriting system.
_________________
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 -> URL Rewriting 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