Database Driven Web Site Add Authors

I get the following error when i execute the addform for the authors

Warning: Cannot modify header information - headers already sent by (output started at /var/www/joke/includes/magicquotes.inc.php:16) in /var/www/joke/admin/authors/index.php on line 32

This is line 32 of joke/admin/authors/index.php the addform from pg 210 of the book.

header(‘Location: .’);

Any Ideas?

BTW Kevin this is a fantastic book. I have read hundreds of php tutorials on the web but never came away with much knowledge from them. I’m now beginning to understand php and mysql :smiley:

Thanks
John

Looks like I might have the same problem as beachjester with a BOM in one of the files.

I took a fresh file and named it form.html.php and checked it with ishida and it checked ok with NO BOM. Next I copied and pasted the content from the book pdf and checked it again. ishida could not open the file… so I suspect that the copy and paste is getting a weird character from the pdf.

John

so much for that theory…

I’m on a Linux computer if that makes any difference…

John

I finally found the problem a carriage return after the closing php tag ?> in the include files.

Hope this helps someone else.

John