flowingwindrider Posted July 20, 2007 Share Posted July 20, 2007 I'm trying to use include() to connect to my database to insert variables gathered from an HTML form. I keep getting the dreaded header error whenever I try to process the form and send the result page using header() at the end. Am I not able to use both of these functions in one script? Quote Link to comment Share on other sites More sharing options...
TheFilmGod Posted July 20, 2007 Share Posted July 20, 2007 use ob_start() This is a quick fix and you should try coding it properly next time. Make sure you don't call header info after HTML output. Even html comment. Quote Link to comment Share on other sites More sharing options...
flowingwindrider Posted July 20, 2007 Author Share Posted July 20, 2007 I see...the php script in my include file was lodged in the body of standard html code. By deleting all the HTML and leaving strictly the php script the header error disappeared. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.