zoukankan      html  css  js  c++  java
  • shop--1.创建maven项目

    加入运行时所需要的包

    j2se-1.5 但是用的jdk是1.8所以在pom.xml中的<bulid></bulid>中加入
    <plugins>
      <plugin>
       //http://mvnrepository.com/search?q=maven-compiler-plugin 要把denpendency去掉
       <!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-compiler-plugin -->
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
    <version>3.7.0</version>
    //然后指明使用的源等信息
    <configuration>
            <source>1.8</source>
            <target>1.8</target>
            <encoding>UTF8</encoding>
          </configuration>
    </plugin>
    </plugins>

    接着建包

     保证输出的在一个folder下

    改动相关配置

    其中改Dynamic Web Module

    需要在项目目录下更改

    <?xml version="1.0" encoding="UTF-8"?>
    <faceted-project>
      <fixed facet="wst.jsdt.web"/>
      <installed facet="wst.jsdt.web" version="1.0"/>
      <installed facet="java" version="1.8"/>
      <installed facet="jst.web" version="3.1"/>
    </faceted-project>

    接着更改web.xml中的

    <web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
            xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
             http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
            version="3.1">
      <display-name>Archetype Created Web Application</display-name>
      <welcome-file-list>
        <welcome-file>index.jsp</welcome-file>
        <welcome-file>index.html</welcome-file>
      </welcome-file-list>
    </web-app>

    访问index.html 即可

  • 相关阅读:
    BZOJ 4245: [ONTAK2015]OR-XOR
    BZOJ 2535: [Noi2010]Plane 航空管制2
    COGS 2551. 新型武器
    cogs2550. 冰桥,升起来了!
    大数模板
    uva 1513(线段树)
    uva 11525(线段树)
    poj 3368(RMQ模板)
    hdu 4686 Arc of Dream(矩阵快速幂)
    poj 3321 Apple Tree(树状数组)
  • 原文地址:https://www.cnblogs.com/windbag7/p/9322124.html
Copyright © 2011-2022 走看看