It depends upon how the site has been coded.
Some sites use CFINCLUDE in each page to place a navigation or menu on the page.
Some sites place the nav/menu code (or a CFINCLUDE to it) in the onRequest page, so it loads on every page.
In a nutshell, without knowing anything about your site, we can't answer your question. How is your inherited project laid out?
Ideally, your ajax calls should go to to a different location that don't render UI elements. Adding a bunch of IF conditions around the code just just sloppy and hard to read.
Tans for the reply,
The problem is there is no place where it specifically as for another page like a header. i am making the assumption that it is setup within the ColdFusion configuration itself. Is there flag to include this unnecessary information with my ajax call? st raw output in whatever I deem fit. I don't want to have to turn it off in the ColdFusion configuration then see if anything is broken. Any hack would work.
I am not completely versed with CFAdmin, but I am not aware of any setting in CFAdmin that could be set to automatically include headers, footers, etc.
What endpoint are you calling? It sounds like it is not restful. Are you calling a CFM page with a header/footer included? Does the project use a framework that could be including a template? Are you calling a CFC directly, and if so what returntype and returnformat is being set on the called method? Without some other information this won't be something we can easily troubleshoot.