hmm my site works a treat and everything is fine until...... sessions !!! I am trying to add session variables to my existing site and have added session_start(); at the start of the document and i get this error
Warning: Cannot send session cookie - headers already sent by (output started at D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php:5) in D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php on line 5 Warning: Cannot send session cache limiter - headers already sent (output started at D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php:5) in D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php on line 5
Warning: Cannot send session cookie - headers already sent by (output started at D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php:5) in D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php on line 5
Warning: Cannot send session cache limiter - headers already sent (output started at D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php:5) in D:\Program Files\Apache Group\Apache\htdocs\cms\printer_pro.php on line 5
anyone help? /matt
I doubt CSS has much to do with it 😃 , but it looks like you're trying to start the session after you've already output some data ... try calling session_start() at the very beginning of the script.
<?php session_start(); ?> <html> <head> <title>Untitled Document</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> </head> <body> <?php include('db_fns.php'); require('header.php');
thats what i have at the top and still same problem /matt
I tried it out without the include files, and had no problems ... what do have in the include files?
nah i think u was right i have got it workign started with just a basic file and then found out the prob cheers /matt