Jump to content

[SOLVED] String to Integer


Asheeown

Recommended Posts

I have an array value that I want to compare to another array value that is similar but they are both strings.

 

Array value one example: $x[2] = "503";

Array value two example: $y[2] = "500";

 

Now I want to check if $x[2] is greater than $y[2] and I can't do that when they are strings.  The function intval does not work.

Link to comment
https://forums.phpfreaks.com/topic/168738-solved-string-to-integer/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.