更改语句会导致数据丢失

时间:2018-01-31 15:17:09

标签: php

我需要从

更改下面的echo语句

  

php部分

<?php
  $results = $GameQ->process();
?>
  

html部分

<tr class="active">
 <td><?php echo $results[$ID]['gq_hostname']; ?></td>
</tr>

到这个

$results = $GameQ->process();   
 echo '<tr>
        <td>'.$ID.'["gq_hostname"]</td>
       </tr>';

第一个php和html部分uptop非常适合我想要改变的东西。

1 个答案:

答案 0 :(得分:1)

将您的代码更改为:

$results = $GameQ->process();   
echo '<tr>
    <td>'.$results[$ID]["gq_hostname"].'</td>
    </tr>';
相关问题