Forum Discussion
mike_gatti_6169
May 18, 2007Nimbostratus
1st, thanks much for the help,
I am using the 1st option since the list will be pretty big. In testing the rule I get the following error logged. I tried reading up and playing around with the rule but didn't get very far. This is the error:
TCL error: can't set "sites": variable is array while executing "set sites [ list \ "/site1" \ "/site2" \ ]"
her is the rule as it stands now.
when RULE_INIT {
set sites [ list \
"/site1" \
"/site2" \
]
}
when HTTP_REQUEST {
if { [matchclass [HTTP::uri] starts_with $::sites] } {
HTTP::redirect "http://www.domain.com/global/[string range [HTTP::uri] 1 end]"
}
elseif { [HTTP::uri] starts_with "/global" } {
use pool site_pool
}
}