Example #1
0
                        <th>
                            <p id="user_data">Comment</p>
                        </th>
                    </tr>
                    <tr>
                        <td>
                            <p id="user_comment_show"></p>
                        </td>
                    </tr>
                </table>
            </div>
    </div>
    <!-----------------------------END Block to show added comments by JavaScript -->
    <!--$all_comment variable to show all user comments -->
    <?php 
$all_comments = Comments_form::select_all();
?>
    <?php 
if (mysqli_num_rows($all_comments) > 0) {
    ?>
    <hr class="line">
    <!--Start .panel .panel-primaty to show all user comments -->
    <!--Show all user comment from Database -->
    <div  style="margin-top: 33px"  class="panel panel-primary">
        <?php 
    while ($res = mysqli_fetch_assoc($all_comments)) {
        ?>
            <div style="background-color: #cccccc" class="panel-body">
                <h4 style="text-align: center" ><?php 
        echo $res['user_name'];
        ?>