<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<%@ 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" %>
<%@ taglib uri="http://msqr.us/mutil/tags" prefix="m" %>
<%@ taglib uri="http://www.springframework.org/tags" prefix="spring" %>
<html>
  <head profile="<c:url value="/profile.txt"/>">
    <title><fmt:message key="setup.db.title"/></title>
    <link media="screen" href="<c:url value="/css/global.css"/>" type="text/css" rel="stylesheet" />
  </head>
  <body>
    <h1><fmt:message key="setup.db.title"/></h1>
    <p><fmt:message key="setup.db.intro"/></p>
    
	<form method="post" action="<c:url value="/setup/wizard.do"/>">
		
		<dl class="menu">
			
			<dt><fmt:message key="setup.db.hibernate.dialect.displayName"/></dt>
			<dd>
				<spring:bind path="command.settings['hibernate.dialect']">
					<select name="<c:out value="${status.expression}"/>">
						<m:classNames packages="org.hibernate.dialect" 
							interfaces="org.hibernate.dialect.Dialect" var="className">
							<c:set var="dialect" value="${fn:split(className,'.')[fn:length(fn:split(className,'.'))-1]}"/>
							<option value="${className}" <c:if test="${status.value == 
								className}">selected="selected"</c:if>>
								<c:choose>
									<c:when test="${fn:endsWith(dialect, 'Dialect')}">
										${fn:substring(dialect, 0, fn:length(dialect) - 7)}
									</c:when>
									<c:otherwise>${dialect}</c:otherwise>
								</c:choose>
							</option>
						</m:classNames>
					</select> <br />
				</spring:bind>
				<fmt:message key="setup.db.hibernate.dialect.caption"/>
			</dd>
			
			
		</dl>
		
		<div>
			<input type="submit" name="_target1" value="<fmt:message key="back.displayName"/>"/>
			<input type="submit" name="_target3" value="<fmt:message key="continue.displayName"/>"/>
		</div>
	</form>

  </body>
</html>
