Forum Moderators: coopster

Message Too Old, No Replies

Same code exploding \n but different results with single/double quotes

         

JAB Creations

6:56 am on Oct 13, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I've found that in my test case exploding "\n" works as desired...but the same functions with the exact same code won't work unless I explode using '\n'.

My functions are rather extensive and I have to rigorously test them against literally hundreds of different test cases so having exact code for both the test case environment and the implemented environment is very important to me.

This is taking place on my PC home WAMP server. I'm completely unsure of what could be causing this. Is there some sort of PHP or MySQL declaration that could switch the functionality of single and double quotes?

- John

JAB Creations

8:00 am on Oct 13, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thankfully this only took me an hour to figure out...turns out that line breaks were escaped via JavaScript. Since the code was the same and there was nothing funky in the PHP I eventually realized I should check my JavaScript code. So I'm all good. :)

- John