Line 179 is several different calls to functions that all could be the cause of the error. What I wanted you to do was put them on separate lines like this:
if ((strpos($WA_curURL,strtolower($WA_localRoot)) !== false &&
strpos($WA_curURL,strtolower($WA_localRoot)) == 0) &&
etc, so that the error would point to which call was causing the error. If you attach the page, I can make the changes for you and attach the page again for you to test.