Quote:
Originally Posted by burntire
Place a zero in front of the time 09.99 and it will work.
Something in the code needs changed, but I can't figure it out.
|
it's the database.
in the XMLfile all database fields in the userfield table are set to
mediumtext as the data type... And as the name implies, it's a text field.
Text fields and numerical fields are sorted in a slightly different manner.
The Quarter Mile ET is Field55 in the userfield table. If you have access to the database, change the field type from mediumtext to type:
Decimal Length/Set: 5,3 (this will allow a range of 00.000 to 99.999 to be entered)
obviously back up the table first, before doing any operation on it.
you should do this for all numerical entry fields ... they should should NOT be text data types, especially when doing any type of sorting or calculations. as in Site Averages!
Also, because you are converting the data type at the Database level, and not restricting the user to enter only numerical data on the front end... (I haven't tested it.. but) the user will likely get a database error when entering data in the 14 field that is not between 00.000 & 99.999.
The way around this is in the AdminCP under User Profile Fields->"" Manager -> Find and click edit for the 1/4 Mile ET field. in the Regular Expression Box enter
^\d+(?:\.\d{0,3})?$ in the description box append this: (numbers ONLY, up to three decimal places)
and you're all set for 1/4 mile ET, you will have to repeat similar steps for all other numerical fields
if there is any interest and with the permission of the author, I could rewrite the XML file to incorporate the data tyoe changes and the RegEx changes, along with any other need "enhancements"