• 简单的购物车应用案例 相关代码2


    <%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
    <%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
    %>

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    <html>
      <head>
      
       
        <title>购买球类页面</title>
       
     <meta http-equiv="pragma" content="no-cache">
     <meta http-equiv="cache-control" content="no-cache">
     <meta http-equiv="expires" content="0">   
     <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
     <meta http-equiv="description" content="This is my page">
     <!--
     <link rel="stylesheet" type="text/css" href="styles.css">
     -->

      </head>
     
      <body>
         <%
        request.setCharacterEncoding("utf-8");
        if(request.getParameter("b1")!=null)
        session.setAttribute("s4", request.getParameter("b1"));
         if(request.getParameter("b2")!=null)
        session.setAttribute("s5", request.getParameter("b2")) ;
        if(request.getParameter("b3")!=null)
        session.setAttribute("s6", request.getParameter("b3"));
       
         %>
         各类球大甩卖,一律八块:<br>
         <form method="post" action="b.jsp">
         <p>
         <input type="checkbox" name="b1" value="篮球">篮球&nbsp;
         <input type="checkbox" name="b2" value="足球">足球&nbsp;
         <input type="checkbox" name="b3" value="排球">排球
         </p>
         <p>
         <input type="submit" value="提交" name="x1">
         <a href="a.jsp">买点别的</a>&nbsp;
        
         <a href="c.jsp">查看购物车</a>
         </p>
        
         </form>
      </body>
    </html>

  • 相关阅读:
    Network File System
    模拟网络抖动及网络延迟
    python with statements
    Centos 7
    Blind Carbon Copy
    git
    python time
    valgrind3.11.0
    tinycore os
    about arp_ignore arp_filter arp_announce rp_filter
  • 原文地址:https://www.cnblogs.com/www-hsy-com/p/7663680.html
Copyright © 2020-2023  润新知