S Simbiat Member Sep 14, 2022 #1 Sep 14, 2022 #1 Hi! Does OLS have an alternative to "Header setifempty" directive possible in Apache?
Cold-Egg Administrator Sep 15, 2022 #2 Sep 15, 2022 #2 For OLS, you can set the header via Virtual Host > context > Header Operations, it may not check if it's empty or not. More example https://openlitespeed.org/kb/setting-up-cors-on-openlitespeed/
For OLS, you can set the header via Virtual Host > context > Header Operations, it may not check if it's empty or not. More example https://openlitespeed.org/kb/setting-up-cors-on-openlitespeed/
S Simbiat Member Sep 15, 2022 #3 Sep 15, 2022 #3 Cold-Egg said: For OLS, you can set the header via Virtual Host > context > Header Operations, it may not check if it's empty or not. More example https://openlitespeed.org/kb/setting-up-cors-on-openlitespeed/ Click to expand... I know that you can set custom headers there, but it does not support setifmepty. I am asking whether there is an alternative approach I can use with OLS, that would simulate this somehow?
Cold-Egg said: For OLS, you can set the header via Virtual Host > context > Header Operations, it may not check if it's empty or not. More example https://openlitespeed.org/kb/setting-up-cors-on-openlitespeed/ Click to expand... I know that you can set custom headers there, but it does not support setifmepty. I am asking whether there is an alternative approach I can use with OLS, that would simulate this somehow?
S Simbiat Member Sep 15, 2022 #4 Sep 15, 2022 #4 In case someone will stumble on this, in LSWS (not OLS, sadly) you can do this: Apache config: Header set header-name "GET, HEAD, OPTIONS" "expr=%{HTTP:header-name} == ''" Last edited: Sep 15, 2022
In case someone will stumble on this, in LSWS (not OLS, sadly) you can do this: Apache config: Header set header-name "GET, HEAD, OPTIONS" "expr=%{HTTP:header-name} == ''"