Undefined variable in code: if ($_SERVER["SERVER_PORT"] != "80" && strpos($host, ':')


hi, i have some trouble with this code line

if ($_SERVER["SERVER_PORT"] != "80" && strpos($host, ':') === false) {
		} else {

i obtain this error message

Notice: Undefined variable: host in /storage/ssd4/455/1458455/public_html/galleries/dwl-wortel/index.php on line 35

Warning: Cannot modify header information - headers already sent by (output started at /storage/ssd4/455/1458455/public_html/galleries/dwl-wortel/index.php:35) in /storage/ssd4/455/1458455/public_html/galleries/dwl-wortel/index.php on line 101

what can i do?
isnt blocked page, just annoying in refreshing

i have other galleries with same code and i dont have trouble with them
i check the code its the same

oops, maybe its because i modify the htaccess files
like this: php_value display_errors 1


Hey can you check your site after removing the code from .htaccess?


after htaccess deleting
no more errors display (of course)

but for the code, maybe i need to “downgrade” the php version of my website
perhaps new php dont accept this line code


Perhaps add those two lines to your .htaccess

php_flag display_errors on
php_flag output_buffering on