It is really strange problem. There is a new line in my address field and when i am adding that value to download in CSV file , all column messed up.
I tried to use nl2br , str_replace , encoding function to find out solution of that mess. But nothing work.
Then I talk with one GURU (Boss 🙂 ) , he told me you need to use ” in place of ‘ because PHP cant replace new line if it is quoted by single ‘.
I was just surprised, then i used the function
str_replace(array(“\r\n”, “\n\r”,”\n”,”\r”),” “,$string);
It just work in one sec 🙂
So, I want to share this information to all my PHP developers because many of them might not know so as I . 🙂