在一個文件,我有這樣的代碼:如果值是空的就什麼都不顯示
if (theForm.lqd_9.value == "")
{
alert("You have forgotten to specify - Description!");
theForm.lqd_9.focus();
return (false);
<tr>
<td class="theadingt" align="center" height="14" width="180">
<b>Description:<span lang="en-us"><font color="#ff0000">*</font></span></b></td>
<td class="theading" align="left" height="14" width="545">
<textarea cols='48' rows='6' name="lqd_9"></textarea></td>
</tr>
,並在接收文件,我有這樣的:
<?php echo $_POST["lqd_9"]; ?>
我怎樣才能使代碼不顯示任何內容如果它留空?
'lert(「你已經忘記了A」);' – 2013-05-27 04:11:18
如果它是空的,呼應它不會有任何區別。 –
謝謝,這是一個錯字當我寫這個問題 –