Warning: session_start() [function.session-start]: Cannot send session cookie - headers already sent by (output started at /home/car/publ/testing/detail.php:1) in /home/car/publ/testing/detail.php on line 2

i'm getting this error.i dont have any empty whitespace in my code.

<?php
session_start();
?>
<html>
<head></head>
<body>
<form>
<?php
//code
?>
</form>
</body>
</html>

Recommended Answers

All 2 Replies

Is this file perhaps included by another one ? Then maybe that one causes the error.

You may also want to check if you have an auto-prepend file set on your server.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.