<commit_before><%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
  <head>
    <title>Spring 2.0 form tag showcase application</title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <link rel="icon" href="<c:url value="/favicon.ico"/>" type="image/x-icon" />
    <link rel="shortcut icon" href="<c:url value="/favicon.ico"/>" type="image/x-icon" />
    <link href="<c:url value="/css/style.css"/>" rel="stylesheet" type="text/css"/>
  </head>

<body>
  <div id="main">

    <div id="topmenu">
      <a href="http://www.interface21.com">Interface21</a><a href="http://www.springframework.org">Spring home</a><a href="http://forum.springframework.org">Spring forum</a><a href="http://www.dzone.com">Dzone.com</a><a href="http://www.infoq.com">Infoq.com</a>
    </div>

    <div id="header">
      <span class="title">The Spring Framework <span class="darktitle">2.0</span> form tags</span><br/>
    </div>

    <div id="content">
       <h1>Edit apprentice magician <c:out value="${command.firstName}"/> <c:out value="${command.lastName}" /></h1>
       <form:form>
           <form:errors path="*" cssClass="errorBox" />

           <div class="first">
			   <form:label path="firstName">First Name:</form:label>
               <form:input path="firstName" />
               <form:errors path="firstName" cssClass="error" />
           </div>

           <div>
			   <form:label path="lastName">Last Name:</form:label>
               <form:input path="lastName" disabled="true" />
               <form:errors path="lastName" cssClass="error" />
           </div>

           <div>
			   <form:label path="country">Country:</form:label>
               <form:select path="country">
                   <form:option value="" label="--Please Select"/>
                   <form:options items="${countryList}" itemValue="code" itemLabel="name"/>
               </form:select>
               <form:errors path="country" cssClass="error"/>
           </div>

           <div>
			   <form:label path="skills">Skills:</form:label>
                <form:select path="skills" items="${skills}"/>
           </div>

           <div>
			   <form:label path="notes">Notes:</form:label>
               <form:textarea path="notes" rows="3" cols="20" />
               <form:errors path="notes" cssClass="error" />
           </div>

           <div>
			   <form:label path="sex">Sex:</form:label>
			   Male: <form:radiobutton path="sex" value="M"/>
			   Female: <form:radiobutton path="sex" value="F"/>
           </div>

           <div>
			   <form:label path="house">House:</form:label>
               <form:select path="house">
                   <form:option value="Gryffindor"/>
                   <form:option value="Hufflepuff"/>
                   <form:option value="Ravenclaw"/>
                   <form:option value="Slytherin"/>
               </form:select>
           </div>

           <div>
			   <form:label path="preferences.receiveNewsletter">Subscribe to newsletter?:</form:label>
               <form:checkbox path="preferences.receiveNewsletter"/>
           </div>

           <div>
			   <form:label path="preferences.interests">Interests:</form:label>
               <span>Quidditch:</span> <form:checkbox path="preferences.interests" value="Quidditch"/><br/>
               <span>Herbology:</span> <form:checkbox path="preferences.interests" value="Herbology"/><br/>
               <span>Defence Against the Dark Arts:</span> <form:checkbox path="preferences.interests" value="Defence Against the Dark Arts"/>
           </div>

           <div>
			   <form:label path="preferences.favouriteWord">Favourite Word:</form:label>
               <span>Magic:</span> <form:checkbox path="preferences.favouriteWord" value="Magic"/>
           </div>

           <div><commit_msg>Added an example of using the disabled="true" attribute to disable a single option tag.<commit_after><%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
  <head>
    <title>Spring 2.0 form tag showcase application</title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8"/>
    <link rel="icon" href="<c:url value="/favicon.ico"/>" type="image/x-icon" />
    <link rel="shortcut icon" href="<c:url value="/favicon.ico"/>" type="image/x-icon" />
    <link href="<c:url value="/css/style.css"/>" rel="stylesheet" type="text/css"/>
  </head>

<body>
  <div id="main">

    <div id="topmenu">
      <a href="http://www.interface21.com">Interface21</a><a href="http://www.springframework.org">Spring home</a><a href="http://forum.springframework.org">Spring forum</a><a href="http://www.dzone.com">Dzone.com</a><a href="http://www.infoq.com">Infoq.com</a>
    </div>

    <div id="header">
      <span class="title">The Spring Framework <span class="darktitle">2.0</span> form tags</span><br/>
    </div>

    <div id="content">
       <h1>Edit apprentice magician <c:out value="${command.firstName}"/> <c:out value="${command.lastName}" /></h1>
       <form:form>
           <form:errors path="*" cssClass="errorBox" />

           <div class="first">
			   <form:label path="firstName">First Name:</form:label>
               <form:input path="firstName" />
               <form:errors path="firstName" cssClass="error" />
           </div>

           <div>
			   <form:label path="lastName">Last Name:</form:label>
               <form:input path="lastName" disabled="true" />
               <form:errors path="lastName" cssClass="error" />
           </div>

           <div>
			   <form:label path="country">Country:</form:label>
               <form:select path="country">
                   <form:option value="" label="--Please Select"/>
                   <form:options items="${countryList}" itemValue="code" itemLabel="name"/>
               </form:select>
               <form:errors path="country" cssClass="error"/>
           </div>

           <div>
			   <form:label path="skills">Skills:</form:label>
                <form:select path="skills" items="${skills}"/>
           </div>

           <div>
			   <form:label path="notes">Notes:</form:label>
               <form:textarea path="notes" rows="3" cols="20" />
               <form:errors path="notes" cssClass="error" />
           </div>

           <div>
			   <form:label path="sex">Sex:</form:label>
			   Male: <form:radiobutton path="sex" value="M"/>
			   Female: <form:radiobutton path="sex" value="F"/>
           </div>

           <div>
			   <form:label path="house">House:</form:label>
               <form:select path="house">
                   <form:option value="Gryffindor"/>
                   <form:option value="Hufflepuff"/>
                   <form:option value="Ravenclaw" disabled="true"/>
                   <form:option value="Slytherin"/>
               </form:select>
           </div>

           <div>
			   <form:label path="preferences.receiveNewsletter">Subscribe to newsletter?:</form:label>
               <form:checkbox path="preferences.receiveNewsletter"/>
           </div>

           <div>
			   <form:label path="preferences.interests">Interests:</form:label>
               <span>Quidditch:</span> <form:checkbox path="preferences.interests" value="Quidditch"/><br/>
               <span>Herbology:</span> <form:checkbox path="preferences.interests" value="Herbology"/><br/>
               <span>Defence Against the Dark Arts:</span> <form:checkbox path="preferences.interests" value="Defence Against the Dark Arts"/>
           </div>

           <div>
			   <form:label path="preferences.favouriteWord">Favourite Word:</form:label>
               <span>Magic:</span> <form:checkbox path="preferences.favouriteWord" value="Magic"/>
           </div>

           <div>
{'fraction_non_alphanumeric': 0.19003947062920826, 'fraction_numerical': 0.00650104481077316, 'mean_word_length': 2.6167086481947943, 'pattern_counts': {'":': 0, '<': 247, '<?xml version=': 0, '>': 247, 'https://': 0, 'lorem ipsum': 0, 'www.': 16, 'xml': 4}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6075122', 'n_tokens_mistral': 2838, 'n_tokens_neox': 2615, 'n_words': 453}