Re: WHat kind of value is this?



Captain Dondo wrote:
OK, I'm a complete PHP newbie. In fact, this is the first PHP project I've taken on... I need to make some changes to an existing codebase and add a couple of custom pages; nothing major. A good learning project. I am familiar with C and Python...

I have a snippet of code that goes like this:

         $ys_w = intval(imgid.bigw.value) + 50;
         $ys_h = intval(imgid.bigh.value) + 50;

It appears that imgid.bigX.value is of type (string), but not quite....

If you have something of type X and want it to be int, then use intval() to convert it to int.


http://www.php.net/manual/en/function.intval.php


//Aho .