Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE>
- <html>
- <head>
- <meta charset="UTF8">
- <title>商品表示</title>
- <link rel="stylesheet" type="text/css" href="/webshop/css/reset.css">
- <link rel="stylesheet" type="text/css" href="/webshop/css/page.css">
- </head>
- <body>
- <div id="wrapper">
- <header>
- <h1>Webshop</h1>
- </header>
- <div id="content">
- <h1><?= $title1 ?></h1>
- <div id="search_block">
- <form action="/webshop/ProductList/search" method="get">
- 検索:
- <input type="text" name="search" size="50" placeholder="商品名をいれて" value="<?=$search ?>">
- <button type="submit" name="btn" value="searchBtn">検索</button>
- </form>
- <?=$search ?>
- </div><!-- #search_block -->
- <h2><?= $title2 ?></h2>
- <?php
- if(isset($dbdata)){
- ?>
- <table>
- <tr>
- <th>商品コード</th>
- <th>商品名</th>
- <th>価格</th>
- <th>販売単位</th>
- <th>商品詳細</th>
- </tr>
- <?php
- foreach ($dbdata as $val){
- $code=htmlspecialchars_decode($val["product_code"]);
- $name=htmlspecialchars_decode($val["product_name"]);
- $price=htmlspecialchars_decode($val["product_price"]);
- $unit=htmlspecialchars_decode($val["product_unit"]);
- $desc=htmlspecialchars_decode($val["product_desc"]);
- ?>
- <tr>
- <td><?=$code?></td>
- <td><a href="/webshop/ProductList/item?pcode"><?=$name?></a></td>
- <td><?=$price?></td>
- <td><?=$unit?></td>
- <td><?=$desc?></td>
- </tr>
- <?php
- }//foreach
- ?>
- </table>
- <?php
- }//if
- ?>
- </div><!-- #content -->
- <footer>
- R4A305 2018-05-18
- </footer>
- </div><!-- #wrapper -->
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement