Log in

View Full Version : header error with news/vb integration


WreckRman2
02-20-2001, 02:27 PM
Using WEBLOG I have created a news forum which will post the threads as news on a main page however when I include the page I get the following header error. I can't seem to find a fix. Any ideas to where I should look for the header info?

Warning: Cannot add header information - headers already sent by (output started at /home/sites/site1/web/index.php:4) in /home/sites/site2/web/forums/admin/functions.php on line 1065


Attached is my code used to extract threads for displaying as news... When called directly no errors exist.

Example: http://www.cfsforums.com/forums/news.php

When I do something as simple as follows I get the error:


<html>
<head>
</head>
<body>

<?php include('/home/sites/site2/web/forums/news.php');?>

</body>
</html>

02-20-2001, 05:47 PM
You can't call news.php like that since it includes global.php. Global.php tries to send cookie information to the user. Since you have already sent your headers this will fail thus causing the errors.

02-20-2001, 08:23 PM
Thanks, by looking at the code supplied do you know how I could create the DB connection to accomplish this with including global.php?