| Marc Kupietz | e5073d4 | 2023-03-04 14:15:40 +0100 | [diff] [blame] | 1 | <div class="container ml-0 pl-0"> |
| 2 | <header class="d-flex flex-wrap py-340 mb-8 border-bottom"> |
| 3 | <div class="col-md-12 justify-content-start pb-5 float-start"> |
| 4 | <a href="/"> |
| 5 | <img class="" width="340" src="<?php echo $SERVICE_LOGO;?>" alt="<?php echo $SERVICE_NAME; ?>" /> |
| 6 | </a> |
| 7 | </div> |
| 8 | |
| 9 | <div class="col-md-12 bold navbar-expand-lg mt-5 ml-5 pl-5 bg-primary" data-bs-theme="dark"> |
| 10 | <ul class="nav nav-pills justify-content-start fs-4"> |
| 11 | <li class="nav-item"><a href="https://korpus.cz/icc" class="nav-link">Home</a></li> |
| 12 | <li class="nav-item"><a href="#" class="nav-link active" aria-current="page">Sign up</a></li> |
| 13 | <li class="nav-item"><a href="#" class="nav-link">Query</a></li> |
| 14 | </ul> |
| 15 | </div> |
| 16 | </header> |
| 17 | </div> |
| 18 | |
| Marc Kupietz | ad3ab5d | 2023-03-04 14:12:46 +0100 | [diff] [blame] | 19 | <h1>Sign up for |
| 20 | <?php echo $SERVICE_ACRONYM;?> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 21 | </h1> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 22 | |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 23 | <form class="row g-3 needs-validation" novalidate action="" method="POST"> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 24 | <!-- Username input --> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 25 | <div class="col-md-4"> |
| 26 | <label class="form-label font-weight-bold" for="form3Example3">Username</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 27 | <input pattern="[^\s]{<?php echo $VAL_USER->min_username.','.$VAL_USER->max_username;?>}" required |
| 28 | title="At least 5 not whitespace characters" name="username" type="text" id="form3Example0" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 29 | class="form-control <?php if(isset($error) && $error && !isset($_POST['username'])){echo 'border-danger';}?>" |
| Marc Kupietz | b527e64 | 2023-02-23 10:04:21 +0100 | [diff] [blame] | 30 | placeholder="johndoe" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 31 | value="<?php echo isset($_POST['username']) ? htmlspecialchars($_POST['username']) : '' ?>" /> |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 32 | <div class="invalid-feedback"> |
| 33 | Please choose a username with at least 5 not whitespace characters. |
| 34 | </div> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 35 | </div> |
| 36 | <!-- 2 column grid layout with text inputs for the first and last names --> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 37 | <div class="col-md-4"> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 38 | <div class="form-outline"> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 39 | <label class="form-label font-weight-bold" for="form3Example1">First name</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 40 | <input pattern="[^\s]{<?php echo $VAL_USER->min_first_name.','.$VAL_USER->max_first_name;?>}" required |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 41 | title="At least 2 not whitespace characters" name="name" type="text" id="form3Example1" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 42 | class="form-control <?php if(isset($error) && $error && !isset($_POST['name'])){echo 'border-danger';}?>" |
| Marc Kupietz | b527e64 | 2023-02-23 10:04:21 +0100 | [diff] [blame] | 43 | placeholder="John" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 44 | value="<?php echo isset($_POST['name']) ? htmlspecialchars($_POST['name']) : '' ?>" /> |
| Marc Kupietz | 3186188 | 2023-02-25 08:52:57 +0100 | [diff] [blame] | 45 | <div class="invalid-feedback"> |
| 46 | Please provide a first name with at least 2 characters. |
| 47 | </div> |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 48 | </div> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 49 | </div> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 50 | <div class="col-md-4"> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 51 | <div class="form-outline"> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 52 | <label class="form-label font-weight-bold" for="form3Example2">Last name</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 53 | <input pattern="[^\s]{<?php echo $VAL_USER->min_last_name.','.$VAL_USER->max_last_name;?>}" required |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 54 | title="At least 2 not whitespace characters" name="last_name" type="text" id="form3Example2" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 55 | class="form-control <?php if(isset($error) && $error && !isset($_POST['last_name'])){echo 'border-danger';}?>" |
| 56 | placeholder="Doe" |
| 57 | value="<?php echo isset($_POST['last_name']) ? htmlspecialchars($_POST['last_name']) : '' ?>" /> |
| Marc Kupietz | 3186188 | 2023-02-25 08:52:57 +0100 | [diff] [blame] | 58 | <div class="invalid-feedback"> |
| 59 | Please provide a last name with at least 2 characters. |
| 60 | </div> |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 61 | </div> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 62 | </div> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 63 | |
| 64 | <!-- Email input --> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 65 | <div class="form-outline md-6"> |
| 66 | <label class="form-label font-weight-bold" for="form3Example3">Email address</label> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 67 | <input required name="email" type="email" id="form3Example3" |
| 68 | class="form-control <?php if(isset($error) && $error && !isset($_POST['email'])){echo 'border-danger';}?>" |
| 69 | placeholder="myemail@example.com" |
| 70 | value="<?php echo isset($_POST['email']) ? htmlspecialchars($_POST['email']) : '' ?>" /> |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 71 | <div class="invalid-feedback"> |
| 72 | Please provide a valid email address. |
| 73 | </div> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 74 | </div> |
| 75 | |
| Marc Kupietz | a19f307 | 2023-02-25 14:16:40 +0100 | [diff] [blame] | 76 | <div class="form-outline md-6"> |
| 77 | <label class="form-label font-weight-bold" for="organization">Institution / Organization</label> |
| 78 | <input required name="organization" type="text" id="organization" |
| 79 | class="form-control <?php if(isset($error) && $error && !isset($_POST['organization'])){echo 'border-danger';}?>" |
| 80 | placeholder="Example University" |
| 81 | pattern=".{3,64}" |
| 82 | value="<?php echo isset($_POST['organization']) ? htmlspecialchars($_POST['organization']) : '' ?>" /> |
| 83 | <div class="invalid-feedback"> |
| 84 | Please indicate the institution or organization you are affiliated with. |
| 85 | </div> |
| 86 | </div> |
| 87 | |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 88 | <!-- Password input --> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 89 | <div id="password-div" class="col-md-8"> |
| 90 | <label class="form-label font-weight-bold" for="pw1">Password</label> |
| Marc Kupietz | 484ec8e | 2023-02-25 11:23:07 +0100 | [diff] [blame] | 91 | <input required |
| 92 | title="Combination of upper and lowercase letters, numbers, punctuation, and special symbols" name="password" type="password" id="pw1" |
| 93 | class="form-control" |
| Marc Kupietz | 3186188 | 2023-02-25 08:52:57 +0100 | [diff] [blame] | 94 | placeholder="********" oninput="check_password_match()" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 95 | value="<?php echo isset($_POST['password']) ? htmlspecialchars($_POST['password']) : '' ?>" /> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 96 | </div> |
| 97 | <div class="col-md-4"> |
| 98 | <label for="pwqinfo">Rating</label> |
| 99 | <input class="form-control" type="text" name="pwqinfo" id="pwqinfo" readonly> |
| 100 | </div> |
| 101 | <div class="col-md-12"> |
| Marc Kupietz | 21fa9bb | 2023-02-24 19:44:16 +0100 | [diff] [blame] | 102 | <div class="progress mt-2"> |
| 103 | <div class="progress-bar bg-danger" role="progressbar" id="pwqbar" aria-valuenow="0" aria-valuemin="0" |
| 104 | aria-valuemax="100"></div> |
| 105 | </div> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 106 | |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 107 | </div> |
| Marc Kupietz | 21fa9bb | 2023-02-24 19:44:16 +0100 | [diff] [blame] | 108 | <!-- |
| 109 | <div class="form-group"> |
| 110 | <label for="pwqinfo">Password rating</label> |
| 111 | <input class="form-control" type="text" name="pwqinfo" id="pwqinfo" readonly> |
| 112 | <div class="progress mt-2"> |
| 113 | <div class="progress-bar bg-danger" role="progressbar" id="pwqbar2" aria-valuenow="0" aria-valuemin="0" |
| 114 | aria-valuemax="100"></div> |
| 115 | </div> |
| 116 | </div> |
| 117 | --> |
| Marc Kupietz | 484ec8e | 2023-02-25 11:23:07 +0100 | [diff] [blame] | 118 | <!-- Password confirmation input --> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 119 | <div id="pwconfirm" class="form-outline col-md-8"> |
| 120 | <label class="form-label font-weight-bold" for="pw2">Confirm your Password</label> |
| Marc Kupietz | 484ec8e | 2023-02-25 11:23:07 +0100 | [diff] [blame] | 121 | <input required |
| 122 | name="password_confirm" type="password" id="pw2" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 123 | class="form-control <?php if(isset($error) && $error && !isset($_POST['password_confirm'])){echo 'border-danger';}?>" |
| Marc Kupietz | 5ad53e7 | 2023-02-25 14:49:49 +0100 | [diff] [blame] | 124 | placeholder="********" oninput="check_password_match()" |
| 125 | value="<?php echo isset($_POST['password_confirm']) ? htmlspecialchars($_POST['password_confirm']) : '' ?>" /> |
| Marc Kupietz | 3186188 | 2023-02-25 08:52:57 +0100 | [diff] [blame] | 126 | <div class="invalid-feedback"> |
| 127 | Passwords do not match. |
| 128 | </div> |
| 129 | </div> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 130 | <div class="form-outline mb-3"> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 131 | <label class="form-label font-weight-bold" for="eula">End User License Agreement</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 132 | <div class="form-group form-check"> |
| Marc Kupietz | 5ad53e7 | 2023-02-25 14:49:49 +0100 | [diff] [blame] | 133 | <input type="checkbox" class="form-check-input" name="eula" id="eula" required |
| 134 | title="You need to agree to the EULA in order to proceed" |
| 135 | <?php echo isset($_POST['eula']) ? 'checked' : '' ?> |
| 136 | value="eula"> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 137 | <label class="form-check-label" for="eula">I have read and agree to to the |
| Marc Kupietz | e5073d4 | 2023-03-04 14:15:40 +0100 | [diff] [blame] | 138 | <?php echo $SERVICE_ACRONYM; ?> <a |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 139 | href="https://www2.ids-mannheim.de/cosmas2/projekt/register/license_agreement.html">End User License |
| 140 | Agreement</a> and will use |
| Marc Kupietz | e5073d4 | 2023-03-04 14:15:40 +0100 | [diff] [blame] | 141 | <?php echo $SERVICE_ACRONYM; ?> only for academic and non-commercial purposes. |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 142 | </label> |
| 143 | <div class="invalid-feedback"> |
| 144 | You need to agree to the EULA in order to proceed. |
| 145 | </div> |
| 146 | </div> |
| 147 | </div> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 148 | <div class="form-outline mb-3"> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 149 | <label class="form-label font-weight-bold" for="privacy_policy">Privacy Policy</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 150 | <div class="form-group form-check"> |
| 151 | <input type="checkbox" class="form-check-input" name="privacy_policy" id="privacy_policy" required |
| Marc Kupietz | 5ad53e7 | 2023-02-25 14:49:49 +0100 | [diff] [blame] | 152 | title="You need to agree to the privacy policy in order to proceed" |
| 153 | <?php echo isset($_POST['privacy_policy']) ? 'checked' : '' ?> |
| 154 | value="privacy_policy"> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 155 | <label class="form-check-label" for="privacy_policy">I have read and agree |
| 156 | to to the |
| Marc Kupietz | e5073d4 | 2023-03-04 14:15:40 +0100 | [diff] [blame] | 157 | <?php echo $SERVICE_ACRONYM; ?> <a |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 158 | href="https://www2.ids-mannheim.de/cosmas2/web-app/datenschutz.html">Privacy Policy</a>. |
| 159 | </label> |
| 160 | <div class="invalid-feedback"> |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 161 | You need to agree to the privacy policy in order to proceed. |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 162 | </div> |
| 163 | </div> |
| 164 | </div> |
| Marc Kupietz | d2dfa00 | 2023-03-04 14:59:16 +0100 | [diff] [blame] | 165 | |
| 166 | <?php if($CAPTCHA_LENGTH > 0): ?> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 167 | <!--captcha here--> |
| 168 | <div class="form-outline mb-3"> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 169 | <label class="form-label font-weight-bold" for="form3Example4">Captcha</label> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 170 | <div class="container mb-2 offset-md-2"> |
| 171 | <img id="captcha" src="<?php echo $BASE_URL.'/captcha.php?token='.$_SESSION['captcha_token']; ?>" /> |
| 172 | <div id="reload_captcha"> |
| Marc Kupietz | 675b565 | 2023-02-25 13:09:47 +0100 | [diff] [blame] | 173 | <button id="reload" class="btn btn-outline-info" type="button"> <span class="glyphicon glyphicon-refresh" |
| 174 | aria-hidden="true"></span></button> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 175 | </div> |
| 176 | </div> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 177 | <input pattern="[^\s]{<?php echo $CAPTCHA_LENGTH; ?>,}" required |
| Marc Kupietz | 0375b7e | 2023-03-04 18:13:26 +0100 | [diff] [blame^] | 178 | title="Please fill the captcha. It has <?php echo $CAPTCHA_LENGTH; ?> characters" name="captcha" type="text" id="form3Example6" |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame] | 179 | class="form-control" placeholder="Type what you see on the image above" /> |
| Marc Kupietz | 5ad53e7 | 2023-02-25 14:49:49 +0100 | [diff] [blame] | 180 | <div class="invalid-feedback"> |
| 181 | Type what you see on the image above. |
| 182 | </div> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 183 | </div> |
| Marc Kupietz | d2dfa00 | 2023-03-04 14:59:16 +0100 | [diff] [blame] | 184 | <?php endif; ?> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 185 | |
| 186 | <!-- Submit button --> |
| Marc Kupietz | e5073d4 | 2023-03-04 14:15:40 +0100 | [diff] [blame] | 187 | <div class="container mt-2 text-right"> |
| 188 | <button name="type" value="register" type="submit" class="btn btn-primary font-weight-bold fs-4">Sign up</button> |
| 189 | </div> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 190 | |
| 191 | </form> |
| Marc Kupietz | 1f2b2e9 | 2023-02-24 13:04:40 +0100 | [diff] [blame] | 192 | </div> |