Well, you've got some weird things going on. I assume that the template you posted is your alphamenu template, so the line I had you remove, should actually go right above the ?> . However, you also are evaling the template right above the line that starts with "$query_Searchltr". And then you are also evaling mysearchbits for some reason. And then nowhere in your template are you using any variable/information that you are defining in the php code. I really can't tell what you are doing in your code.