我有這樣的代碼結合了超鏈接字符串的單一顯示內
<?php echo "<td class='name'><a href='humlaInfrastructure.php?title=".$humlainfrastructure["sn"][$i]."'>".$humlainfrastructure["title"][$i]."</a></td>"; ?>
我需要添加另一個條件這裏面:
<a class="button red right" href="#" onClick="window.open('modules/addInfrastructureTitle.php','_new','fullscreen=no,location=no,width=600,height=200')"><strong>+</strong> New</a>
所以最終的代碼變得
<?php echo "<td class='name'><a href='humlaInfrastructure.php?title=".$humlainfrastructure["sn"][$i]."'>".$humlainfrastructure["title"][$i]."</a><a class="button red right" href="#" onClick="window.open('modules/addInfrastructureTitle.php','_new','fullscreen=no,location=no,width=600,height=200')"><strong>+</strong> New</a></td>"; ?>
但它顯示一個錯誤。我該如何解決它?
你報價錯誤 –
是什麼你得到的錯誤信息?發佈到SO時,包含您在屏幕上看到的錯誤總是有幫助的。 – Robbert