Perfect! And it's working great. But here's the catch... One of my fields is based on an IF statement, so it could potentially be showing data from one field or the other field.
Basically, this is what is displayed in the recordset table results.
<?php if($to == $sess) {
echo $frm;
} else {
echo $to;
}
My question is ... which field would I actually bind the sort to given this scenario? Ack! :/
Also, I want to use a default sort order, which could complicate things even more. I guess I would have to use an if statement within the query to choose between two queries depending on if a sort order is specified or not? Is this possible?
EXAMPLE: if ((((!isset($_GET["sort"]))?$_GET["sort"]:"") = "")) { — something like this? Would this even work?
Thank you! :)