Re: [PHP] Unix date (even more bazaar)



At 7:07 PM -0600 12/30/07, Richard Lynch wrote:
Spacing and/or control (unprintable) characters could easily be
messing you up.

Use something like:

$l = strlen($input);
for ($i = 0; $i < $l; $i++){
echo "$i: $input[$i] (", ord($input[$i]), ")<br />\n";
}
to see what you're getting.

Richard:

As usual, you are exactly right.

I found that somehow a gremlin had crept in -- I still don't understand how, but it did. So, I stepped through the string similar to what you did and replaced everything that wasn't supposed to be there.

Interesting that making a text file with the string and looking at it via a Hex Editor, I found that the gremlin was a 0A (new line), but when it was on the server, it was two characters ("High" ASCII 194/160) -- very strange.

In any event, I fixed it. I didn't have the time to run down why.

Thanks,

tedd

--
-------
http://sperling.com http://ancientstones.com http://earthstones.com
.



Relevant Pages

  • Re: The use of the in keyword in a comparision??
    ... > Thomas 'PointedEars' Lahn wrote: ... >>> I was messing around with someone elses script when I noticed that ... >>> he had used the in keyword in an if conditional to compare a string ... around with someone elses script" and "compare a string with a object" ...
    (comp.lang.javascript)
  • Re: Date Time Difference
    ... What am I messing up? ... >Public Function CountDownas String ... >Dim lTemp as long ...
    (microsoft.public.access.formscoding)
  • Re: [PHP] Miserable escape string problem
    ... Richard Lynch wrote: ... >> Google Kreme wrote: ... >> rest of the string interferes with syntax. ... I suggest you bring yourself up to speed on what escaping really means. ...
    (php.general)
  • Re: Classes, Properties, and structures
    ... > Alright, so I'm messing around with some code, and I ... > Private mstrName As String ... > Public Property NameAs String ... opposed to classes which are reference types), or when it is important to ...
    (microsoft.public.dotnet.languages.vb)
  • Classes, Properties, and structures
    ... Alright, so I'm messing around with some code, and I brought up a good ... If creating a class called "Person", and filling that class with variables, ... Private mstrName As String ...
    (microsoft.public.dotnet.languages.vb)