Page 1 of 1

Ascii Characters Not Concatenating

Posted: Sat Aug 29, 2009 9:40 pm
by zunebuggy
I have a for loop that has a variable $myCharVar that has is set by using the ord and mid of a larger string. If I do a var_dump of $myCharVar I can see the output is (correctly): int(72) int(101) int(108) int(108) int(111) int(32) int(87) int(111) int(114) int(108) int(100) and in the for loop I also have $NewWord .= chr($myCharVar); but if I do echo $NewWord it is blank or if I do var_dump on $NewWord it returns a few string(0) "" and a few string(1) " ". I have checked the spelling of the variables. I wondered if this was an obvious mistake I made.
Thank you.

Re: Ascii Characters Not Concatenating

Posted: Sat Aug 29, 2009 9:54 pm
by requinix
Post code.

Re: Ascii Characters Not Concatenating

Posted: Sat Aug 29, 2009 9:58 pm
by zunebuggy
Sorry. I figured it out. I had a function between the two variables and was altering the wrong variable. it wasn't ovious to me before but I see it clearly now.