Example #1
0
    static function renderContactForm()
    {
        $mandatory_label = ' <span style="color: rgb(185,2,0); font-weight: bold;">*</span>';
        $rtn = Message::renderMessages() . '
<form role="form" action="" method="post" id="contact">
  <fieldset>
    <div class="form-group form-field-name">
      <label for="name">' . i18n(array('en' => 'Your name', 'zh' => '您的姓名')) . $mandatory_label . '</label>
      <input class="form-control" name="contact[name]" id="name" autofocus required="">
    </div>
    <div class="form-group form-field-email">
      <label for="email">' . i18n(array('en' => 'E-mail', 'zh' => '电子邮箱')) . $mandatory_label . '</label>
      <input class="form-control" type="email" name="contact[email]" id="email" required="">
    </div>
    <div class="form-group form-field-message">
      <label for="message">' . i18n(array('en' => 'Message', 'zh' => '留言')) . $mandatory_label . '</label>
      <textarea id="message" name="contact[message]" rows="5" class="form-control" required=""></textarea>
    </div>
    <div class="form-group" id="form-field-notice"><small><i>
      ' . $mandatory_label . i18n(array('en' => ' indicates mandatory fields', 'zh' => ' 标记为必填项')) . '
    </i></small></div>
    <input type="submit" name="submit" class="btn btn-success btn-block disabled" value="' . i18n(array('en' => 'Submit', 'zh' => '提交')) . '" />
    ' . Form::loadSpamToken('#contact', 'global contact form') . '
  </fieldset>
</form>
';
        return $rtn;
    }
Example #2
0
    static function renderForgetPasswordForm()
    {
        $rtn = Message::renderMessages() . '
<form role="form" action="" method="post" id="forget_password">
  <fieldset>
    <div class="form-group">
      <label for="email">' . i18n(array('en' => 'Your E-mail address', 'zh' => '您的电子箱地址')) . '</label>
      <input class="form-control" name="email" type="email" id="email" autofocus required="">
    </div>
    <input type="submit" name="submit" class="btn btn-primary btn-block ' . (module_enabled('form') ? 'disabled' : '') . '" value="' . i18n(array('en' => 'Confirm', 'zh' => '确认')) . '" />
    ' . (module_enabled('form') ? Form::loadSpamToken('#forget_password', SITEUSER_FORM_SPAM_TOKEN) : '') . '
    <div style="text-align:center;"><br /><small><a href="' . uri('users') . '">返回登录界面</a></small></div>
  </fieldset>
</form>
';
        return $rtn;
    }
Example #3
0
    </div>
    <div class="checkbox">
      <label>
        <input name="remember" type="checkbox" value="Remeber me" <?php 
if (isset($_POST['remember'])) {
    ?>
checked="checked"<?php 
}
?>
><?php 
i18n_echo(array('en' => 'Remember Me', 'zh' => '下次自动登录'));
?>
      </label>
    </div>
    <!-- Change this to a button or input when using this as a form -->
    <input type="submit" name="submit" class="btn btn-success btn-block disabled" value="<?php 
i18n_echo(array('en' => 'Login', 'zh' => '登录'));
?>
" />
    <?php 
if (module_enabled('form')) {
    ?>
      <?php 
    Form::loadSpamToken('#login', UID_BACKEND_LOGIN_FORM);
    ?>
    <?php 
}
?>
  </fieldset>
</form>
Example #4
0
    static function renderPasswordResetForm()
    {
        $rtn = Message::renderMessages() . '
<form role="form" action="" method="post" id="forget_password_reset">
  <fieldset>
    <div class="form-group form-field-password">
      <label for="password">' . i18n(array('en' => 'Your new password', 'zh' => '您的新密码')) . '</label>
      <input class="form-control" name="password" type="password" id="password" autofocus required="">
    </div>
    <div class="form-group form-field-password-confirm">
      <label for="password_confirm">' . i18n(array('en' => 'Confirm your password', 'zh' => '确认密码')) . '</label>
      <input class="form-control" name="password_confirm" type="password" id="password_confirm" required="">
    </div>
    <input type="submit" name="submit" class="btn btn-primary btn-block ' . (module_enabled('form') ? 'disabled' : '') . '" value="' . i18n(array('en' => 'Update password', 'zh' => '更新密码')) . '" />
    ' . (module_enabled('form') ? Form::loadSpamToken('#forget_password_reset', SITEUSER_FORM_SPAM_TOKEN) : '') . '
  </fieldset>
</form>
';
        return $rtn;
    }
Example #5
0
            <form id="contact" action="<?php 
echo uri('contact');
?>
" method="post" class="wpcf7-form" novalidate="novalidate">
              <p class="field-one-half">
                <label>Name <span class="required">*</span></label><span class="wpcf7-form-control-wrap your-name"><input type="text" name="contact[name]" value="" size="40" required="required" class="wpcf7-form-control wpcf7-text wpcf7-validates-as-required" aria-required="true" aria-invalid="false" /></span>
              </p>
              <p class="field-one-half">
                <label>Email <span class="required">*</span></label><span class="wpcf7-form-control-wrap your-email"><input type="email" required="required" name="contact[email]" value="" size="40" class="wpcf7-form-control wpcf7-text wpcf7-email wpcf7-validates-as-required wpcf7-validates-as-email" aria-required="true" aria-invalid="false" /></span>
              </p>
              <div class="clear"></div>
              <p class="field-full-width">
                <label>Message <span class="required">*</span></label><span class="wpcf7-form-control-wrap your-message"><textarea required="required" name="contact[message]" cols="40" rows="8" class="wpcf7-form-control wpcf7-textarea wpcf7-validates-as-required" aria-required="true" aria-invalid="false"></textarea></span>
              </p>
              <p><input name="submit" type="submit" value="Submit" class="wpcf7-form-control wpcf7-submit button" /></p>
              <div class="wpcf7-response-output wpcf7-display-none"></div>
              <?php 
Form::loadSpamToken('#contact', 'global contact form');
?>
            </form>
          </div>
        </div>
        <?php 
echo $full_page_sidebar_right;
?>
        <div class="clear"></div>
      </div>
    </article>

  </div>
</section>