Print Page - Bug in Edit Route page (edit_route.php)
Airline Mogul Forum
Airline Mogul => Bugs => Topic started by: Calebrw on August 09, 2009, 10:59:54 pm
Title: Bug in Edit Route page (edit_route.php)
Post by: Calebrw on August 09, 2009, 10:59:54 pm
Got another bug for you guys.
I accidentally added a plus sign (+) behind my route number to make it "029+" instead of "029".
This produced the following error message:
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /var/www/vhosts/airlinemogul.com/httpdocs/airlinemogul/includes/cr_functions.php on line 889 0
I'll leave it be for now so you guys can review, but this error can be found in the following: Airline ID: 27386 World ID: 818 Route ID: 3608
I don't know that the actual error message can be prevented, but I figure that the input can be checked for proper format (numbers in this case).
Title: Re: Bug in Edit Route page (edit_route.php)
Post by: CHR on August 10, 2009, 11:15:27 am
The box usually does remove non-numbers, and everything after it (i.e. 16^3 goes to 16). I am guessing, but the + sign may not be filtered out when dealing with numbers so that there can be a distinction between positive and negative numbers.
I just tested it out, and it appeared to work fine, trying + before, in the middle and after.