Wednesday, March 25, 2009

Session problems while developing multilingual pages in PHP

You need to use UTF encoding for files while developing multilingual pages.
In that case, if you are using sessions then PHP interpreter may give a warning like "session_start() [function.session-start]: Cannot send session cache limiter - headers already sent". even when session_start() is the line of the code.

This can be avoided by using "UTF without BOM" (byte order mark) instead of just UTF encoding which does not insert extra bytes at the start of the file.