b2evolution PHP Cross Reference Blogging Systems

Source: /skins/_closeaccount.disp.php - 62 lines - 2253 bytes - Text - Print

Description: This is the template that displays the close account page.

   1  <?php
   2  /**

   3   * This is the template that displays the close account page.

   4   *

   5   * This file is not meant to be called directly.

   6   * It is meant to be called by an include in the main.page.php template.

   7   *

   8   * This file is part of the b2evolution/evocms project - {@link http://b2evolution.net/}.

   9   * See also {@link http://sourceforge.net/projects/evocms/}.

  10   *

  11   * @copyright (c)2003-2014 by Francois Planque - {@link http://fplanque.com/}.

  12   *

  13   * @license http://b2evolution.net/about/license.html GNU General Public License (GPL)

  14   *

  15   * @version $Id: $

  16   */
  17  if( !defined('EVO_MAIN_INIT') ) die( 'Please, do not access this page directly.' );
  18  
  19  global $secure_htsrv_url;
  20  
  21  global $Blog;
  22  
  23  $Form = new Form( $secure_htsrv_url.'login.php' );
  24  
  25  $Form->begin_form( 'inskin' );
  26  
  27  $Form->add_crumb( 'closeaccountform' );
  28  $Form->hidden( 'redirect_to', $Blog->gen_blogurl() );
  29  $Form->hidden( 'action', 'closeaccount');
  30  
  31  echo '<p>'.T_( 'We are sorry to see you leave.' ).'</p>'."\n";
  32  echo '<p>'.T_( 'We value your feedback. Please be so kind and tell us in a few words why you are leaving us. This will help us to improve the site for the future.' ).'</p>';
  33  
  34  $Form->textarea_input( 'account_close_reason', '', 6, NULL, array( 'cols' => 40, 'class' => 'large', 'maxlength' => 255 ) );
  35  echo '<div id="character_counter" class="section_requires_javascript">';
  36  echo '<div id="characters_left_block"></div>';
  37  ?>
  38      <script type="text/javascript">
  39          <?php echo 'var counter_text = "'.T_( '%s characters left' ).'";';?>
  40          jQuery("#characters_left_block").html( counter_text.replace( "%s", 255 ) );
  41          jQuery("#account_close_reason").bind( "keyup", function(event)
  42          {
  43              var char_left = 255 - this.value.length;
  44              if( char_left < 0 )
  45              {
  46                  char_left = 0;
  47              }
  48              jQuery("#characters_left_block").html( counter_text.replace( "%s", char_left ) );
  49          } );
  50      </script>
  51      <noscript>
  52          <?php echo T_( '255 characters max' ); ?>
  53      </noscript>
  54  <?php
  55  echo '</div>';
  56  
  57  $Form->buttons( array( array( 'submit', 'submit', T_('Close my account now'), 'SaveButton' ) ) );
  58  
  59  $Form->info( '', '<a href="'.url_add_param( $Blog->gen_blogurl(), 'disp=user' ).'">'.T_( 'I changed my mind, don\'t close my account.' ).'</a>' );
  60  
  61  $Form->end_form();
  62  ?>

title

Description

title

Description

title

Description

title

title

Body