| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 1 | <h1>Sign up for |
| 2 | <?php echo $SERVICE_NAME;?> |
| 3 | </h1> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 4 | |
| 5 | <form action="" method="POST"> |
| 6 | <!-- Username input --> |
| 7 | <div class="form-outline mb-3"> |
| 8 | <label class="form-label font-weight-bold" for="form3Example3">Username*</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 9 | <input pattern="[^\s]{<?php echo $VAL_USER->min_username.','.$VAL_USER->max_username;?>}" required |
| 10 | title="At least 5 not whitespace characters" name="username" type="text" id="form3Example0" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 11 | 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] | 12 | placeholder="johndoe" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 13 | value="<?php echo isset($_POST['username']) ? htmlspecialchars($_POST['username']) : '' ?>" /> |
| 14 | </div> |
| 15 | <!-- 2 column grid layout with text inputs for the first and last names --> |
| 16 | <div class="row mb-3"> |
| 17 | <div class="col"> |
| 18 | <div class="form-outline"> |
| 19 | <label class="form-label font-weight-bold" for="form3Example1">First name*</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 20 | <input pattern="[^\s]{<?php echo $VAL_USER->min_first_name.','.$VAL_USER->max_first_name;?>}" required |
| 21 | title="At least 3 not whitespace characters" name="name" type="text" id="form3Example1" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 22 | 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] | 23 | placeholder="John" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 24 | value="<?php echo isset($_POST['name']) ? htmlspecialchars($_POST['name']) : '' ?>" /> |
| 25 | </div> |
| 26 | </div> |
| 27 | <div class="col"> |
| 28 | <div class="form-outline"> |
| 29 | <label class="form-label font-weight-bold" for="form3Example2">Last name*</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 30 | <input pattern="[^\s]{<?php echo $VAL_USER->min_last_name.','.$VAL_USER->max_last_name;?>}" required |
| 31 | title="At least 3 not whitespace characters" name="last_name" type="text" id="form3Example2" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 32 | class="form-control <?php if(isset($error) && $error && !isset($_POST['last_name'])){echo 'border-danger';}?>" |
| 33 | placeholder="Doe" |
| 34 | value="<?php echo isset($_POST['last_name']) ? htmlspecialchars($_POST['last_name']) : '' ?>" /> |
| 35 | </div> |
| 36 | </div> |
| 37 | </div> |
| 38 | |
| 39 | <!-- Email input --> |
| 40 | <div class="form-outline mb-3"> |
| 41 | <label class="form-label font-weight-bold" for="form3Example3">Email address*</label> |
| 42 | <input required name="email" type="email" id="form3Example3" |
| 43 | class="form-control <?php if(isset($error) && $error && !isset($_POST['email'])){echo 'border-danger';}?>" |
| 44 | placeholder="myemail@example.com" |
| 45 | value="<?php echo isset($_POST['email']) ? htmlspecialchars($_POST['email']) : '' ?>" /> |
| 46 | </div> |
| 47 | |
| 48 | <!-- Password input --> |
| 49 | <div class="form-outline mb-3"> |
| 50 | <label class="form-label font-weight-bold" for="form3Example4">Password*</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 51 | <input pattern="[^\s]{<?php echo $VAL_USER->min_password.','.$VAL_USER->max_password;?>}" required |
| 52 | title="At least 8 not whitespace characters" name="password" type="password" id="form3Example4" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 53 | class="form-control <?php if(isset($error) && $error && !isset($_POST['password'])){echo 'border-danger';}?>" |
| 54 | placeholder="********" |
| 55 | value="<?php echo isset($_POST['password']) ? htmlspecialchars($_POST['password']) : '' ?>" /> |
| 56 | </div> |
| 57 | <!-- Password input --> |
| 58 | <div class="form-outline mb-3"> |
| 59 | <label class="form-label font-weight-bold" for="form3Example4">Confirm your Password*</label> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 60 | <input pattern="[^\s]{<?php echo $VAL_USER->min_password.','.$VAL_USER->max_password;?>}" required |
| 61 | title="At least 8 not whitespace characters" name="password_confirm" type="password" id="form3Example5" |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 62 | class="form-control <?php if(isset($error) && $error && !isset($_POST['password_confirm'])){echo 'border-danger';}?>" |
| 63 | placeholder="********" |
| 64 | value="<?php echo isset($_POST['password_confirm']) ? htmlspecialchars($_POST['password_confirm']) : '' ?>" /> |
| 65 | </div> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 66 | <hr class="mt-2 mb-3" /> |
| 67 | <div class="form-outline mb-3"> |
| 68 | <label class="form-label font-weight-bold" for="eula">End User License Agreement*</label> |
| 69 | <div class="form-group form-check"> |
| 70 | <input type="checkbox" class="form-check-input" id="eula" required |
| 71 | title="You need to agree to the EULA in order to proceed"> |
| 72 | <label class="form-check-label" for="eula">I have read and agree to to the |
| 73 | <?php echo $SERVICE_NAME; ?> <a |
| 74 | href="https://www2.ids-mannheim.de/cosmas2/projekt/register/license_agreement.html">End User License |
| 75 | Agreement</a> and will use |
| 76 | <?php echo $SERVICE_NAME; ?> only for academic and non-commercial purposes. |
| 77 | </label> |
| 78 | <div class="invalid-feedback"> |
| 79 | You need to agree to the EULA in order to proceed. |
| 80 | </div> |
| 81 | </div> |
| 82 | </div> |
| 83 | <hr class="mt-2 mb-3" /> |
| 84 | <div class="form-outline mb-3"> |
| 85 | <label class="form-label font-weight-bold" for="privacy_policy">Privacy Policy*</label> |
| 86 | <div class="form-group form-check"> |
| 87 | <input type="checkbox" class="form-check-input" name="privacy_policy" id="privacy_policy" required |
| 88 | title="You need to agree to the privacy policy in order to proceed"> |
| 89 | <label class="form-check-label" for="privacy_policy">I have read and agree |
| 90 | to to the |
| 91 | <?php echo $SERVICE_NAME; ?> <a |
| 92 | href="https://www2.ids-mannheim.de/cosmas2/web-app/datenschutz.html">Privacy Policy</a>. |
| 93 | </label> |
| 94 | <div class="invalid-feedback"> |
| 95 | You need to agree to the EULA in order to proceed. |
| 96 | </div> |
| 97 | </div> |
| 98 | </div> |
| 99 | |
| 100 | <hr class="mt-2 mb-3" /> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 101 | <!--captcha here--> |
| 102 | <div class="form-outline mb-3"> |
| 103 | |
| 104 | <label class="form-label font-weight-bold" for="form3Example4">Captcha:</label> |
| 105 | <div class="container mb-2 offset-md-2"> |
| 106 | <img id="captcha" src="<?php echo $BASE_URL.'/captcha.php?token='.$_SESSION['captcha_token']; ?>" /> |
| 107 | <div id="reload_captcha"> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 108 | <button id="reload" class="btn btn-outline-info" type="button"> <span |
| 109 | class="glyphicon glyphicon-refresh" aria-hidden="true"></span></button> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 110 | </div> |
| 111 | </div> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 112 | <input pattern="[^\s]{<?php echo $CAPTCHA_LENGTH; ?>,}" required |
| 113 | title="Please fill the captcha. It has 5 characters" name="captcha" type="text" id="form3Example6" |
| 114 | class="form-control" placeholder="Type what you see on the image above" /> |
| matheusfillipe | abd513e | 2021-05-11 03:29:11 -0300 | [diff] [blame] | 115 | </div> |
| 116 | |
| 117 | <!-- Submit button --> |
| 118 | <button name="type" value="register" type="submit" class="btn btn-primary float-right btn-md">Sign up</button> |
| 119 | |
| 120 | </form> |
| Marc Kupietz | 7743428 | 2023-02-24 12:04:47 +0100 | [diff] [blame^] | 121 | </div> |