PHP session start “Cannot send session cookie and cache limiter”

前端 未结 3 1882
野的像风
野的像风 2021-01-14 03:10

I\'ve changed my hosting server from a Windows to a Linux system. But when I run my PHP program, I get this errors:

Warning: session_start() [function.sessio         


        
3条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2021-01-14 03:29

    You get the error because there are some output before you have initiated session_start(); This could be caused because of your editor that include a BOM character in the beginning of your file. Try open the code in notepad and see if there are any lines before session_start(), (spaces) or things like that and remove them.

    To fix your editor if it add a bom in your file, you need to go to your settings and turn it off.

提交回复
热议问题