如果Submit
行为空,我会使用此代码显示invoice
表单按钮。如果不是,那么我会显示invoice
行值。主要问题是我无法弄清楚如何进行语法正确的更改以显示其他提交按钮,现在行发票值为。
". (empty($row['invoice'])? '<form action="page.php" method="post"><input type="submit" alt="Submit Form" value="Submit" /></form>' : $row['invoice']) ."
我认为它应该是这样的:
". (empty($row['invoice'])? '<form action="page.php" method="post"><input type="submit" alt="Submit Form" value="Submit" /></form>' : '<form action="page.php" method="post"><input type="submit" alt="Submit Form" value="Submit" /></form>' ."
也许有人可以帮我解决这个问题吗?
答案 0 :(得分:0)
复制下面的代码,你错过了)
(empty($row['invoice']))? '<form action="page.php" method="post"><input type="submit" alt="Submit Form" value="Submit" /></form>' : '<form action="page.php" method="post"><input type="submit" alt="Submit Form" value="Submit" /></form>'