rameshfaj Posted June 20, 2007 Share Posted June 20, 2007 Warning: Cannot modify header information - headers already sent by (output started at /home/jobspkr/public_html/login.php:9) in /home/jobspkr/public_html/login.php on line 130 I got the above error after uploading the pages.How can I get rid of it. Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/ Share on other sites More sharing options...
TheFilmGod Posted June 20, 2007 Share Posted June 20, 2007 CHECK OUT the discussion on the top of the PHP HELP Board. Its there! Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278236 Share on other sites More sharing options...
lupld Posted June 20, 2007 Share Posted June 20, 2007 The biggest problem is changing the header after an html tag, it has to come before any html tags... if that doesn't help, the board has a few extra things about them that may help... Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278237 Share on other sites More sharing options...
redarrow Posted June 20, 2007 Share Posted June 20, 2007 ob_start(); before the session start or on the top off the page ok. Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278239 Share on other sites More sharing options...
teng84 Posted June 20, 2007 Share Posted June 20, 2007 rameshfaj if the girl on the pic is you ill answer it even it was posted a million time and even if it is pined up there ASTIG!!! Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278240 Share on other sites More sharing options...
TheFilmGod Posted June 20, 2007 Share Posted June 20, 2007 rameshfaj if the girl on the pic is you ill answer it even it was posted a million time and even if it is pined up there ;D That's why I answered. But with nowadays predators, you never know. LOL! PHP freaks gives a great explanation at the top of the disscussion board. If you need help after reading it or still get header problems post them! Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278244 Share on other sites More sharing options...
rameshfaj Posted June 20, 2007 Author Share Posted June 20, 2007 That was the one that I have tried on the local server only(using tool to make the machine as server). But now I am facing the problem after the pages are uploaded in the web site.Here that doesnot work and requires a new idea.So I have asked u all for the kind help. Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278287 Share on other sites More sharing options...
lewis987 Posted June 20, 2007 Share Posted June 20, 2007 use the <meta> tags instead...thats how i managed to conquer my problem with headers Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278318 Share on other sites More sharing options...
rameshfaj Posted June 21, 2007 Author Share Posted June 21, 2007 <meta> tag in what sense? Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278972 Share on other sites More sharing options...
corbin Posted June 21, 2007 Share Posted June 21, 2007 I'm assuming what he means is that you can use a meta tag for a page redirection. You can do: <meta http-equiv="refresh" content="{delay};url={url}"> As for the header error, you cannot start a session before any kind of output unless you use buffering. For example: <?php echo '<h1>Page 1</h1>'; session_start(); ?> Will generate an error. <?php session_start(); echo '<h1>Page 1</h1>'; ?> That will not generate an error. Quote Link to comment https://forums.phpfreaks.com/topic/56320-warning-cannot-modify-header-information-headers-already-sent-by-output-star/#findComment-278992 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.