Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

when you will get the message/error "headers already sent"?

Answer Posted / dhiraj

when we are using the session variable..and want to start
our session.. we use session_start(); in the very first
line.
anything occur before this line, even a single space we get
the headers already sent error.
To overcome this problem, we can use ob_start(); at the
very first line and ob_end_flush(); at the end of the
script..

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Does https prevent csrf?

921


How to define a user function?

1016


How many keywords are there in php?

1129


Why post method is used in php?

1109


Tell me what is the difference between get and post?

970


How to strip whitespace (or other characters) from the beginning and end of a string?

887


What is composer phar?

998


Explain me is it possible to destroy a cookie?

952


Do you know what is the differences between $a != $B and $a !== $B?

1003


Write a program in php to find the occurrence of a word in a string?

1077


What is die in php?

1050


Give the case where we can use get and we can use post methods?

1040


Can you define an array argument as a reference type?

923


Which function would you use to format date information in php?

976


Is php a backend?

978