Robert_47833
Jul 21, 2011Altostratus
closing brackets before "else"
Hi,dear Irule
if {[class match $uri starts_with gen3abURLs_SRWD29]} {
if { rand() <0.2 } {
pool cjj-BRX set cjjA_cookie 1
return
}
else {
pool cjj-BROWSE
set cjjB_cookie 1
return
}
}
Hi,in a http request event,if I submit rule like above,it told me undefined procedure :else
but if I changed it to rule like below,it is fine,why should I put else after the closing brackets,how to work around this?
if {[class match $uri starts_with gen3abURLs_SRWD29]} {
if { rand() <0.2 } {
pool cjj-BRX
set cjjA_cookie 1
return
} else {
pool cjj-BROWSE
set cjjB_cookie 1
return
}
}