锘??xml version="1.0" encoding="utf-8" standalone="yes"?>色www永久免费视频首页在线,bdsm精品捆绑chinese,中文在线中文字幕http://www.aygfsteel.com/gen-sky/category/38662.html鍕ゆ濄佽皚璦銆佹厧琛屻佸帤縐佽杽鍙?/description>zh-cnSat, 18 Dec 2021 04:14:07 GMTSat, 18 Dec 2021 04:14:07 GMT60瑙e喅If you want an embedded database (H2, HSQL or Derby), please put it on the classpath.闂http://www.aygfsteel.com/gen-sky/archive/2021/12/15/436093.html鏄熸湡浜?/dc:creator>鏄熸湡浜?/author>Wed, 15 Dec 2021 11:59:00 GMThttp://www.aygfsteel.com/gen-sky/archive/2021/12/15/436093.htmlhttp://www.aygfsteel.com/gen-sky/comments/436093.htmlhttp://www.aygfsteel.com/gen-sky/archive/2021/12/15/436093.html#Feedback0http://www.aygfsteel.com/gen-sky/comments/commentRss/436093.htmlhttp://www.aygfsteel.com/gen-sky/services/trackbacks/436093.html

springboot欏圭洰鎼緩閬囧埌闂錛屾彁渚涗袱縐嶈В鍐蟲柟娉曪細

“Failed to configure a DataSource: 'url' attribute is not specified and no embedded datasource could be configured.”

琛ㄧず娌℃湁鎸囧畾鐨勬暟鎹簱url錛屾棤娉曢厤緗暟鎹簱

image.png

鏂規硶涓錛氫笉浣跨敤鏁版嵁婧愰厤緗?/h4>

鎴戜滑鍙互鍦⊿pring Boot欏圭洰鍏ュ彛娉ㄨВ澶勬坊鍔?exclude= {DataSourceAutoConfiguration.class}錛岃〃紺哄彇娑堟暟鎹簮鐨勮嚜鍔ㄩ厤緗?/p>

濡傦細

import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;   /**  * 琛ㄧず鍙栨秷鏁版嵁婧愮殑鑷姩閰嶇疆  */ @SpringBootApplication(exclude= {DataSourceAutoConfiguration.class}) public class SpringbootWeb01Application {       public static void main(String[] args) {         SpringApplication.run(SpringbootWeb01Application.class, args);     }   }  

鏂規硶浜岋細鎸夌収鎶ラ敊錛屾垜浠坊鍔犳暟鎹簱閰嶇疆

鎴戜滑闇瑕乤pplication.yml鏂囦歡涓嬫坊鍔犲涓嬮厤緗?/p>

server:   port: 8080 spring:   datasource:     url: jdbc:mysql://localhost:3306/springboottest     driver-class-name: com.mysql.cj.jdbc.Driver     password: 88888888     username: jiade 


浣滆咃細紼嬪簭鍛樻邯璦
閾炬帴錛歨ttps://www.jianshu.com/p/54db85befb01
鏉ユ簮錛氱畝涔?br />钁椾綔鏉冨綊浣滆呮墍鏈夈傚晢涓氳漿杞借鑱旂郴浣滆呰幏寰楁巿鏉冿紝闈炲晢涓氳漿杞借娉ㄦ槑鍑哄銆?/div>

]]>
欏甸潰杞彂鏂規硶 鍖呭惈鍏跺畠鏂囦歡http://www.aygfsteel.com/gen-sky/archive/2009/06/30/284809.html鏄熸湡浜?/dc:creator>鏄熸湡浜?/author>Tue, 30 Jun 2009 10:00:00 GMThttp://www.aygfsteel.com/gen-sky/archive/2009/06/30/284809.htmlhttp://www.aygfsteel.com/gen-sky/comments/284809.htmlhttp://www.aygfsteel.com/gen-sky/archive/2009/06/30/284809.html#Feedback0http://www.aygfsteel.com/gen-sky/comments/commentRss/284809.htmlhttp://www.aygfsteel.com/gen-sky/services/trackbacks/284809.html <head>
    <META HTTP-EQUIV="Refresh" CONTENT="0;URL=/example/hello.action">
</head>
2.
<jsp:forward page="/prosceniumAction.do?action=toIndex"></jsp:forward>




 <%@ include file="/commons/taglibs.jsp"%>







]]>
[杞琞jsp鐢熸垚闈欐侀〉紼嬪簭 http://www.aygfsteel.com/gen-sky/archive/2008/12/14/246203.html鏄熸湡浜?/dc:creator>鏄熸湡浜?/author>Sun, 14 Dec 2008 02:55:00 GMThttp://www.aygfsteel.com/gen-sky/archive/2008/12/14/246203.htmlhttp://www.aygfsteel.com/gen-sky/comments/246203.htmlhttp://www.aygfsteel.com/gen-sky/archive/2008/12/14/246203.html#Feedback0http://www.aygfsteel.com/gen-sky/comments/commentRss/246203.htmlhttp://www.aygfsteel.com/gen-sky/services/trackbacks/246203.html    
  import   java.io.*;  
  import   java.util.Map;  
   
  import   org.apache.commons.logging.Log;  
  import   org.apache.commons.logging.LogFactory;  
  import   freemarker.template.*;  
   
  public   class   MakeHtmlFile   {  
   
  private   final   Log   logger   =   LogFactory.getLog(getClass());  
   
  private   Configuration   freemarkerCfg   =   null;  
   
  private   String   templatePath   =   "";  
   
  private   String   realBuildPath   =   "";  
   
  /**  
    *    
    *   @param   realBuildPath鏍圭洰褰曠粷瀵硅礬寰? 
    *   @param   templatePath妯℃澘鐩稿璺緞錛屼笉鍖呭惈妯℃澘鍚嶇О  
    */  
  public   MakeHtmlFile(String   realBuildPath,   String   templatePath)   {  
  this.templatePath   =   templatePath;  
  this.realBuildPath   =   realBuildPath;  
  setTemplatePath();  
  }  
   
  /**  
    *    
    *   @param   templatePath:妯℃澘緇濆璺緞  
    */  
  private   void   setTemplatePath()   {  
  //   璁劇疆freemarker鐨勫弬鏁? 
  freemarkerCfg   =   new   Configuration();  
  try   {  
  File   file   =   new   File(realBuildPath+templatePath);  
  freemarkerCfg  
  .setDirectoryForTemplateLoading(file);  
  freemarkerCfg.setObjectWrapper(new   DefaultObjectWrapper());  
  freemarkerCfg.setDefaultEncoding("UTF-8");  
  }   catch   (IOException   ex)   {  
  System.out.println("No   Directory   found,please   check   you   config."n"  
  +   realBuildPath+templatePath);  
  }  
  }  
   
  /**  
    *   鐢熸垚闈欐佹枃浠? 
    *    
    *   @param   templateFileName  
    *                         妯$増鍚嶇Оeg:(biz/order.ftl)  
    *   @param   propMap  
    *                         鐢ㄤ簬澶勭悊妯℃澘鐨勫睘鎬bject鏄犲皠  
    *   @param   htmlFilePath  
    *                         瑕佺敓鎴愮殑闈欐佹枃浠剁殑璺緞,鐩稿璁劇疆涓殑鏍硅礬寰?渚嬪   "/biz/2006/5/"  
    *   @param   htmlFileName  
    *                         瑕佺敓鎴愮殑鏂囦歡鍚?渚嬪   "123.htm"  
    *   @return  
    */  
  public   boolean   buildHtml(String   templateFileName,   Map   propMap,  
  String   htmlFilePath,   String   htmlFileName)   {  
  try   {  
  Template   template   =   freemarkerCfg.getTemplate(templateFileName);  
  template.setEncoding("UTF-8");  
  //   鍒涘緩鐢熸垚鏂囦歡鐩綍  
  creatDirs(realBuildPath,   htmlFilePath);  
  File   htmlFile   =   new   File(realBuildPath   +   htmlFilePath  
  +   htmlFileName);  
  Writer   out   =   new   BufferedWriter(new   OutputStreamWriter(  
  new   FileOutputStream(htmlFile),   "UTF-8"));  
  template.process(propMap,   out);  
  out.flush();  
  return   true;  
  }   catch   (TemplateException   ex)   {  
  ex.printStackTrace();  
  logger.error("Build   Error"   +   templateFileName,   ex);  
  return   false;  
  }   catch   (IOException   e)   {  
  logger.error("Build   Error"   +   templateFileName,   e);  
  return   false;  
  }  
   
  }  
   
  /**  
    *   鍒涘緩澶氱駭鐩綍  
    *    
    *   @param   aParentDir  
    *                         String  
    *   @param   aSubDir  
    *                         浠?  /   寮澶? 
    *   @return   boolean   鏄惁鎴愬姛  
    */  
  public   static   boolean   creatDirs(String   aParentDir,   String   aSubDir)   {  
  File   aFile   =   new   File(aParentDir);  
  if   (aFile.exists())   {  
  File   aSubFile   =   new   File(aParentDir   +   aSubDir);  
  if   (!aSubFile.exists())   {  
  return   aSubFile.mkdirs();  
  }   else   {  
  return   true;  
  }  
  }   else   {  
  return   false;  
  }  
  }  
  } 


鍒潃鎬ワ紝絳夋垜瀛︿細浜嗭紝鎴戜竴姝ユ璇存槑涓浠涔堟剰鎬?


]]>
JSTL 鏍囧噯鏍囩璇存槑http://www.aygfsteel.com/gen-sky/archive/2008/12/08/245014.html鏄熸湡浜?/dc:creator>鏄熸湡浜?/author>Mon, 08 Dec 2008 05:45:00 GMThttp://www.aygfsteel.com/gen-sky/archive/2008/12/08/245014.htmlhttp://www.aygfsteel.com/gen-sky/comments/245014.htmlhttp://www.aygfsteel.com/gen-sky/archive/2008/12/08/245014.html#Feedback0http://www.aygfsteel.com/gen-sky/comments/commentRss/245014.htmlhttp://www.aygfsteel.com/gen-sky/services/trackbacks/245014.html JSTL  鏍囧噯鏍囩搴撻渶瑕佷簩涓牳蹇僯ar 鍖呮墠鑳戒嬌鐢ㄣ?br /> jstl.jar  鍜?tandard.jar 鍖?/strong>

鍦↗SP欏甸潰涓婂啓:

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>

1銆?寰幆鎺у埗鏍囩

<c:forEach>
<c:forEach>鏍囩鐢ㄤ簬閫氱敤鏁版嵁錛屽畠鏈変互涓嬪睘鎬?灞?鎬?鎻?榪?鏄惁蹇呴』 緙虹渷鍊?

items 榪涜寰幆鐨勯」鐩?鍚?鏃?
begin 寮濮嬫潯浠?鍚?0
end 緇撴潫鏉′歡 鍚?闆嗗悎涓殑鏈鍚庝竴涓」鐩?
step 姝ラ暱 鍚?1
var 浠h〃褰撳墠欏圭洰鐨勫彉閲忓悕 鍚?鏃?
varStatus 鏄劇ず寰幆鐘舵佺殑鍙橀噺 瀹冪殑灞炴у寘鎷細index 褰撳墠ID錛宑ount 涓鍏辨湁澶氬皯鏁版嵁銆?br />
2銆佸驚鐜壒鍒鍙?br /> <c:forTokens>
<c:forTokens>鏍囩鏈変互涓嬪睘鎬?灞?鎬?鎻?榪?鏄惁蹇呴』 緙虹渷鍊?
items 榪涜寰幆鐨勯」鐩?鏄?鏃?
delims 鍒嗗壊絎?鏄?鏃?
begin 寮濮嬫潯浠?鍚?0
end 緇撴潫鏉′歡 鍚?闆嗗悎涓殑鏈鍚庝竴涓」鐩?
step 姝ラ暱 鍚?1
var 浠h〃褰撳墠欏圭洰鐨勫彉閲忓悕 鍚?鏃?
varStatus 鏄劇ず寰幆鐘舵佺殑鍙橀噺 鍚?鏃?
3.鍒ゆ柇闆嗗悎涓嶄負絀?br />
${user}涓洪泦鍚?
<c:if test="${empty user}">
鏃犱俊鎭紒
</c:if>
<c:if test="${!empty user}">
鍏跺畠...
</c:if>




]]>
主站蜘蛛池模板: 长沙县| 灵宝市| 乌什县| 黄大仙区| 甘孜| 新泰市| 宁明县| 霸州市| 恩平市| 清远市| 梁河县| 汾西县| 高邮市| 汶上县| 伊春市| 双辽市| 张家口市| 东阿县| 平阴县| 饶河县| 平谷区| 巍山| 防城港市| 沂南县| 金昌市| 湖南省| 乡宁县| 衡阳县| 天镇县| 桂阳县| 志丹县| 蓬莱市| 长阳| 阜宁县| 开平市| 高州市| 永善县| 墨玉县| 秦安县| 沿河| 康马县|