Re: [PHP] variable type - conversion/checking

[email protected] (tamouse mailing lists)
Newsgroups php.general
Message-ID <CAHUC_t-xf1wr7cdkjvupzP=YD57MZq1W033GwZ588Nog2E2SGQ@mail.gmail.com>
On Fri, Mar 15, 2013 at 8:34 PM, Ashley Sheridan
<[email protected]> wrote:
>>> >>>>> On Thu, Mar 14, 2013 at 7:02 PM,
>>georg<[email protected]**>
>>> >>>>>>> I have tried to find a way to check if a character string is
>>> >>>>>>> possible to
>>> >>>>>>> test whether it is convertible to an intger !

> The op wasn't about casting a string to an int but detecting if a string was just a string representation of an int. Hence using a regex to determine that. Regular expressions are not just about giving feedback to the user.

Seemed to me that was exactly what it was about.

> Thanks,
> Ash
> http://www.ashleysheridan.co.uk
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.