August 09, 2005 Archives

09.08.2005 11:54

PHP fun (solution)

Well I found the solution on #php on substr($ret , -5) was returning html when being the last 5 char is should of returned .html. I did notice this, but having never used the substr function before I didnt think much of it. So it turns out I was returning html\n (\n is 1 char). So it needed the trim function applied: trim(substr($ret, -4);
Its just like Perls chop function, servers same purpose. There easy solution like I said. -----

Posted by DaveQB | Permanent Link | Categories: IT