我寫過這個html表單和一個php腳本。我希望標題和子標題以粗體和不同顏色呈現。有什麼建議麼。php html form rendering
<form action="myscript.php" method="POST">
<fieldset>
#title#
<p><label for="title"></label>
<input type="text" name="title" size="60" /></p>
<p><label for="Introduction"></label>
<textarea cols="width" rows="height" name="introduction">Introduction...</textarea></p>
#first_title or subtitle#
<p><label for="first_title"></label>
<input type="text" name="first_title" size="60" value="first para title..."></p>
<p><label for="first_para"></label>
<textarea cols="width" rows="height" name="first_para">first paragraph...</textarea></p>
#second_title or subtitle#
<p><label for="second_title"></label>
<input type="text" name="second_title" size="60" value="second para title..."></p>
<p><label for="second_para"></label>
<textarea cols="width" rows="height" name="second_para">second paragraph...</textarea></p>
<br />
<fieldset class="center">
<input type="submit" value="" />
<input type="reset" value="Clear and Restart" />
</fieldset>
</form>
這裏是PHP腳本
<?php
foreach($_REQUEST as $value) {
echo "<p>" . $value . "</p>";
}
?>
我增加了一些新的代碼,更多的澄清。
你能指定哪些元素是標題和副標題嗎?標籤或輸入?哪個? – SW4
將它們包裹在span標籤上,然後使用正常的類或ID –