Never mind I found the problem, my input did not have the quote character…
I recommend to just post the solution or your finding under the post because it might be helpful to other people looking for the same solution.
I had the following array where for quote character I had the backtic (the backtick is the key to the left of the numeral “1”) character. The resulting page contained invalid characters
$LOGIN_INFO = array(
‘XXXXXXX’ =&>; ‘YYYYYYY’,
‘AAAAAAAAA’ =>; ‘BBBBBBBB’
Copied from some other source…