Subj : How to put a null character into a string? To : netscape.public.mozilla.jseng From : Christian Biesinger Date : Thu Jun 09 2005 01:40 am Hi, I was playing around a bit with JS strings. I got unexpected results: js> "\u0000".charCodeAt(0) typein:1: ReferenceError: \xC30 is not defined js> "\u0000" u0\uffff000 js> "\x00".charCodeAt(0) typein:3: ReferenceError: \xC30 is not defined js> String.fromCharCode(0) typein:4: ReferenceError: \xC30 is not defined Why \xC30? Is that expected behaviour? That was with an xpcshell from today's cvs trunk. -biesi .