iT邦幫忙

0

請問我用php的include語法問題

請問我用php的include語法問題
原始碼如下:

<html xmlns="http://www.w3.org/1999/xhtml">

<meta http-equiv="Content-Type" content="text/html; charset=big5" />
<title>無標題文件</title>
<style type="text/css">
<!--
body {
margin-left: 0px;
margin-top: 0px;
margin-right: 0px;
margin-bottom: 0px;
}
-->
</style>

<table width="100%" border="0" align="center">
<tr>
<td><?php echo include("top01.php")?></td>
</tr>
<tr>
<td><?php echo include("top02.php")?></td>
</tr>
</table>
<table width="100%" border="0">
<tr>
<td width="14%"><table width="100%" border="0">
<tr>
<td><?php echo include("left01.php")?></td>
</tr>
<tr>
<td> </td>
</tr>
</table></td>
<td width="86%"><?php echo include("main01.php")?></td>
</tr>
</table>

出來的畫面卻會後面有個數字1 不知為什麼 原始碼並沒有看到

圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

1 個回答

24
fillano
iT邦超人 1 級 ‧ 2008-08-06 09:28:58
最佳解答

include()前面不用加echo啦....

我想是因為include成功會回傳1,所以你前面加了echo,就把這個return value也一起顯示出來了。

kane18456 iT邦新手 5 級 ‧ 2008-08-06 21:54:15 檢舉

謝謝你 解決了 就是他了 ^^b

我要發表回答

立即登入回答