Add sorting field
Add sorting of values to choose like in tags attribute
Added callback to prevent SQL errors. Fixed bug in sorting.
Added error statement, was still a dummy ;)