With mysqli and prepared statements can I PASS IN COLUMN NAMES to 'ORDER BY'
问题 I need to be able to use prepared MYSQLI statements for security reasons. I need to be able to ORDER BY COLUMNNAME DIRECTION However, the COLUMNNAME is DYNAMIC as is the DIRECTION (ASC/DESC) When I bind mysqli parameters I get 'COLUMNNAME' 'ASC' or 'COLUMNNAME' 'DESC' Whereas what I need is NO QUOTES........ Is there anyway to do this? I have seen someone ask something similar in Are PHP MySQLi prepared queries with bound parameters secure? 回答1: It is not possible to use parameter binding for