简体   繁体   English

如何使用HTML表将数据库获取值从一页发布到上一页

[英]how to post database fetch values from one page to anthor page using HTML table

in this code 在这段代码中

"<td align="left"><a href="admin_order_update.php">' .$row['o_id'] .'</a></td>"

i generate multiple o_id so when i click on other particular o_id this o_id post by other page and on that behalf i can access this o_id in multiple pages but im trying to use hidden type but it not working so any other process to post this value other page.... it is possible to send this so please help me.... 我生成了多个o_id,因此当我单击其他特定o_id时,可以通过其他页面访问该o_id,并且可以代表我在多个页面中访问此o_id,但是我试图使用隐藏类型,但无法正常工作,因此任何其他进程可以将该值发送给其他用户页面...。可以发送此邮件,所以请帮助我。
and one more thing i using hidden type but is not working also how it's work for post the value from one page to other page using html in php tag.... 还有一件事,我使用隐藏类型,但无法正常工作,如何使用php标签中的html将值从一页发布到另一页。...

$sql1 = " select count(status) as count from bill_generation_request where hotel_id = '$hid' and status ='yes'";

$result = mysql_query($sql1);

        while ($row = mysql_fetch_array($result))
    {
    $count = $row['count'];
    }

 echo '<table align="center" cellspacing="0" cellpadding="5" width="0%" border="1"> <tr>        
        <td align="left"><b>Bill Request Count</b></td>';   
 echo '<td align="left">' .$count . '</td> ';
 echo '</tr>';
 echo '</table>';
echo '<table align="center" cellspacing="0" cellpadding="5" width="75%" border="1">
 <tr>
 <td align="left"><b>Order Number</b></td>
 <td align="left"><b>Table Number</b></td>
 <td align="left"><b>Item Count</b></td>
 <td align="left"><b>Order Time</b></td>
 <td align="left"><b>Total Amount</b></td>
 <td align="left"><b>Order Note</b></td>
 <td align="left"><b>Note</b></td>
 </tr> ';
$i=0;
while ($row = mysql_fetch_array($res))
    {   
        $oid = $row['o_id'];
     echo '<tr bgcolor="' . $bg . '">
         <td align="left"><a href="admin_order_update.php">' .$row['o_id'] .'</a></td>
         <td align="left">' . $row['tableid'] . '</td>
         <td align="left">' . $row['total_count'] . '</td>
         <td align="left">' .$row['time'] . '</td>
         <td align="left">' .$row['amount'] . '</td>
         <td align="left">' .$row['onote'] . '</td>
         <td align="left">' .$row['note'] . '</td>
         </tr>';

    $i++;
    }

 echo '</table>';


mysql_close($con);

Try like 尝试像

$id = $row['o_id'];
<td align="left"><a href="admin_order_update.php?id=$id">' .$row['o_id'] .'</a></td>

and Use $_GET['id'] to get that id 并使用$ _GET ['id']获取该ID

Try this 尝试这个

$id = $row['o_id'];
<td align="left"><a href="admin_order_update.php?id=$id">' .$row['o_id'] .'</a></td>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 我怎样才能单独在MySQL数据库的表中选择一行在php的anthor页面中? - how can i select one row from table in MySQL database alone in anthor page with php? 如何使用在另一个php页面的一个html页面中定义的用户输入从Oracle数据库中获取数据 - how to use a user input defined in one html page in another php page to fetch data from oracle database 如何使用锚标记将信息从一个页面发送到另一个页面,并从php中的数据库中获取数据 - how to send information form one page to another page using anchor tag and fetch data from database in php 如何从PHP页面上的数据库表中获取数据 - How to fetch data from database table on PHP page 如何在一页php html中显示数据库中的图像? - how to display image from database in one page php html? 无法使用POST提取页面 - Unable to fetch page using POST 如何在不刷新PHP页面的情况下按按钮获取HTML文本框中的数据库值? - How to fetch database values in html text boxes on button press without refreshing page in php? 如何在不同数据库表的一个页面中显示数据 - how to display data in one page from different database table 如何获取从第一页到第三页的帖子值,作为帖子 - How to get post values from first page to third page ,as post 如何使用ajax从一个php页面发布值到另一个页面 - How to post value from one php page to another using ajax
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM