php入门问题~~求助啊,刚开始学就卡着了
这是HTML代码:<html><head><title>Bob'sAutoParts</title></head><body><formaction="processor...
这是HTML代码:
<html>
<head><title>Bob's Auto Parts</title></head>
<body>
<form action="processorder.php" method="post">
<table border="0">
<tr bgcolor="#cccccc">
<td width="150">Item</td>
<td width="15">Quantity</td>
</tr>
<tr>
<td>Tires</td>
<td align="center"><input type="text" name="tireqty" size="3"
maxlength="3" /></td>
</tr>
<tr>
<td>Oil</td>
<td align="center"><input type="text" name="oilqty" size="3"
maxlength="3" /></td>
</tr>
<tr>
<td>Spark Plugs</td>
<td align="center"><input type="text" name="sparkqty" size="3"
maxlength="3" /></td>
</tr>
<tr>
<td>How did you find Bob's?</td>
<td><select name="find">
<option value = "a">I'm a regular customer</option>
<option value = "b">TV advertising</option>
<option value = "c">Phone directory</option>
<option value = "d">Word of mouth</option>
</select>
</td>
</tr>
<tr>
<td colspan="2" align="center"><input type="submit" value="Submit Order" /></td>
</tr>
</table>
</form>
</body>
</html>
这是PHP代码:
<html>
<head>
<title>Bob 's Auto Parts - Order Resautls</title>
</head>
<body>
<h1>Bob 's Auto Parts</h1>
<h2>Order Results</h2>
<?php
echo '<p>Order processed.</p>';
?>
</body>
</html>
为什么表单提交之后显示的是
Order processed.
'; ?>
后面这些符号怎么回事?而且用IE和Chrome提交不太一样,用IE的直接请求PHP文件了,提示打开还是下载;用Chrome直接打开PHP,但是显示的是上面的东西。 展开
<html>
<head><title>Bob's Auto Parts</title></head>
<body>
<form action="processorder.php" method="post">
<table border="0">
<tr bgcolor="#cccccc">
<td width="150">Item</td>
<td width="15">Quantity</td>
</tr>
<tr>
<td>Tires</td>
<td align="center"><input type="text" name="tireqty" size="3"
maxlength="3" /></td>
</tr>
<tr>
<td>Oil</td>
<td align="center"><input type="text" name="oilqty" size="3"
maxlength="3" /></td>
</tr>
<tr>
<td>Spark Plugs</td>
<td align="center"><input type="text" name="sparkqty" size="3"
maxlength="3" /></td>
</tr>
<tr>
<td>How did you find Bob's?</td>
<td><select name="find">
<option value = "a">I'm a regular customer</option>
<option value = "b">TV advertising</option>
<option value = "c">Phone directory</option>
<option value = "d">Word of mouth</option>
</select>
</td>
</tr>
<tr>
<td colspan="2" align="center"><input type="submit" value="Submit Order" /></td>
</tr>
</table>
</form>
</body>
</html>
这是PHP代码:
<html>
<head>
<title>Bob 's Auto Parts - Order Resautls</title>
</head>
<body>
<h1>Bob 's Auto Parts</h1>
<h2>Order Results</h2>
<?php
echo '<p>Order processed.</p>';
?>
</body>
</html>
为什么表单提交之后显示的是
Order processed.
'; ?>
后面这些符号怎么回事?而且用IE和Chrome提交不太一样,用IE的直接请求PHP文件了,提示打开还是下载;用Chrome直接打开PHP,但是显示的是上面的东西。 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询