Changeset 6834
- Timestamp:
- 07/05/2018 06:03:38 PM (8 years ago)
- Location:
- trunk/src
- Files:
-
- 4 edited
-
bbpress.php (modified) (1 diff)
-
includes/admin/assets/css/admin.css (modified) (4 diffs)
-
includes/admin/assets/js/converter.js (modified) (3 diffs)
-
includes/admin/settings.php (modified) (23 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bbpress.php
r6817 r6834 204 204 /** Versions **********************************************************/ 205 205 206 $this->version = '2.6-rc-68 10';206 $this->version = '2.6-rc-6831'; 207 207 $this->db_version = '262'; 208 208 -
trunk/src/includes/admin/assets/css/admin.css
r6817 r6834 436 436 /* Converter */ 437 437 438 .bbp-converter-settings-wrap { 439 float: left; 440 width: 55%; 441 } 442 443 #poststuff.bbp-converter-monitor-wrap { 444 float: right; 445 width: 43%; 446 margin-left: 2%; 447 min-width: 200px; 448 } 449 438 450 #bbp-converter-monitor h2 { 439 451 position: relative; … … 442 454 #bbp-converter-monitor .inside { 443 455 margin-bottom: 0; 456 border-bottom: 1px solid #e5e5e5; 457 } 458 459 #bbp-converter-monitor div.actions { 460 padding: 10px; 461 background: #fafafa; 462 clear: both; 463 } 464 465 #bbp-converter-spinner { 466 margin: 4px 0; 444 467 } 445 468 … … 541 564 button.bbp-db-pass-toggle { 542 565 border: none; 543 background: #fff;566 background: transparent; 544 567 position: absolute; 545 568 right: 3px; … … 572 595 } 573 596 597 #poststuff.bbp-converter-monitor-wrap, 598 .bbp-converter-settings-wrap { 599 float: none; 600 width: 100%; 601 margin: 20px 0; 602 } 603 574 604 button.bbp-db-pass-toggle { 575 605 height: 35px; -
trunk/src/includes/admin/assets/js/converter.js
r6690 r6834 10 10 restart = $( '#_bbp_converter_restart' ), 11 11 status = $( '#bbp-converter-status' ), 12 spinner = $( '#bbp-converter-spinner' ), 12 13 settings = $( '#bbp-converter-settings' ), 13 14 password = $( '#_bbp_converter_db_pass' ), 14 15 toggle = $( '.bbp-db-pass-toggle' ), 15 16 step_p = $( '#bbp-converter-step-percentage' ), 16 total_p = $( '#bbp-converter-total-percentage' ); 17 total_p = $( '#bbp-converter-total-percentage' ), 18 fields = settings.find( 'table:first-of-type input, table:first-of-type select' ); 17 19 18 20 /** … … 218 220 219 221 message.addClass( 'started' ); 222 220 223 start.hide(); 221 224 stop.show(); 225 console.log( fields ); 226 spinner.css( 'visibility', 'visible' ); 227 fields.prop( 'readonly', true ); 222 228 223 229 bbp_converter_post(); … … 257 263 start.show(); 258 264 stop.hide(); 265 266 spinner.css( 'visibility', 'hidden' ); 267 fields.prop( 'readonly', false ); 259 268 } 260 269 -
trunk/src/includes/admin/settings.php
r6780 r6834 493 493 'callback' => 'bbp_converter_setting_callback_platform', 494 494 'sanitize_callback' => 'sanitize_text_field', 495 'args' => array( )495 'args' => array( 'label_for'=> '_bbp_converter_platform' ) 496 496 ), 497 497 … … 501 501 'callback' => 'bbp_converter_setting_callback_dbserver', 502 502 'sanitize_callback' => 'sanitize_text_field', 503 'args' => array( )503 'args' => array( 'label_for'=> '_bbp_converter_db_server' ) 504 504 ), 505 505 … … 509 509 'callback' => 'bbp_converter_setting_callback_dbport', 510 510 'sanitize_callback' => 'intval', 511 'args' => array( )511 'args' => array( 'label_for'=> '_bbp_converter_db_port' ) 512 512 ), 513 513 … … 517 517 'callback' => 'bbp_converter_setting_callback_dbname', 518 518 'sanitize_callback' => 'sanitize_text_field', 519 'args' => array( )519 'args' => array( 'label_for'=> '_bbp_converter_db_name' ) 520 520 ), 521 521 … … 525 525 'callback' => 'bbp_converter_setting_callback_dbuser', 526 526 'sanitize_callback' => 'sanitize_text_field', 527 'args' => array( )527 'args' => array( 'label_for'=> '_bbp_converter_db_user' ) 528 528 ), 529 529 … … 533 533 'callback' => 'bbp_converter_setting_callback_dbpass', 534 534 'sanitize_callback' => 'sanitize_text_field', 535 'args' => array( )535 'args' => array( 'label_for'=> '_bbp_converter_db_pass' ) 536 536 ), 537 537 … … 541 541 'callback' => 'bbp_converter_setting_callback_dbprefix', 542 542 'sanitize_callback' => 'sanitize_text_field', 543 'args' => array( )543 'args' => array( 'label_for'=> '_bbp_converter_db_prefix' ) 544 544 ) 545 545 ), … … 553 553 'callback' => 'bbp_converter_setting_callback_rows', 554 554 'sanitize_callback' => 'intval', 555 'args' => array( )555 'args' => array( 'label_for'=> '_bbp_converter_rows' ) 556 556 ), 557 557 … … 561 561 'callback' => 'bbp_converter_setting_callback_delay_time', 562 562 'sanitize_callback' => 'intval', 563 'args' => array( )563 'args' => array( 'label_for'=> '_bbp_converter_delay_time' ) 564 564 ), 565 565 … … 569 569 'callback' => 'bbp_converter_setting_callback_convert_users', 570 570 'sanitize_callback' => 'intval', 571 'args' => array( )571 'args' => array( 'label_for'=> '_bbp_converter_convert_users' ) 572 572 ), 573 573 … … 577 577 'callback' => 'bbp_converter_setting_callback_halt', 578 578 'sanitize_callback' => 'intval', 579 'args' => array( )579 'args' => array( 'label_for'=> '_bbp_converter_halt' ) 580 580 ), 581 581 … … 585 585 'callback' => 'bbp_converter_setting_callback_restart', 586 586 'sanitize_callback' => 'intval', 587 'args' => array( )587 'args' => array( 'label_for'=> '_bbp_converter_restart' ) 588 588 ), 589 589 … … 593 593 'callback' => 'bbp_converter_setting_callback_clean', 594 594 'sanitize_callback' => 'intval', 595 'args' => array( )595 'args' => array( 'label_for'=> '_bbp_converter_clean' ) 596 596 ) 597 597 ) … … 1523 1523 ?> 1524 1524 1525 <p><?php _e( 'Information about your previous forums database so that they can be converted. <strong>Backup your database before proceeding.</strong>', 'bbpress' ); ?></p>1525 <p><?php _e( 'Information about the database for your previous forums so they can be converted.', 'bbpress' ); ?></p> 1526 1526 1527 1527 <?php … … 1546 1546 1547 1547 <select name="_bbp_converter_platform" id="_bbp_converter_platform"><?php echo $options ?></select> 1548 < label for="_bbp_converter_platform"><?php esc_html_e( 'is the previous forum software', 'bbpress' ); ?></label>1548 <p class="description"><?php esc_html_e( 'The previous forum software', 'bbpress' ); ?></p> 1549 1549 1550 1550 <?php … … 1560 1560 1561 1561 <input name="_bbp_converter_db_server" id="_bbp_converter_db_server" type="text" class="code" value="<?php bbp_form_option( '_bbp_converter_db_server', 'localhost' ); ?>" <?php bbp_maybe_admin_setting_disabled( '_bbp_converter_db_server' ); ?> /> 1562 < label for="_bbp_converter_db_server"><?php esc_html_e( 'Use default "localhost" if on the same server, otherwise IP or hostname', 'bbpress' ); ?></label>1562 <p class="description"><?php printf( esc_html__( 'Use default %s if same server, or IP or hostname', 'bbpress' ), '<code>localhost</code>' ); ?></p> 1563 1563 1564 1564 <?php … … 1574 1574 1575 1575 <input name="_bbp_converter_db_port" id="_bbp_converter_db_port" type="text" class="code" value="<?php bbp_form_option( '_bbp_converter_db_port', '3306' ); ?>" <?php bbp_maybe_admin_setting_disabled( '_bbp_converter_db_port' ); ?> /> 1576 < label for="_bbp_converter_db_port"><?php esc_html_e( 'Use default "3306" if unsure', 'bbpress' ); ?></label>1576 <p class="description"><?php printf( esc_html__( 'Use default %s if unsure', 'bbpress' ), '<code>3306</code>' ); ?></p> 1577 1577 1578 1578 <?php … … 1588 1588 1589 1589 <input name="_bbp_converter_db_user" id="_bbp_converter_db_user" type="text" class="code" value="<?php bbp_form_option( '_bbp_converter_db_user' ); ?>" <?php bbp_maybe_admin_setting_disabled( '_bbp_converter_db_user' ); ?> /> 1590 < label for="_bbp_converter_db_user"><?php esc_html_e( 'User to access the database', 'bbpress' ); ?></label>1590 <p class="description"><?php esc_html_e( 'User to access the database', 'bbpress' ); ?></p> 1591 1591 1592 1592 <?php … … 1608 1608 </button> 1609 1609 </span> 1610 < label for="_bbp_converter_db_pass"><?php esc_html_e( 'Password for the above database user', 'bbpress' ); ?></label>1610 <p class="description"><?php esc_html_e( 'Password for the above database user', 'bbpress' ); ?></p> 1611 1611 1612 1612 <?php … … 1622 1622 1623 1623 <input name="_bbp_converter_db_name" id="_bbp_converter_db_name" type="text" class="code" value="<?php bbp_form_option( '_bbp_converter_db_name' ); ?>" <?php bbp_maybe_admin_setting_disabled( '_bbp_converter_db_name' ); ?> /> 1624 < label for="_bbp_converter_db_name"><?php esc_html_e( 'Name of the database with your old forum data', 'bbpress' ); ?></label>1624 <p class="description"><?php esc_html_e( 'Name of the database with your old forum data', 'bbpress' ); ?></p> 1625 1625 1626 1626 <?php … … 1649 1649 1650 1650 <input name="_bbp_converter_db_prefix" id="_bbp_converter_db_prefix" type="text" class="code" value="<?php bbp_form_option( '_bbp_converter_db_prefix' ); ?>" <?php bbp_maybe_admin_setting_disabled( '_bbp_converter_db_prefix' ); ?> /> 1651 < label for="_bbp_converter_db_prefix"><?php esc_html_e( '(If converting from BuddyPress Forums, use "wp_bb_" or your custom prefix)', 'bbpress' ); ?></label>1651 <p class="description"><?php printf( esc_html__( 'Use %s if converting from BuddyPress Legacy', 'bbpress' ), '<code>wp_bb_</code>' ); ?></p> 1652 1652 1653 1653 <?php … … 1778 1778 <h2 class="nav-tab-wrapper"><?php bbp_tools_admin_tabs( esc_html__( 'Import Forums', 'bbpress' ) ); ?></h2> 1779 1779 1780 <form action="#" method="post" id="bbp-converter-settings"><?php 1781 1782 // Fields 1783 settings_fields( 'converter' ); 1784 1785 // Sections 1786 do_settings_sections( 'converter' ); 1787 1788 ?> 1789 1790 <p class="submit"> 1791 <input type="button" name="submit" class="button-primary" id="bbp-converter-start" value="<?php echo esc_attr( $start_text ); ?>" /> 1792 <input type="button" name="submit" class="button-primary" id="bbp-converter-stop" value="<?php esc_attr_e( 'Pause', 'bbpress' ); ?>" /> 1793 </p> 1794 </form> 1795 1796 <div id="poststuff"> 1797 <div id="post-body" class="metabox-holder columns-1"> 1798 <div id="postbox-container-1" class="postbox-container"> 1799 <div id="normal-sortables" class="meta-box-sortables ui-sortable"> 1800 <div id="bbp-converter-monitor" class="postbox"> 1801 <button type="button" class="handlediv" aria-expanded="true"> 1802 <span class="screen-reader-text"><?php esc_html_e( 'Toggle panel: Import Status', 'bbpress' ); ?></span> 1803 <span class="toggle-indicator" aria-hidden="true"></span> 1804 </button> 1805 <h2 class="hndle ui-sortable-handle"> 1806 <span><?php esc_html_e( 'Import Monitor', 'bbpress' ); ?></span> 1807 <span id="bbp-converter-status"><?php echo esc_html( $status_text ); ?></span> 1808 <span id="bbp-converter-step-percentage" class="bbp-progress-bar"></span> 1809 <span id="bbp-converter-total-percentage" class="bbp-progress-bar"></span> 1810 </h2> 1811 <div class="inside"> 1812 <div id="bbp-converter-message" class="bbp-converter-log"> 1813 <p><?php echo esc_html( $progress_text ); ?></p> 1780 <div class="bbp-converter-wrap"> 1781 <div id="poststuff" class="bbp-converter-monitor-wrap"> 1782 <div id="post-body" class="metabox-holder columns-1"> 1783 <div id="postbox-container-1" class="postbox-container"> 1784 <div id="normal-sortables" class="meta-box-sortables ui-sortable"> 1785 <div id="bbp-converter-monitor" class="postbox"> 1786 <button type="button" class="handlediv" aria-expanded="true"> 1787 <span class="screen-reader-text"><?php esc_html_e( 'Toggle panel: Import Status', 'bbpress' ); ?></span> 1788 <span class="toggle-indicator" aria-hidden="true"></span> 1789 </button> 1790 <h2 class="hndle ui-sortable-handle"> 1791 <span><?php esc_html_e( 'Import Monitor', 'bbpress' ); ?></span> 1792 <span id="bbp-converter-status"><?php echo esc_html( $status_text ); ?></span> 1793 <span id="bbp-converter-step-percentage" class="bbp-progress-bar"></span> 1794 <span id="bbp-converter-total-percentage" class="bbp-progress-bar"></span> 1795 </h2> 1796 <div class="inside"> 1797 <div id="bbp-converter-message" class="bbp-converter-log"> 1798 <p><?php echo esc_html( $progress_text ); ?></p> 1799 </div> 1800 </div> 1801 <div class="actions"> 1802 <input type="button" name="submit" class="button-primary" id="bbp-converter-start" value="<?php echo esc_attr( $start_text ); ?>" /> 1803 <input type="button" name="submit" class="button-primary" id="bbp-converter-stop" value="<?php esc_attr_e( 'Pause', 'bbpress' ); ?>" /> 1804 <span class="spinner" id="bbp-converter-spinner"></span> 1814 1805 </div> 1815 1806 </div> … … 1818 1809 </div> 1819 1810 </div> 1811 1812 <form action="#" method="post" id="bbp-converter-settings" class="bbp-converter-settings-wrap"><?php 1813 1814 // Fields 1815 settings_fields( 'converter' ); 1816 1817 // Sections 1818 do_settings_sections( 'converter' ); 1819 1820 ?></form> 1820 1821 </div> 1821 1822 </div>
Note: See TracChangeset
for help on using the changeset viewer.