Completed
Branch master (6d8b39)
by
unknown
08:42
created
admin-page-framework/help/AdminPageFrameworkLoader_AdminPage_Help_Tip.php 2 patches
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -25,14 +25,14 @@  discard block
 block discarded – undo
25 25
             
26 26
         $_aItems     = $this->getContentsByHeader( $this->getReadmeContents(), 4 );
27 27
         $_iLastIndex = count( $_aItems ) - 1;
28
-        foreach( $_aItems as $_iIndex => $_aContent ) {
28
+        foreach ( $_aItems as $_iIndex => $_aContent ) {
29 29
 
30 30
             $_oParser   = new AdminPageFramework_WPReadmeParser( $_aContent[ 1 ] );
31 31
             $_sContent  = $_oParser->get();
32 32
             $oAdminPage->addSettingSections(    
33 33
                 $this->sPageSlug, // the target page slug  
34 34
                 array(
35
-                    'section_id'        => 'tips_' . $_iIndex,
35
+                    'section_id'        => 'tips_'.$_iIndex,
36 36
                     'title'             => $_aContent[ 0 ],
37 37
                     'collapsible'       => array(
38 38
                         'toggle_all_button' => $_iLastIndex === $_iIndex 
@@ -53,9 +53,9 @@  discard block
 block discarded – undo
53 53
         /**
54 54
          * @return      string
55 55
          */
56
-        private function getReadMeContents()  {       
56
+        private function getReadMeContents() {       
57 57
             return $this->_getReadmeContents( 
58
-                AdminPageFrameworkLoader_Registry::$sDirPath . '/readme.txt', // source path
58
+                AdminPageFrameworkLoader_Registry::$sDirPath.'/readme.txt', // source path
59 59
                 '', // TOC title
60 60
                 array( 'Other Notes' )  // sections
61 61
             );
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@
 block discarded – undo
53 53
         /**
54 54
          * @return      string
55 55
          */
56
-        private function getReadMeContents()  {       
56
+        private function getReadMeContents() {
57 57
             return $this->_getReadmeContents( 
58 58
                 AdminPageFrameworkLoader_Registry::$sDirPath . '/readme.txt', // source path
59 59
                 '', // TOC title
Please login to merge, or discard this patch.
include/class/admin/demo/AdminPageFrameworkLoader_Demo.php 2 patches
Indentation   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -9,12 +9,12 @@
 block discarded – undo
9 9
  * @since        3.5.0
10 10
  */
11 11
 
12
- /**
13
-  * 
14
-  * 
15
-  * @action     do      admin_page_framework_loader_action_before_loading_demo
16
-  * @action     do      admin_page_framework_loader_action_after_loading_demo
17
-  */
12
+    /**
13
+     * 
14
+     * 
15
+     * @action     do      admin_page_framework_loader_action_before_loading_demo
16
+     * @action     do      admin_page_framework_loader_action_after_loading_demo
17
+     */
18 18
 class AdminPageFrameworkLoader_Demo {
19 19
     
20 20
     public function __construct() {
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -19,14 +19,14 @@  discard block
 block discarded – undo
19 19
     
20 20
     public function __construct() {
21 21
         
22
-        if ( ! $this->_shouldLoadDemo() ) {
22
+        if ( !$this->_shouldLoadDemo() ) {
23 23
             return;
24 24
         }
25 25
         
26 26
         do_action( 'admin_page_framework_loader_action_before_loading_demo' );
27 27
         
28 28
         // Include example components.
29
-        include( AdminPageFrameworkLoader_Registry::$sDirPath . '/example/admin-page-framework-demo-bootstrap.php' );
29
+        include( AdminPageFrameworkLoader_Registry::$sDirPath.'/example/admin-page-framework-demo-bootstrap.php' );
30 30
         
31 31
         do_action( 'admin_page_framework_loader_action_after_loading_demo' );
32 32
         
@@ -43,10 +43,10 @@  discard block
 block discarded – undo
43 43
         
44 44
             // Check if the demo is enabled.
45 45
             $_oOption = AdminPageFrameworkLoader_Option::getInstance();
46
-            if ( ! $_oOption->get( 'enable_admin_pages' ) ) {
46
+            if ( !$_oOption->get( 'enable_admin_pages' ) ) {
47 47
                 return false;
48 48
             }            
49
-            if ( ! $_oOption->get( 'enable_demo' ) ) {
49
+            if ( !$_oOption->get( 'enable_demo' ) ) {
50 50
                 $this->_setPointerToolTips();
51 51
                 return false;
52 52
             }           
@@ -74,7 +74,7 @@  discard block
 block discarded – undo
74 74
                 'options'   => array(
75 75
                     'content' => sprintf( '<h3> %1$s </h3> <p> %2$s </p>',
76 76
                         AdminPageFrameworkLoader_Registry::NAME,
77
-                        __( 'Check out the functionality of Admin Page Framework by enabling the demo.','admin-page-framework-loader' )
77
+                        __( 'Check out the functionality of Admin Page Framework by enabling the demo.', 'admin-page-framework-loader' )
78 78
                     ),
79 79
                     'position'  => array( 'edge' => 'left', 'align' => 'middle' )
80 80
                 )
Please login to merge, or discard this patch.
factory/_common/_abstract/_controller/AdminPageFramework_Resource_Base.php 3 patches
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -232,6 +232,8 @@  discard block
 block discarded – undo
232 232
      * @remark      The meta box class may be instantiated multiple times so prevent echoing the same styles multiple times.
233 233
      * @parameter   string      $sIDPrefix   The id selector embedded in the script tag.
234 234
      * @parameter   string      $sClassName  The class name that identify the call group. This is important for the meta-box class because it can be instantiated multiple times in one particular page.
235
+     * @param string $sIDPrefix
236
+     * @param string $sClassName
235 237
      */
236 238
     protected function _printCommonStyles( $sIDPrefix, $sClassName ) {
237 239
 
@@ -315,6 +317,8 @@  discard block
 block discarded – undo
315 317
      * @remark      The meta box class may be instantiated multiple times so prevent echoing the same styles multiple times.
316 318
      * @parametr    string      $sIDPrefix      The id selector embedded in the script tag.
317 319
      * @parametr    string      $sClassName     The class name that identify the call group. This is important for the meta-box class because it can be instantiated multiple times in one particular page.
320
+     * @param string $sIDPrefix
321
+     * @param string $sClassName
318 322
      */
319 323
     protected function _printCommonScripts( $sIDPrefix, $sClassName ) {
320 324
         
Please login to merge, or discard this patch.
Spacing   +43 added lines, -43 removed lines patch added patch discarded remove patch
@@ -37,19 +37,19 @@  discard block
 block discarded – undo
37 37
     
38 38
         /* The system internal keys. */
39 39
         'sSRC'          => null,
40
-        'aPostTypes'    => array(),     // for meta box class
40
+        'aPostTypes'    => array(), // for meta box class
41 41
         'sPageSlug'     => null,    
42 42
         'sTabSlug'      => null,
43
-        'sType'         => null,        // script or style
43
+        'sType'         => null, // script or style
44 44
         
45 45
         /* The below keys are for users. */
46 46
         'handle_id'     => null,
47 47
         'dependencies'  => array(),
48
-        'version'       => false,       // although the type should be string, the wp_enqueue_...() functions want false as the default value.
49
-        'translation'   => array(),     // only for scripts
50
-        'in_footer'     => false,       // only for scripts
51
-        'media'         => 'all',       // only for styles     
52
-        'attributes'    => array(),     // 3.3.0+ - the attribute array
48
+        'version'       => false, // although the type should be string, the wp_enqueue_...() functions want false as the default value.
49
+        'translation'   => array(), // only for scripts
50
+        'in_footer'     => false, // only for scripts
51
+        'media'         => 'all', // only for styles     
52
+        'attributes'    => array(), // 3.3.0+ - the attribute array
53 53
         
54 54
     );    
55 55
       
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
      * @remark      This value should be overridden in an extended class.
61 61
      * @internal
62 62
      */
63
-    protected $_sClassSelector_Style    = 'admin-page-framework-style';
63
+    protected $_sClassSelector_Style = 'admin-page-framework-style';
64 64
     
65 65
     /**
66 66
      * Stores the class selector used to the class-specific script.
@@ -69,7 +69,7 @@  discard block
 block discarded – undo
69 69
      * @remark      This value should be overridden in an extended class.
70 70
      * @internal
71 71
      */    
72
-    protected $_sClassSelector_Script   = 'admin-page-framework-script';
72
+    protected $_sClassSelector_Script = 'admin-page-framework-script';
73 73
       
74 74
     /**
75 75
      * Stores hand IDs by resource url to look up handle id and add custom arguments.
@@ -143,8 +143,8 @@  discard block
 block discarded – undo
143 143
      * @internal
144 144
      */
145 145
     
146
-    public function _forceToEnqueueStyle( $sSRC, $aCustomArgs=array() ) {}
147
-    public function _forceToEnqueueScript( $sSRC, $aCustomArgs=array() ) {}
146
+    public function _forceToEnqueueStyle( $sSRC, $aCustomArgs = array() ) {}
147
+    public function _forceToEnqueueScript( $sSRC, $aCustomArgs = array() ) {}
148 148
     
149 149
     /**
150 150
      * A helper function for the _replyToEnqueueScripts() and the `_replyToEnqueueStyle()` methods.
@@ -205,7 +205,7 @@  discard block
 block discarded – undo
205 205
                     }
206 206
                     
207 207
                     $_sAttributes   = $this->getAttributes( $_aAttributes );
208
-                    $_sModifiedURL  = $sSanitizedURL . "' " . rtrim( $_sAttributes, "'\"" );    // '"
208
+                    $_sModifiedURL  = $sSanitizedURL."' ".rtrim( $_sAttributes, "'\"" ); // '"
209 209
 
210 210
                     return $_sModifiedURL;                    
211 211
                     
@@ -253,10 +253,10 @@  discard block
 block discarded – undo
253 253
          */
254 254
         private function _getStyleTag( $oCaller, $sIDPrefix ) {
255 255
             
256
-            $_sStyle     = $this->addAndApplyFilters( 
256
+            $_sStyle = $this->addAndApplyFilters( 
257 257
                 $oCaller, 
258 258
                 array(
259
-                    "style_common_admin_page_framework",            // 3.2.1+
259
+                    "style_common_admin_page_framework", // 3.2.1+
260 260
                     "style_common_{$this->oProp->sClassName}",
261 261
                 ), 
262 262
                 AdminPageFramework_CSS::getDefaultCSS() 
@@ -269,7 +269,7 @@  discard block
 block discarded – undo
269 269
                 // : $this->getCSSMinified( $_sStyle );
270 270
                 
271 271
             if ( $_sStyle ) {
272
-                echo "<style type='text/css' id='" . esc_attr( $sIDPrefix ) . "'>"
272
+                echo "<style type='text/css' id='".esc_attr( $sIDPrefix )."'>"
273 273
                         . $_sStyle
274 274
                     . "</style>";
275 275
             }
@@ -283,10 +283,10 @@  discard block
 block discarded – undo
283 283
          */        
284 284
         private function _getIEStyleTag( $oCaller, $sIDPrefix ) {
285 285
                 
286
-            $_sStyleIE   = $this->addAndApplyFilters( 
286
+            $_sStyleIE = $this->addAndApplyFilters( 
287 287
                 $oCaller, 
288 288
                 array(
289
-                    "style_ie_common_admin_page_framework",         // 3.2.1+
289
+                    "style_ie_common_admin_page_framework", // 3.2.1+
290 290
                     "style_ie_common_{$this->oProp->sClassName}", 
291 291
                 ),
292 292
                 AdminPageFramework_CSS::getDefaultCSSIE() 
@@ -297,7 +297,7 @@  discard block
 block discarded – undo
297 297
                 // ? trim( $_sStyleIE )
298 298
                 // : $this->getCSSMinified( $_sStyleIE );
299 299
             return $_sStyleIE
300
-                ? "<!--[if IE]><style type='text/css' id='" . esc_attr( $sIDPrefix . "-ie" ) . "'>"
300
+                ? "<!--[if IE]><style type='text/css' id='".esc_attr( $sIDPrefix."-ie" )."'>"
301 301
                         . $_sStyleIE
302 302
                     . "</style><![endif]-->"
303 303
                 : '';
@@ -330,14 +330,14 @@  discard block
 block discarded – undo
330 330
         $_sScript = $this->addAndApplyFilters( 
331 331
             $this->oProp->oCaller, 
332 332
             array(
333
-                "script_common_admin_page_framework",       // 3.2.1+
333
+                "script_common_admin_page_framework", // 3.2.1+
334 334
                 "script_common_{$this->oProp->sClassName}", 
335 335
             ),
336 336
             AdminPageFramework_Property_Base::$_sDefaultScript 
337 337
         );
338 338
         $_sScript = trim( $_sScript );
339 339
         if ( $_sScript ) {
340
-            echo "<script type='text/javascript' id='" . esc_attr( $sIDPrefix ) . "'>"
340
+            echo "<script type='text/javascript' id='".esc_attr( $sIDPrefix )."'>"
341 341
                     . '/* <![CDATA[ */'
342 342
                     . $_sScript
343 343
                     . '/* ]]> */'
@@ -356,7 +356,7 @@  discard block
 block discarded – undo
356 356
      */
357 357
     protected function _printClassSpecificStyles( $sIDPrefix ) {
358 358
            
359
-        $_oCaller   = $this->oProp->oCaller;     
359
+        $_oCaller = $this->oProp->oCaller;     
360 360
         echo $this->_getClassSpecificStyleTag( $_oCaller, $sIDPrefix );
361 361
         echo $this->_getClassSpecificIEStyleTag( $_oCaller, $sIDPrefix );
362 362
         
@@ -387,7 +387,7 @@  discard block
 block discarded – undo
387 387
                 // : $this->getCSSMinified( $_sStyle );
388 388
             if ( $_sStyle ) {
389 389
                 $_iCallCount++;
390
-                return "<style type='text/css' id='" . esc_attr( "{$sIDPrefix}-{$this->oProp->sClassName}_{$_iCallCount}" ) . "'>"
390
+                return "<style type='text/css' id='".esc_attr( "{$sIDPrefix}-{$this->oProp->sClassName}_{$_iCallCount}" )."'>"
391 391
                         . $_sStyle
392 392
                     . "</style>";
393 393
             }         
@@ -415,7 +415,7 @@  discard block
 block discarded – undo
415 415
                 // : $this->getCSSMinified( $_sStyleIE );
416 416
             if ( $_sStyleIE ) {
417 417
                 $_iCallCountIE++;
418
-                return "<!--[if IE]><style type='text/css' id='" . esc_attr( "{$sIDPrefix}-ie-{$this->oProp->sClassName}_{$_iCallCountIE}" ) . "'>" 
418
+                return "<!--[if IE]><style type='text/css' id='".esc_attr( "{$sIDPrefix}-ie-{$this->oProp->sClassName}_{$_iCallCountIE}" )."'>" 
419 419
                         . $_sStyleIE
420 420
                     . "</style><![endif]-->";
421 421
             }            
@@ -443,7 +443,7 @@  discard block
 block discarded – undo
443 443
         $_sScript = trim( $_sScript );
444 444
         if ( $_sScript ) {
445 445
             $_iCallCount++;
446
-            echo "<script type='text/javascript' id='" . esc_attr( "{$sIDPrefix}-{$this->oProp->sClassName}_{$_iCallCount}" ) . "'>" 
446
+            echo "<script type='text/javascript' id='".esc_attr( "{$sIDPrefix}-{$this->oProp->sClassName}_{$_iCallCount}" )."'>" 
447 447
                     . '/* <![CDATA[ */'
448 448
                     . $_sScript
449 449
                     . '/* ]]> */'
@@ -468,12 +468,12 @@  discard block
 block discarded – undo
468 468
     public function _replyToAddStyle() {
469 469
     
470 470
         $_oCaller = $this->oProp->oCaller;     
471
-        if ( ! $_oCaller->_isInThePage() ) {
471
+        if ( !$_oCaller->_isInThePage() ) {
472 472
             return; 
473 473
         }
474 474
         
475 475
         $this->_printCommonStyles( 'admin-page-framework-style-common', get_class() );
476
-        $this->_printClassSpecificStyles( $this->_sClassSelector_Style . '-' . $this->oProp->sStructureType );
476
+        $this->_printClassSpecificStyles( $this->_sClassSelector_Style.'-'.$this->oProp->sStructureType );
477 477
  
478 478
     }
479 479
     /**
@@ -488,12 +488,12 @@  discard block
 block discarded – undo
488 488
     public function _replyToAddScript() {
489 489
 
490 490
         $_oCaller = $this->oProp->oCaller;     
491
-        if ( ! $_oCaller->_isInThePage() ) { 
491
+        if ( !$_oCaller->_isInThePage() ) { 
492 492
             return; 
493 493
         }
494 494
         
495 495
         $this->_printCommonScripts( 'admin-page-framework-script-common', get_class() );
496
-        $this->_printClassSpecificScripts( $this->_sClassSelector_Script . '-' . $this->oProp->sStructureType );
496
+        $this->_printClassSpecificScripts( $this->_sClassSelector_Script.'-'.$this->oProp->sStructureType );
497 497
         
498 498
     }        
499 499
     
@@ -508,28 +508,28 @@  discard block
 block discarded – undo
508 508
     protected function _enqueueSRC( $aEnqueueItem ) {
509 509
         
510 510
         // For styles
511
-        if ( 'style' === $aEnqueueItem['sType'] ) {
511
+        if ( 'style' === $aEnqueueItem[ 'sType' ] ) {
512 512
             wp_enqueue_style( 
513
-                $aEnqueueItem['handle_id'], 
514
-                $aEnqueueItem['sSRC'], 
515
-                $aEnqueueItem['dependencies'], 
516
-                $aEnqueueItem['version'], 
517
-                $aEnqueueItem['media']
513
+                $aEnqueueItem[ 'handle_id' ], 
514
+                $aEnqueueItem[ 'sSRC' ], 
515
+                $aEnqueueItem[ 'dependencies' ], 
516
+                $aEnqueueItem[ 'version' ], 
517
+                $aEnqueueItem[ 'media' ]
518 518
             );
519 519
             return;
520 520
         }
521 521
 
522 522
         // For scripts
523 523
         wp_enqueue_script( 
524
-            $aEnqueueItem['handle_id'], 
525
-            $aEnqueueItem['sSRC'], 
526
-            $aEnqueueItem['dependencies'], 
527
-            $aEnqueueItem['version'], 
528
-            did_action( 'admin_body_class' ) ? true : $aEnqueueItem['in_footer'] 
524
+            $aEnqueueItem[ 'handle_id' ], 
525
+            $aEnqueueItem[ 'sSRC' ], 
526
+            $aEnqueueItem[ 'dependencies' ], 
527
+            $aEnqueueItem[ 'version' ], 
528
+            did_action( 'admin_body_class' ) ? true : $aEnqueueItem[ 'in_footer' ] 
529 529
         );
530 530
     
531
-        if ( $aEnqueueItem['translation'] ) {
532
-            wp_localize_script( $aEnqueueItem['handle_id'], $aEnqueueItem['handle_id'], $aEnqueueItem['translation'] );
531
+        if ( $aEnqueueItem[ 'translation' ] ) {
532
+            wp_localize_script( $aEnqueueItem[ 'handle_id' ], $aEnqueueItem[ 'handle_id' ], $aEnqueueItem[ 'translation' ] );
533 533
         }
534 534
         
535 535
     }
@@ -545,7 +545,7 @@  discard block
 block discarded – undo
545 545
      * @internal
546 546
      */    
547 547
     public function _replyToEnqueueStyles() {        
548
-        foreach( $this->oProp->aEnqueuingStyles as $_sKey => $_aEnqueuingStyle ) {
548
+        foreach ( $this->oProp->aEnqueuingStyles as $_sKey => $_aEnqueuingStyle ) {
549 549
             $this->_enqueueSRCByCondition( $_aEnqueuingStyle );
550 550
             unset( $this->oProp->aEnqueuingStyles[ $_sKey ] );
551 551
         }
@@ -562,7 +562,7 @@  discard block
 block discarded – undo
562 562
      * @internal
563 563
      */
564 564
     public function _replyToEnqueueScripts() {     
565
-        foreach( $this->oProp->aEnqueuingScripts as $_sKey => $_aEnqueuingScript ) {
565
+        foreach ( $this->oProp->aEnqueuingScripts as $_sKey => $_aEnqueuingScript ) {
566 566
             $this->_enqueueSRCByCondition( $_aEnqueuingScript );     
567 567
             unset( $this->oProp->aEnqueuingScripts[ $_sKey ] );
568 568
         }
Please login to merge, or discard this patch.
Braces   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -235,7 +235,7 @@  discard block
 block discarded – undo
235 235
      */
236 236
     protected function _printCommonStyles( $sIDPrefix, $sClassName ) {
237 237
 
238
-        if ( self::$_bCommonStyleLoaded ) { 
238
+        if ( self::$_bCommonStyleLoaded ) {
239 239
             return; 
240 240
         }
241 241
         self::$_bCommonStyleLoaded = true;
@@ -474,7 +474,7 @@  discard block
 block discarded – undo
474 474
     public function _replyToAddScript() {
475 475
 
476 476
         $_oCaller = $this->oProp->_getCallerObject();     
477
-        if ( ! $_oCaller->_isInThePage() ) { 
477
+        if ( ! $_oCaller->_isInThePage() ) {
478 478
             return; 
479 479
         }
480 480
         
@@ -530,7 +530,7 @@  discard block
 block discarded – undo
530 530
      * @since       3.2.0   Changed it unset the enqueued item so that the method can be called multiple times.
531 531
      * @internal
532 532
      */    
533
-    public function _replyToEnqueueStyles() {        
533
+    public function _replyToEnqueueStyles() {
534 534
         foreach( $this->oProp->aEnqueuingStyles as $_sKey => $_aEnqueuingStyle ) {
535 535
             $this->_enqueueSRCByCondition( $_aEnqueuingStyle );
536 536
             unset( $this->oProp->aEnqueuingStyles[ $_sKey ] );
@@ -547,7 +547,7 @@  discard block
 block discarded – undo
547 547
      * @since       3.2.0   Changed it unset the enqueued item so that the method can be called multiple times.
548 548
      * @internal
549 549
      */
550
-    public function _replyToEnqueueScripts() {     
550
+    public function _replyToEnqueueScripts() {
551 551
         foreach( $this->oProp->aEnqueuingScripts as $_sKey => $_aEnqueuingScript ) {
552 552
             $this->_enqueueSRCByCondition( $_aEnqueuingScript );     
553 553
             unset( $this->oProp->aEnqueuingScripts[ $_sKey ] );
Please login to merge, or discard this patch.
factory/_common/_abstract/_model/AdminPageFramework_Property_Base.php 2 patches
Doc Comments   +2 added lines patch added patch discarded remove patch
@@ -370,6 +370,8 @@
 block discarded – undo
370 370
      * Sets up necessary property values.
371 371
      * 
372 372
      * @remark      This class gets instantiated in every factory class so the constructor should be lightest as possible.
373
+     * @param string $sCapability
374
+     * @param string $sTextDomain
373 375
      */
374 376
     public function __construct( $oCaller, $sCallerPath, $sClassName, $sCapability, $sTextDomain, $sStructureType ) {
375 377
                 
Please login to merge, or discard this patch.
Spacing   +15 added lines, -15 removed lines patch added patch discarded remove patch
@@ -148,7 +148,7 @@  discard block
 block discarded – undo
148 148
      * @deprecated  3.2.0
149 149
      * @internal    
150 150
      */
151
-    public static $_sDefaultStyle ="";    
151
+    public static $_sDefaultStyle = "";    
152 152
         
153 153
     /**
154 154
      * The default CSS rules for IE loaded in the head tag of the created admin pages.
@@ -315,14 +315,14 @@  discard block
 block discarded – undo
315 315
      * @since       3.7.0
316 316
      */
317 317
     public $aFormCallbacks = array(
318
-        'hfID'              => null,    // the input id attribute
319
-        'hfTagID'           => null,    // the field container id attribute
320
-        'hfName'            => null,    // the field name attribute
321
-        'hfNameFlat'        => null,    // the flat field name attribute
318
+        'hfID'              => null, // the input id attribute
319
+        'hfTagID'           => null, // the field container id attribute
320
+        'hfName'            => null, // the field name attribute
321
+        'hfNameFlat'        => null, // the flat field name attribute
322 322
         // @todo Document the differences between `hfName` and `hfInputName`
323
-        'hfInputName'       => null,    // 3.6.0+   the field input name attribute
324
-        'hfInputNameFlat'   => null,    // 3.6.0+   the flat field input name 
325
-        'hfClass'           => null,    // the class attribute       
323
+        'hfInputName'       => null, // 3.6.0+   the field input name attribute
324
+        'hfInputNameFlat'   => null, // 3.6.0+   the flat field input name 
325
+        'hfClass'           => null, // the class attribute       
326 326
     );
327 327
             
328 328
     /**
@@ -401,7 +401,7 @@  discard block
 block discarded – undo
401 401
          * @since       3.7.9
402 402
          */
403 403
         private function _setGlobals() {
404
-            if ( ! isset( $GLOBALS[ 'aAdminPageFramework' ] ) ) {
404
+            if ( !isset( $GLOBALS[ 'aAdminPageFramework' ] ) ) {
405 405
                 $GLOBALS[ 'aAdminPageFramework' ] = array( 
406 406
                     'aFieldFlags' => array() 
407 407
                 );
@@ -425,7 +425,7 @@  discard block
 block discarded – undo
425 425
     public function getFormArguments() {
426 426
         return array(
427 427
             'caller_id'                         => $this->sClassName,
428
-            'structure_type'                    => $this->_sPropertyType,  // @todo change this to admin_page
428
+            'structure_type'                    => $this->_sPropertyType, // @todo change this to admin_page
429 429
             'action_hook_form_registration'     => $this->_sFormRegistrationHook,
430 430
         ) + $this->aFormArguments;
431 431
     }
@@ -467,8 +467,8 @@  discard block
 block discarded – undo
467 467
             'hfTagID'                           => array( $this->oCaller, '_replyToGetInputTagIDAttribute' ), // the fields & fieldset & field row container id attribute
468 468
             'hfName'                            => array( $this->oCaller, '_replyToGetFieldNameAttribute' ), // the input name attribute
469 469
             'hfNameFlat'                        => array( $this->oCaller, '_replyToGetFlatFieldName' ), // the flat input name attribute
470
-            'hfInputName'                       => array( $this->oCaller, '_replyToGetInputNameAttribute' ),    // 3.6.0+   the field input name attribute
471
-            'hfInputNameFlat'                   => array( $this->oCaller, '_replyToGetFlatInputName' ),    // 3.6.0+   the flat field input name                 
470
+            'hfInputName'                       => array( $this->oCaller, '_replyToGetInputNameAttribute' ), // 3.6.0+   the field input name attribute
471
+            'hfInputNameFlat'                   => array( $this->oCaller, '_replyToGetFlatInputName' ), // 3.6.0+   the flat field input name                 
472 472
             'hfClass'                           => array( $this->oCaller, '_replyToGetInputClassAttribute' ), // the class attribute
473 473
             'hfSectionName'                     => array( $this->oCaller, '_replyToGetSectionName' ), // 3.6.0+            
474 474
         ) + $this->aFormCallbacks;        
@@ -542,7 +542,7 @@  discard block
 block discarded – undo
542 542
      * @remark      The information can be used to embed into the footer etc.
543 543
      * @return      array       The information of the script.
544 544
      */  
545
-    protected function getCallerInfo( $sCallerPath='' ) {
545
+    protected function getCallerInfo( $sCallerPath = '' ) {
546 546
 
547 547
         if ( isset( self::$_aScriptDataCaches[ $sCallerPath ] ) ) {
548 548
             return self::$_aScriptDataCaches[ $sCallerPath ];
@@ -660,11 +660,11 @@  discard block
 block discarded – undo
660 660
 
661 661
         // 3.7.9 Moved from the constructor to make it lighter.
662 662
         if ( 'sClassHash' === $sName ) {
663
-            $this->sClassHash       = md5( $this->sClassName );    
663
+            $this->sClassHash = md5( $this->sClassName );    
664 664
             return $this->sClassHash;
665 665
         }
666 666
         if ( 'sScriptType' === $sName ) {
667
-            $this->sScriptType      = $this->_getCallerType( $this->sCallerPath );    // 3.7.6+        
667
+            $this->sScriptType = $this->_getCallerType( $this->sCallerPath ); // 3.7.6+        
668 668
             return $this->sScriptType;
669 669
         }
670 670
         if ( 'oUtil' === $sName ) {
Please login to merge, or discard this patch.
factory/_common/_abstract/_view/AdminPageFramework_PageLoadInfo_Base.php 3 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -109,7 +109,7 @@
 block discarded – undo
109 109
          * Converts bytes to HR.
110 110
          *
111 111
          * @access private
112
-         * @param mixed $bytes
112
+         * @param mixed $nBytes
113 113
          * @remark This is influenced by the work of Mike Jolley.
114 114
          * @see http://mikejolley.com/projects/wp-page-load-stats/
115 115
          */
Please login to merge, or discard this patch.
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -28,11 +28,11 @@  discard block
 block discarded – undo
28 28
      */
29 29
     public function __construct( $oProp, $oMsg ) {
30 30
         
31
-        if ( $oProp->bIsAdminAjax || ! $oProp->bIsAdmin ) {
31
+        if ( $oProp->bIsAdminAjax || !$oProp->bIsAdmin ) {
32 32
             return;
33 33
         }     
34 34
         
35
-        if ( ! defined( 'WP_DEBUG' ) || ! WP_DEBUG ) {
35
+        if ( !defined( 'WP_DEBUG' ) || !WP_DEBUG ) {
36 36
             return;
37 37
         }
38 38
             
@@ -78,10 +78,10 @@  discard block
 block discarded – undo
78 78
         return $sFooterHTML
79 79
             . "<div id='admin-page-framework-page-load-stats'>"
80 80
                 . "<ul>"
81
-                    . "<li>" . sprintf( $this->oMsg->get( 'queries_in_seconds' ), $_nQueryCount, $_nSeconds ) . "</li>"
82
-                    . "<li>" . sprintf( $this->oMsg->get( 'out_of_x_memory_used' ), $_nMemoryUsage, $_nMemoryLimit, round( ( $_nMemoryUsage / $_nMemoryLimit ), 2 ) * 100 . '%' ) . "</li>"
83
-                    . "<li>" . sprintf( $this->oMsg->get( 'peak_memory_usage' ), $_nMemoryPeakUsage ) . "</li>"
84
-                    . "<li>" . sprintf( $this->oMsg->get( 'initial_memory_usage' ), $_sInitialMemoryUsage ) . "</li>"
81
+                    . "<li>".sprintf( $this->oMsg->get( 'queries_in_seconds' ), $_nQueryCount, $_nSeconds )."</li>"
82
+                    . "<li>".sprintf( $this->oMsg->get( 'out_of_x_memory_used' ), $_nMemoryUsage, $_nMemoryLimit, round( ( $_nMemoryUsage / $_nMemoryLimit ), 2 ) * 100.'%' )."</li>"
83
+                    . "<li>".sprintf( $this->oMsg->get( 'peak_memory_usage' ), $_nMemoryPeakUsage )."</li>"
84
+                    . "<li>".sprintf( $this->oMsg->get( 'initial_memory_usage' ), $_sInitialMemoryUsage )."</li>"
85 85
                 . "</ul>"
86 86
             . "</div>";
87 87
         
@@ -99,8 +99,8 @@  discard block
 block discarded – undo
99 99
          */
100 100
         private function _convertToNumber( $nSize ) {
101 101
             
102
-            $_nReturn     = substr( $nSize, 0, -1 );
103
-            switch( strtoupper( substr( $nSize, -1 ) ) ) {
102
+            $_nReturn = substr( $nSize, 0, -1 );
103
+            switch ( strtoupper( substr( $nSize, -1 ) ) ) {
104 104
                 case 'P':
105 105
                     $_nReturn *= 1024;
106 106
                 case 'T':
@@ -129,7 +129,7 @@  discard block
 block discarded – undo
129 129
             $_nLog = log( $nBytes, 1024 );
130 130
             $_iPower = ( int ) $_nLog;
131 131
             $_iSize = pow( 1024, $_nLog - $_iPower );
132
-            return $_iSize . $_aUnits[ $_iPower ];
132
+            return $_iSize.$_aUnits[ $_iPower ];
133 133
         }
134 134
 
135 135
 }
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
      */
64 64
     public function _replyToGetPageLoadInfo( $sFooterHTML ) {
65 65
         
66
-        if ( self::$_bLoadedPageLoadInfo ) { 
66
+        if ( self::$_bLoadedPageLoadInfo ) {
67 67
             return; 
68 68
         }
69 69
         self::$_bLoadedPageLoadInfo = true;     
Please login to merge, or discard this patch.
factory/_common/_abstract/AdminPageFramework_Factory_Controller.php 4 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -187,7 +187,7 @@  discard block
 block discarded – undo
187 187
      * @access      public
188 188
      * @remark      The actual registration will be performed in the `_replyToRegisterSettings()` method with the `admin_menu` hook.
189 189
      * @remark      The `$oForm` property should be created in each extended class.
190
-     * @param       array|string        $aSection       the section array. If a string is passed, it is considered as a target page slug that will be used as a page slug element from the next call so that the element can be omitted.
190
+     * @param       array|string        $aSectionset       the section array. If a string is passed, it is considered as a target page slug that will be used as a page slug element from the next call so that the element can be omitted.
191 191
      * <h4>Section Definition Array</h4>
192 192
      * <ul>
193 193
      *      <li>**section_id** - (string) the section ID. Avoid using non-alphabetic characters except underscore and numbers.</li>
@@ -299,7 +299,7 @@  discard block
 block discarded – undo
299 299
      * @since        3.0.0   The scope changed to public to indicate the users will use.
300 300
      * @return       void
301 301
      * @remark       The $oForm property should be created in each extended class.
302
-     * @param        array|string       $asField        A field definition array or a string of the target section id.
302
+     * @param        array|string       $asFieldset        A field definition array or a string of the target section id.
303 303
     * <h4>Built-in Field Types</h4>
304 304
     * <ul>
305 305
     *       <li>**text** - a normal field to enter text input.</li>
Please login to merge, or discard this patch.
Indentation   +277 added lines, -277 removed lines patch added patch discarded remove patch
@@ -291,18 +291,18 @@  discard block
 block discarded – undo
291 291
     }     
292 292
         
293 293
     /**
294
-    * Adds form fields.
295
-    * 
296
-    * It inserts the given field definition arrays into the class property and later they are parsed when fields are registered. The field definition array requires specific keys. Refer to the parameter section of this method.
297
-    * 
298
-    * @since        2.0.0
299
-    * @since        3.5.3       Removed the parameter declarations as they are caught with the func_get_args().
300
-    * @remark       Accepts variadic parameters; the number of accepted parameters are not limited to three.
301
-    * @param        array       the field definition array.
302
-    * @param        array       (optional) another field array.
303
-    * @param        array       (optional) add more field arrays to the next parameters as many as necessary.
304
-    * @return       void
305
-    */ 
294
+     * Adds form fields.
295
+     * 
296
+     * It inserts the given field definition arrays into the class property and later they are parsed when fields are registered. The field definition array requires specific keys. Refer to the parameter section of this method.
297
+     * 
298
+     * @since        2.0.0
299
+     * @since        3.5.3       Removed the parameter declarations as they are caught with the func_get_args().
300
+     * @remark       Accepts variadic parameters; the number of accepted parameters are not limited to three.
301
+     * @param        array       the field definition array.
302
+     * @param        array       (optional) another field array.
303
+     * @param        array       (optional) add more field arrays to the next parameters as many as necessary.
304
+     * @return       void
305
+     */ 
306 306
     public function addSettingFields( /* $aField1, $aField2=null, $_and_more=null */ ) {
307 307
         foreach( func_get_args() as $_aFieldset ) { 
308 308
             $this->addSettingField( $_aFieldset ); 
@@ -333,249 +333,249 @@  discard block
 block discarded – undo
333 333
      * @return       void
334 334
      * @remark       The $oForm property should be created in each extended class.
335 335
      * @param        array|string       $asField        A field definition array or a string of the target section id.
336
-    * <h4>Built-in Field Types</h4>
337
-    * <ul>
338
-    *       <li>**text** - a normal field to enter text input.</li>
339
-    *       <li>**password** - a masked text input field.</li>
340
-    *       <li>**textarea** - a text input field with multiple lines. It supports rich text editor.</li>
341
-    *       <li>**radio** - a set of radio buttons that lets the user pick an option.</li>
342
-    *       <li>**checkbox** - a check box that lets the user enable/disable an item.</li>
343
-    *       <li>**select** - a drop-down list that lest the user pick one or more item(s) from a list.</li>
344
-    *       <li>**hidden** - a hidden field that will be useful to insert invisible values.</li>
345
-    *       <li>**file** - a file uploader that lets the user upload files.</li>
346
-    *       <li>**image** - a custom text field with the image uploader script that lets the user set the image URL.</li>
347
-    *       <li>**media** - a custom text field with the media uploader script that lets the user set the file URL.</li>
348
-    *       <li>**color** - a custom text field with the color picker script.</li>
349
-    *       <li>**submit** - a submit button that lets the user send the form.</li>
350
-    *       <li>**export** - a custom submit field that lets the user export the stored data.</li>
351
-    *       <li>**import** - a custom combination field of the file and the submit fields that let the user import data.</li>
352
-    *       <li>**posttype** - a check-list of post types enabled on the site.</li>
353
-    *       <li>**taxonomy** - a set of check-lists of taxonomies enabled on the site in a tabbed box.</li>
354
-    *       <li>**size** - a combination field of the text and the select fields that let the user set sizes with a selectable unit.</li>
355
-    *       <li>**section_title** - [3.0.0+] a text field type that will be placed in the section title so that it lets the user set the section title. Note that only one field with this field type is allowed per a section.</li>
356
-    *       <li>**system** - [3.3.0+] a custom textara field that displays the system information including the PHP settings, the framework version, MySQL version etc.</li>
357
-    * </ul>
358
-    * <h4>Field Definition Array</h4>
359
-    * <ul>
360
-    *       <li>**field_id** - ( required, string) the field ID. Avoid using non-alphabetic characters except underscore and numbers.</li>
361
-    *       <li>**type** - ( required, string) the type of the field. The supported types are listed below.</li>
362
-    *       <li>**section_id** - (optional, string) the section ID that the field belongs to. If not set, the internal `_default` section ID will be assigned.</li>
363
-    *       <li>**title** - (optional, string) the title of the section.</li>
364
-    *       <li>**description** - (optional, string) the description of the field which is inserted into the after the input field tag.</li>
365
-    *       <li>**tip** - (optional, string) the tip for the field which is displayed when the mouse is hovered over the field title.</li>
366
-    *       <li>**capability** - (optional, string) the <a href="http://codex.wordpress.org/Roles_and_Capabilities">access level</a> of the section. If the page visitor does not have sufficient capability, the section will be invisible to them.</li>
367
-    *       <li>**error_message** - (optional, string) the error message to display above the input field.</li>
368
-    *       <li>**before_field** - (optional, string) the HTML string to insert before the input field output.</li>
369
-    *       <li>**after_field** - (optional, string) the HTML string to insert after the input field output.</li>
370
-    *       <li>**if** - (optional, boolean) if the passed value is false, the section will not be registered.</li>
371
-    *       <li>**order** - (optional, integer) the order number of the section. The higher the number is, the lower the position it gets.</li>
372
-    *       <li>**label** - (optional, string) the text label(s) associated with and displayed along with the input field. Some input types can ignore this key.</li>
373
-    *       <li>**default** - (optional, string|array) the default value(s) assigned to the input tag's value attribute.</li>
374
-    *       <li>**value** - (optional, string|array) the value(s) assigned to the input tag's `value` attribute to override the default and the stored value.</li>
375
-    *       <li>**delimiter** - (optional, string) the HTML string that delimits multiple elements. This is available if the <var>label</var> key is passed as array. It will be enclosed in inline-block elements so the passed HTML string should not contain block elements.</li>
376
-    *       <li>**before_input** - (optional, string) the HTML string inserted right before the input tag. It will be enclosed in the <code>label</code> tag so the passed HTML string should not contain block elements.</li>
377
-    *       <li>**after_input** - (optional, string) the HTML string inserted right after the input tag. It will be enclosed in the <code>label</code> tag so the passed HTML string should not contain block elements.</li>
378
-    *       <li>**label_min_width** - (optional, string) the inline style property of the `min-width` of the label tag for the field. If the unit is not specified, 'px' is applied. Default: `120`. e.g. `100%`</li> 
379
-    *       <li>**help** - (optional, string) the help description added to the contextual help tab.</li>
380
-    *       <li>**help_aside** - (optional, string) the additional help description for the side bar of the contextual help tab.</li>
381
-    *       <li>**repeatable** - [3.0.0+] (optional, array|boolean) whether the fields should be repeatable. If it yields true, the plus and the minus buttons appear next to each field that lets the user add/remove the fields. Optionally an setting array can be passed.
382
-    *           <h5>Repeatable Fields Setting Array</h5>
383
-    *           <ul>
384
-    *                 <li>**max** - the allowed maximum number of fields to be repeated.</li>
385
-    *                 <li>**min** - the allowed minimum number of fields to be repeated.</li>
386
-    *           </ul>
387
-    *       </li>
388
-    *       <li>**sortable** - [3.0.0+] (optional, boolean) whether the fields should be sortable. If it yields true, the fields will be enclosed in a draggable box.
389
-    *       <li>**attributes** - [3.0.0+] (optional, array) holds key-value pairs representing the attribute and its property. Note that some field types have specific keys in the first dimensions. e.g. `array( 'class' => 'my_custom_class_selector', 'style' => 'background-color:#777', 'size' => 20, )` Every field holds the following nested attribute definition arrays.
390
-    *           <ul>
391
-    *               <li>**fieldrow** - the `td` tag element containing the field output.</li>
392
-    *               <li>**fieldset** - the `fieldset` tag element containing the field output.</li>
393
-    *               <li>**fields** - the `div` tag element containing the sub-fields and the main field.</li>
394
-    *               <li>**field** - the `div` tag element containing each field.</li>
395
-    *           </ul>
396
-    *       </li>
397
-    *       <li>**show_title_column** - [3.0.0+] (optional, boolean) If true, the field title column will be omitted from the output.</li>
398
-    *       <li>**hidden** - [3.0.0+] (optional, boolean) If true, the entire field row output will be invisible with the inline style attribute of `style="display:none"`.</li>
399
-    *       <li>**save** - [3.6.0+] (optional, boolean) If `false`, the field value will not be saved. Default: `true`</li>
400
-    *       <li>**content** - (optional, string) [3.6.1+] a custom section output.</li>
401
-    * </ul>
402
-    * 
403
-    * <h4>Field Type Specific Arguments</h4>
404
-    * <p>Each field type uses specific array arguments.</p>
405
-    * <ul>
406
-    *       <li>**text** - a text input field which allows the user to type text.</li>
407
-    *       <li>**password** - a password input field which allows the user to type text.</li>
408
-    *       <li>**number, range** - HTML5 input field types. Some browsers do not support these.</li>
409
-    *       <li>**textarea** - a textarea input field. The following array keys are supported.
410
-    *           <ul>
411
-    *               <li>**rich** - [2.1.2+] (optional, array) to make it a rich text editor pass a non-empty value. It accept a setting array of the <code>_WP_Editors</code> class defined in the core.
412
-    * For more information, see the argument section of <a href="http://codex.wordpress.org/Function_Reference/wp_editor" target="_blank">this page</a>.
413
-    *               </li>
414
-    *           </ul>
415
-    *       </li>
416
-    *       <li>**radio** - a radio button input field.</li>
417
-    *       <li>**checkbox** - a check box input field.</li>
418
-    *           <ul>
419
-    *               <li>**select_all_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select All` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
420
-    *               <li>**select_none_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select None` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
421
-    *           </ul>
422
-    *       <li>**select** - a drop-down input field.
423
-    *           <ul>
424
-    *               <li>**is_multiple** - (optional, boolean) if this is set to true, the `multiple` attribute will be inserted into the field input tag, which enables the multiple selections for the user.</li>
425
-    *           </ul>
426
-    *       </li>
427
-    *       <li>**size** - a size input field. This is a combination of number and select fields.
428
-    *           <ul>
429
-    *               <li>
430
-    *                   **units** - (optional, array) defines the units to show. e.g. `array( 'px' => 'px', '%' => '%', 'em' => 'em'  )` 
431
-    *                   Default: `array( 'px' => 'px', '%' => '%', 'em' => 'em', 'ex' => 'ex', 'in' => 'in', 'cm' => 'cm', 'mm' => 'mm', 'pt' => 'pt', 'pc' => 'pc' )`
432
-    *               </li>
433
-    *               <li>**is_multiple** - (optional, boolean) if this is set to true, the `multiple` attribute will be inserted into the field input tag, which enables the multiple selections for the user.</li>
434
-    *               <li>**attributes** - [3.0.0+] (optional, array) The attributes array of this field type has four initial keys: size, unit, optgroup, and option and they have a regular attribute array in each.</li>
435
-    *           </ul>
436
-    *       </li>
437
-    *       <li>**hidden** - a hidden input field.</li>
438
-    *       <li>**file** - a file upload input field.</li>
439
-    *       <li>**submit** - a submit button input field.
440
-    *           <ul>
441
-    *               <li>**href** - (optional, string) the url(s) linked to the submit button.</li>
442
-    *               <li>**redirect_url** - (optional, string) the url(s) redirected to after submitting the input form.</li>
443
-    *               <li>**reset** - [2.1.2+] (optional, boolean|string|array) the option key to delete. Set 1 for the entire option. [3.5.3+] In order to reset a particular field that belongs to a section, set an array representing the dimensional keys such as `array( 'my_sectio_id', 'my_field_id' )`.</li>
444
-    *               <li>**skip_confirmation** - [3.7.6+] (optional, boolean) Whether to skip confirmation. Default: `false`.</li>
445
-    *               <li>**email** - [3.3.0+] (optional, array) Coming soon...
446
-    *                   <ul>
447
-    *                       <li>**to** - (string|array) the email address to send the email to. For multiple email addressed, set comma delimited items.</li>
448
-    *                       <li>**subject** - (string|array) the email title.</li>
449
-    *                       <li>**message** - (string|array) the email body text.</li>
450
-    *                       <li>**attachments** - (string|array) the file path.</li>
451
-    *                       <li>**name** - (string|array) the sender name.</li>
452
-    *                       <li>**from** - (string|array) the sender email.</li>
453
-    *                       <li>**is_html** - (boolean|array) indicates whether the message should be sent as an html or plain text.</li>
454
-    *                   </ul>
455
-    *               </li>
456
-    *           </ul>
457
-    *       </li>
458
-    *       <li>**import** - an import input field. This is a custom file and submit field.
459
-    *           <ul>
460
-    *               <li>**option_key** - (optional, string) the option table key to save the importing data.</li>
461
-    *               <li>**format** - (optional, string) the import format. json, or array is supported. Default: array</li>
462
-    *               <li>**is_merge** - (optional, boolean) [2.0.5+] determines whether the imported data should be merged with the existing options.</li>
463
-    *           </ul>
464
-    *       </li>
465
-    *       <li>**export** - an export input field. This is a custom submit field.
466
-    *           <ul>
467
-    *               <li>**file_name** - (optional, string) the file name to download.</li>
468
-    *               <li>**format** - (optional, string) the format type. array, json, or text is supported. Default: array.</li>
469
-    *               <li>**data** - (optional, string|array|object ) the data to export.</li>
470
-    *           </ul>
471
-    *       </li>
472
-    *       <li>**image** - an image input field. This is a custom text field with an attached JavaScript script.
473
-    *           <ul>
474
-    *               <li>**show_preview** - (optional, boolean) if this is set to false, the image preview will be disabled.</li>
475
-    *               <li>**attributes_to_store** - [2.1.3+] (optional, array) the array of the attribute names of the image to save. If this is set, the field will be an array with the specified attributes. The supported attributes are, 'title', 'alt', 'width', 'height', 'caption', 'id', 'align', and 'link'. Note that for external URLs, ID will not be captured. e.g. `'attributes_to_store' => array( 'id', 'caption', 'description' )`</li>
476
-    *               <li>**allow_external_source** - [2.1.3+] (optional, boolean) whether external URL can be set via the uploader.</li>
477
-    *               <li>**attributes** - [3.0.0+] (optional, array) The attributes array of this field type has three keys: input, button, and preview and they have a regular attribute array in each.</li>
478
-    *           </ul>
479
-    *       </li>
480
-    *       <li>**media** - [2.1.3+] a media input field. This is a custom text field with an attached JavaScript script.
481
-    *           <ul>
482
-    *               <li>**attributes_to_store** - [2.1.3+] (optional, array) the array of the attribute names of the image to save. If this is set, the field will be an array with the specified attributes. The supported attributes are, 'id', 'caption', and 'description'. Note that for external URLs, ID will not be captured. e.g. `'attributes_to_store' => array( 'id', 'caption', 'description' )`</li>
483
-    *               <li>**allow_external_source** - [2.1.3+] (optional, boolean) whether external URL can be set via the uploader.</li>
484
-    *           </ul>
485
-    *       </li>
486
-    *       <li>**color** - a color picker input field. This is a custom text field with a JavaScript script.</li>
487
-    *       <li>**taxonomy** - a taxonomy check list. This is a set of check boxes listing a specified taxonomy. This does not accept to create multiple fields by passing an array of labels.
488
-    *           <ul>
489
-    *               <li>**taxonomy_slugs** - (optional, array) the taxonomy slug to list.</li>
490
-    *               <li>**max_width** - (optional, string) the inline style property value of `max-width` of this element. Include the unit such as px, %. Default: 100%</li>
491
-    *               <li>**height** - (optional, string) the inline style property value of `height` of this element. Include the unit such as px, %. Default: 250px</li>
492
-    *               <li>**select_all_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select All` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
493
-    *               <li>**select_none_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select None` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
494
-    *               <li>**label_no_term_found** - [3.3.2+] (optional, string) The label to display when no term is found. Default: `No Term Found`.</li>
495
-    *               <li>**label_list_title** - [3.3.2+] (optional, string) The heading title string for a term list. Default: `''`. Insert an HTML custom string right before the list starts.</li>
496
-    *               <li>**query** - [3.3.2+] (optional, array) the query array to search terms. For more details, see the argument of the [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters) function.
497
-    *                   <ul>
498
-    *                       <li>child_of - (integer) The parent term ID. All the descendant terms such as child's child term will be listed. default: `0`</li>
499
-    *                       <li>parent   - (integer) The direct parent term ID. Only the first level children will be listed. default: ``</li>
500
-    *                       <li>orderby - (string) The type of how the term list should be ordered by. Either `ID`, `term_id`, or `name` can be accepted. Default: `name`.</li>
501
-    *                       <li>order - (string) The order of the list. `ASC` or `DESC`. Default: `ASC`.</li>
502
-    *                       <li>hide_empty - (boolean) whether to show the terms with no post associated. Default: `false`.</li>
503
-    *                       <li>hierarchical - (boolean) whether to show the terms as a hierarchical tree. Default: `true`</li>
504
-    *                       <li>number - (integer) The maximum number of the terms to show. 0 for no limit. Default: `0`.</li>
505
-    *                       <li>pad_counts - (boolean) whether to sum up the post counts with the child post counts. Default: `false`</li>
506
-    *                       <li>exclude - (string|array) Comma separated term IDs or an array to exclude from the list. for example `1` will remove the 'Uncategorized' category from the list. </li>
507
-    *                       <li>exclude_tree - (integer) For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters)..</li>
508
-    *                       <li>include - (string|array) Comma separated term IDs to include in the list.</li>
509
-    *                       <li>fields - (string) Default: `all`. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
510
-    *                       <li>slug - (string) Default: ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
511
-    *                       <li>get - (string) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
512
-    *                       <li>name__like - (string) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
513
-    *                       <li>description__like - (string) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
514
-    *                       <li>offset - (integer) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
515
-    *                       <li>search - (string) The search keyword to get the term with. Default ``.</li>
516
-    *                       <li>cache_domain - (string) Default:`core`. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
517
-    *                   </ul>
518
-    *               </li>
519
-    *               <li>**queries** - [3.3.2+] (optional, array) Allows to set a query argument for each taxonomy. The array key must be the taxonomy slug and the value is the query argument array.</li>
520
-    *           </ul>
521
-    *           <h4>Example</h4>
522
-    * <pre><code>array(  
523
-    *     'field_id'              => 'taxonomy_custom_queries',
524
-    *     'title'                 => __( 'Custom Taxonomy Queries', 'admin-page-framework-demo' ),
525
-    *     'type'                  => 'taxonomy',
526
-    *     'description'           => 
527
-    *         array(
528
-    *             __( 'With the <code>query</code> argument array, you can customize how the terms should be retrieved.', 'admin-page-framework-demo' ),
529
-    *             sprintf( __( 'For the structure and the array key specifications, refer to the parameter section of the <a href="%1$s" target="_blank">get_term()</a> function.', 'admin-page-framework-demo' ), 'http://codex.wordpress.org/Function_Reference/get_terms#Parameters' ),
530
-    *         ),
531
-    *     
532
-    *     // (required)   Determines which taxonomies should be listed
533
-    *     'taxonomy_slugs'        => $aTaxnomies = get_taxonomies( '', 'names' ),    
534
-    *         
535
-    *     // (optional) This defines the default query argument. For the structure and supported arguments, see http://codex.wordpress.org/Function_Reference/get_terms#Parameters
536
-    *     'query'                 => array(
537
-    *         'depth'     => 2,
538
-    *         'orderby'   => 'term_id',       // accepts 'ID', 'term_id', or 'name'
539
-    *         'order'     => 'DESC',
540
-    *         // 'exclude'   => '1', // removes the 'Uncategorized' category.
541
-    *         // 'search' => 'PHP',   // the search keyward
542
-    *         // 'parent'    => 9,    // only show terms whose direct parent ID is 9.
543
-    *         // 'child_of'  => 8,    // only show child terms of the term ID of 8.
544
-    *     ),
545
-    *     // (optional) This allows to set a query argument for each taxonomy. 
546
-    *     // Note that each element will be merged with the above default 'query' argument array. 
547
-    *     // So unset keys here will be overridden by the default argument array above. 
548
-    *     'queries'               => array(
549
-    *         // taxonomy slug => query argument array
550
-    *         'category'  =>  array(
551
-    *             'depth'     => 2,
552
-    *             'orderby'   => 'term_id',  
553
-    *             'order'     => 'DESC',
554
-    *             'exclude'   => array( 1 ), 
555
-    *         ),
556
-    *         'post_tag'  => array(
557
-    *             'orderby'   => 'name',
558
-    *             'order'     => 'ASC',
559
-    *             // 'include'   => array( 4, ), // term ids
560
-    *         ),
561
-    *     ), 
562
-    * ),
563
-    * </code></pre>
564
-    *       </li>
565
-    *       <li>**posttype** - a post-type check list. This is a set of check boxes listing post type slugs.
566
-    *           <ul>
567
-    *               <li>**slugs_to_remove** - (optional, array) the post type slugs not to be listed. e.g.`array( 'revision', 'attachment', 'nav_menu_item' )`</li>
568
-    *               <li>**select_all_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select All` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
569
-    *               <li>**select_none_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select None` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
570
-    *           </ul>
571
-    *       </li>
572
-    *       <li>**system** - [3.3.0+] a custom textara field that displays system information.
573
-    *           <ul>
574
-    *               <li>**data** - (optional, array) an associative array ta that holds the data to display.</li>
575
-    *               <li>**print_type** - [3.3.6+] (optional, integer) Indicates how the data array should be displayed. 1: readable array representation. 2. the output of the print_r() function. Default: `1`.</li>
576
-    *           </ul>
577
-    *       </li>
578
-    * </ul>    
336
+     * <h4>Built-in Field Types</h4>
337
+     * <ul>
338
+     *       <li>**text** - a normal field to enter text input.</li>
339
+     *       <li>**password** - a masked text input field.</li>
340
+     *       <li>**textarea** - a text input field with multiple lines. It supports rich text editor.</li>
341
+     *       <li>**radio** - a set of radio buttons that lets the user pick an option.</li>
342
+     *       <li>**checkbox** - a check box that lets the user enable/disable an item.</li>
343
+     *       <li>**select** - a drop-down list that lest the user pick one or more item(s) from a list.</li>
344
+     *       <li>**hidden** - a hidden field that will be useful to insert invisible values.</li>
345
+     *       <li>**file** - a file uploader that lets the user upload files.</li>
346
+     *       <li>**image** - a custom text field with the image uploader script that lets the user set the image URL.</li>
347
+     *       <li>**media** - a custom text field with the media uploader script that lets the user set the file URL.</li>
348
+     *       <li>**color** - a custom text field with the color picker script.</li>
349
+     *       <li>**submit** - a submit button that lets the user send the form.</li>
350
+     *       <li>**export** - a custom submit field that lets the user export the stored data.</li>
351
+     *       <li>**import** - a custom combination field of the file and the submit fields that let the user import data.</li>
352
+     *       <li>**posttype** - a check-list of post types enabled on the site.</li>
353
+     *       <li>**taxonomy** - a set of check-lists of taxonomies enabled on the site in a tabbed box.</li>
354
+     *       <li>**size** - a combination field of the text and the select fields that let the user set sizes with a selectable unit.</li>
355
+     *       <li>**section_title** - [3.0.0+] a text field type that will be placed in the section title so that it lets the user set the section title. Note that only one field with this field type is allowed per a section.</li>
356
+     *       <li>**system** - [3.3.0+] a custom textara field that displays the system information including the PHP settings, the framework version, MySQL version etc.</li>
357
+     * </ul>
358
+     * <h4>Field Definition Array</h4>
359
+     * <ul>
360
+     *       <li>**field_id** - ( required, string) the field ID. Avoid using non-alphabetic characters except underscore and numbers.</li>
361
+     *       <li>**type** - ( required, string) the type of the field. The supported types are listed below.</li>
362
+     *       <li>**section_id** - (optional, string) the section ID that the field belongs to. If not set, the internal `_default` section ID will be assigned.</li>
363
+     *       <li>**title** - (optional, string) the title of the section.</li>
364
+     *       <li>**description** - (optional, string) the description of the field which is inserted into the after the input field tag.</li>
365
+     *       <li>**tip** - (optional, string) the tip for the field which is displayed when the mouse is hovered over the field title.</li>
366
+     *       <li>**capability** - (optional, string) the <a href="http://codex.wordpress.org/Roles_and_Capabilities">access level</a> of the section. If the page visitor does not have sufficient capability, the section will be invisible to them.</li>
367
+     *       <li>**error_message** - (optional, string) the error message to display above the input field.</li>
368
+     *       <li>**before_field** - (optional, string) the HTML string to insert before the input field output.</li>
369
+     *       <li>**after_field** - (optional, string) the HTML string to insert after the input field output.</li>
370
+     *       <li>**if** - (optional, boolean) if the passed value is false, the section will not be registered.</li>
371
+     *       <li>**order** - (optional, integer) the order number of the section. The higher the number is, the lower the position it gets.</li>
372
+     *       <li>**label** - (optional, string) the text label(s) associated with and displayed along with the input field. Some input types can ignore this key.</li>
373
+     *       <li>**default** - (optional, string|array) the default value(s) assigned to the input tag's value attribute.</li>
374
+     *       <li>**value** - (optional, string|array) the value(s) assigned to the input tag's `value` attribute to override the default and the stored value.</li>
375
+     *       <li>**delimiter** - (optional, string) the HTML string that delimits multiple elements. This is available if the <var>label</var> key is passed as array. It will be enclosed in inline-block elements so the passed HTML string should not contain block elements.</li>
376
+     *       <li>**before_input** - (optional, string) the HTML string inserted right before the input tag. It will be enclosed in the <code>label</code> tag so the passed HTML string should not contain block elements.</li>
377
+     *       <li>**after_input** - (optional, string) the HTML string inserted right after the input tag. It will be enclosed in the <code>label</code> tag so the passed HTML string should not contain block elements.</li>
378
+     *       <li>**label_min_width** - (optional, string) the inline style property of the `min-width` of the label tag for the field. If the unit is not specified, 'px' is applied. Default: `120`. e.g. `100%`</li> 
379
+     *       <li>**help** - (optional, string) the help description added to the contextual help tab.</li>
380
+     *       <li>**help_aside** - (optional, string) the additional help description for the side bar of the contextual help tab.</li>
381
+     *       <li>**repeatable** - [3.0.0+] (optional, array|boolean) whether the fields should be repeatable. If it yields true, the plus and the minus buttons appear next to each field that lets the user add/remove the fields. Optionally an setting array can be passed.
382
+     *           <h5>Repeatable Fields Setting Array</h5>
383
+     *           <ul>
384
+     *                 <li>**max** - the allowed maximum number of fields to be repeated.</li>
385
+     *                 <li>**min** - the allowed minimum number of fields to be repeated.</li>
386
+     *           </ul>
387
+     *       </li>
388
+     *       <li>**sortable** - [3.0.0+] (optional, boolean) whether the fields should be sortable. If it yields true, the fields will be enclosed in a draggable box.
389
+     *       <li>**attributes** - [3.0.0+] (optional, array) holds key-value pairs representing the attribute and its property. Note that some field types have specific keys in the first dimensions. e.g. `array( 'class' => 'my_custom_class_selector', 'style' => 'background-color:#777', 'size' => 20, )` Every field holds the following nested attribute definition arrays.
390
+     *           <ul>
391
+     *               <li>**fieldrow** - the `td` tag element containing the field output.</li>
392
+     *               <li>**fieldset** - the `fieldset` tag element containing the field output.</li>
393
+     *               <li>**fields** - the `div` tag element containing the sub-fields and the main field.</li>
394
+     *               <li>**field** - the `div` tag element containing each field.</li>
395
+     *           </ul>
396
+     *       </li>
397
+     *       <li>**show_title_column** - [3.0.0+] (optional, boolean) If true, the field title column will be omitted from the output.</li>
398
+     *       <li>**hidden** - [3.0.0+] (optional, boolean) If true, the entire field row output will be invisible with the inline style attribute of `style="display:none"`.</li>
399
+     *       <li>**save** - [3.6.0+] (optional, boolean) If `false`, the field value will not be saved. Default: `true`</li>
400
+     *       <li>**content** - (optional, string) [3.6.1+] a custom section output.</li>
401
+     * </ul>
402
+     * 
403
+     * <h4>Field Type Specific Arguments</h4>
404
+     * <p>Each field type uses specific array arguments.</p>
405
+     * <ul>
406
+     *       <li>**text** - a text input field which allows the user to type text.</li>
407
+     *       <li>**password** - a password input field which allows the user to type text.</li>
408
+     *       <li>**number, range** - HTML5 input field types. Some browsers do not support these.</li>
409
+     *       <li>**textarea** - a textarea input field. The following array keys are supported.
410
+     *           <ul>
411
+     *               <li>**rich** - [2.1.2+] (optional, array) to make it a rich text editor pass a non-empty value. It accept a setting array of the <code>_WP_Editors</code> class defined in the core.
412
+     * For more information, see the argument section of <a href="http://codex.wordpress.org/Function_Reference/wp_editor" target="_blank">this page</a>.
413
+     *               </li>
414
+     *           </ul>
415
+     *       </li>
416
+     *       <li>**radio** - a radio button input field.</li>
417
+     *       <li>**checkbox** - a check box input field.</li>
418
+     *           <ul>
419
+     *               <li>**select_all_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select All` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
420
+     *               <li>**select_none_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select None` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
421
+     *           </ul>
422
+     *       <li>**select** - a drop-down input field.
423
+     *           <ul>
424
+     *               <li>**is_multiple** - (optional, boolean) if this is set to true, the `multiple` attribute will be inserted into the field input tag, which enables the multiple selections for the user.</li>
425
+     *           </ul>
426
+     *       </li>
427
+     *       <li>**size** - a size input field. This is a combination of number and select fields.
428
+     *           <ul>
429
+     *               <li>
430
+     *                   **units** - (optional, array) defines the units to show. e.g. `array( 'px' => 'px', '%' => '%', 'em' => 'em'  )` 
431
+     *                   Default: `array( 'px' => 'px', '%' => '%', 'em' => 'em', 'ex' => 'ex', 'in' => 'in', 'cm' => 'cm', 'mm' => 'mm', 'pt' => 'pt', 'pc' => 'pc' )`
432
+     *               </li>
433
+     *               <li>**is_multiple** - (optional, boolean) if this is set to true, the `multiple` attribute will be inserted into the field input tag, which enables the multiple selections for the user.</li>
434
+     *               <li>**attributes** - [3.0.0+] (optional, array) The attributes array of this field type has four initial keys: size, unit, optgroup, and option and they have a regular attribute array in each.</li>
435
+     *           </ul>
436
+     *       </li>
437
+     *       <li>**hidden** - a hidden input field.</li>
438
+     *       <li>**file** - a file upload input field.</li>
439
+     *       <li>**submit** - a submit button input field.
440
+     *           <ul>
441
+     *               <li>**href** - (optional, string) the url(s) linked to the submit button.</li>
442
+     *               <li>**redirect_url** - (optional, string) the url(s) redirected to after submitting the input form.</li>
443
+     *               <li>**reset** - [2.1.2+] (optional, boolean|string|array) the option key to delete. Set 1 for the entire option. [3.5.3+] In order to reset a particular field that belongs to a section, set an array representing the dimensional keys such as `array( 'my_sectio_id', 'my_field_id' )`.</li>
444
+     *               <li>**skip_confirmation** - [3.7.6+] (optional, boolean) Whether to skip confirmation. Default: `false`.</li>
445
+     *               <li>**email** - [3.3.0+] (optional, array) Coming soon...
446
+     *                   <ul>
447
+     *                       <li>**to** - (string|array) the email address to send the email to. For multiple email addressed, set comma delimited items.</li>
448
+     *                       <li>**subject** - (string|array) the email title.</li>
449
+     *                       <li>**message** - (string|array) the email body text.</li>
450
+     *                       <li>**attachments** - (string|array) the file path.</li>
451
+     *                       <li>**name** - (string|array) the sender name.</li>
452
+     *                       <li>**from** - (string|array) the sender email.</li>
453
+     *                       <li>**is_html** - (boolean|array) indicates whether the message should be sent as an html or plain text.</li>
454
+     *                   </ul>
455
+     *               </li>
456
+     *           </ul>
457
+     *       </li>
458
+     *       <li>**import** - an import input field. This is a custom file and submit field.
459
+     *           <ul>
460
+     *               <li>**option_key** - (optional, string) the option table key to save the importing data.</li>
461
+     *               <li>**format** - (optional, string) the import format. json, or array is supported. Default: array</li>
462
+     *               <li>**is_merge** - (optional, boolean) [2.0.5+] determines whether the imported data should be merged with the existing options.</li>
463
+     *           </ul>
464
+     *       </li>
465
+     *       <li>**export** - an export input field. This is a custom submit field.
466
+     *           <ul>
467
+     *               <li>**file_name** - (optional, string) the file name to download.</li>
468
+     *               <li>**format** - (optional, string) the format type. array, json, or text is supported. Default: array.</li>
469
+     *               <li>**data** - (optional, string|array|object ) the data to export.</li>
470
+     *           </ul>
471
+     *       </li>
472
+     *       <li>**image** - an image input field. This is a custom text field with an attached JavaScript script.
473
+     *           <ul>
474
+     *               <li>**show_preview** - (optional, boolean) if this is set to false, the image preview will be disabled.</li>
475
+     *               <li>**attributes_to_store** - [2.1.3+] (optional, array) the array of the attribute names of the image to save. If this is set, the field will be an array with the specified attributes. The supported attributes are, 'title', 'alt', 'width', 'height', 'caption', 'id', 'align', and 'link'. Note that for external URLs, ID will not be captured. e.g. `'attributes_to_store' => array( 'id', 'caption', 'description' )`</li>
476
+     *               <li>**allow_external_source** - [2.1.3+] (optional, boolean) whether external URL can be set via the uploader.</li>
477
+     *               <li>**attributes** - [3.0.0+] (optional, array) The attributes array of this field type has three keys: input, button, and preview and they have a regular attribute array in each.</li>
478
+     *           </ul>
479
+     *       </li>
480
+     *       <li>**media** - [2.1.3+] a media input field. This is a custom text field with an attached JavaScript script.
481
+     *           <ul>
482
+     *               <li>**attributes_to_store** - [2.1.3+] (optional, array) the array of the attribute names of the image to save. If this is set, the field will be an array with the specified attributes. The supported attributes are, 'id', 'caption', and 'description'. Note that for external URLs, ID will not be captured. e.g. `'attributes_to_store' => array( 'id', 'caption', 'description' )`</li>
483
+     *               <li>**allow_external_source** - [2.1.3+] (optional, boolean) whether external URL can be set via the uploader.</li>
484
+     *           </ul>
485
+     *       </li>
486
+     *       <li>**color** - a color picker input field. This is a custom text field with a JavaScript script.</li>
487
+     *       <li>**taxonomy** - a taxonomy check list. This is a set of check boxes listing a specified taxonomy. This does not accept to create multiple fields by passing an array of labels.
488
+     *           <ul>
489
+     *               <li>**taxonomy_slugs** - (optional, array) the taxonomy slug to list.</li>
490
+     *               <li>**max_width** - (optional, string) the inline style property value of `max-width` of this element. Include the unit such as px, %. Default: 100%</li>
491
+     *               <li>**height** - (optional, string) the inline style property value of `height` of this element. Include the unit such as px, %. Default: 250px</li>
492
+     *               <li>**select_all_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select All` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
493
+     *               <li>**select_none_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select None` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
494
+     *               <li>**label_no_term_found** - [3.3.2+] (optional, string) The label to display when no term is found. Default: `No Term Found`.</li>
495
+     *               <li>**label_list_title** - [3.3.2+] (optional, string) The heading title string for a term list. Default: `''`. Insert an HTML custom string right before the list starts.</li>
496
+     *               <li>**query** - [3.3.2+] (optional, array) the query array to search terms. For more details, see the argument of the [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters) function.
497
+     *                   <ul>
498
+     *                       <li>child_of - (integer) The parent term ID. All the descendant terms such as child's child term will be listed. default: `0`</li>
499
+     *                       <li>parent   - (integer) The direct parent term ID. Only the first level children will be listed. default: ``</li>
500
+     *                       <li>orderby - (string) The type of how the term list should be ordered by. Either `ID`, `term_id`, or `name` can be accepted. Default: `name`.</li>
501
+     *                       <li>order - (string) The order of the list. `ASC` or `DESC`. Default: `ASC`.</li>
502
+     *                       <li>hide_empty - (boolean) whether to show the terms with no post associated. Default: `false`.</li>
503
+     *                       <li>hierarchical - (boolean) whether to show the terms as a hierarchical tree. Default: `true`</li>
504
+     *                       <li>number - (integer) The maximum number of the terms to show. 0 for no limit. Default: `0`.</li>
505
+     *                       <li>pad_counts - (boolean) whether to sum up the post counts with the child post counts. Default: `false`</li>
506
+     *                       <li>exclude - (string|array) Comma separated term IDs or an array to exclude from the list. for example `1` will remove the 'Uncategorized' category from the list. </li>
507
+     *                       <li>exclude_tree - (integer) For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters)..</li>
508
+     *                       <li>include - (string|array) Comma separated term IDs to include in the list.</li>
509
+     *                       <li>fields - (string) Default: `all`. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
510
+     *                       <li>slug - (string) Default: ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
511
+     *                       <li>get - (string) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
512
+     *                       <li>name__like - (string) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
513
+     *                       <li>description__like - (string) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
514
+     *                       <li>offset - (integer) Default ``. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
515
+     *                       <li>search - (string) The search keyword to get the term with. Default ``.</li>
516
+     *                       <li>cache_domain - (string) Default:`core`. For more details see [get_terms()](http://codex.wordpress.org/Function_Reference/get_terms#Parameters).</li>
517
+     *                   </ul>
518
+     *               </li>
519
+     *               <li>**queries** - [3.3.2+] (optional, array) Allows to set a query argument for each taxonomy. The array key must be the taxonomy slug and the value is the query argument array.</li>
520
+     *           </ul>
521
+     *           <h4>Example</h4>
522
+     * <pre><code>array(  
523
+     *     'field_id'              => 'taxonomy_custom_queries',
524
+     *     'title'                 => __( 'Custom Taxonomy Queries', 'admin-page-framework-demo' ),
525
+     *     'type'                  => 'taxonomy',
526
+     *     'description'           => 
527
+     *         array(
528
+     *             __( 'With the <code>query</code> argument array, you can customize how the terms should be retrieved.', 'admin-page-framework-demo' ),
529
+     *             sprintf( __( 'For the structure and the array key specifications, refer to the parameter section of the <a href="%1$s" target="_blank">get_term()</a> function.', 'admin-page-framework-demo' ), 'http://codex.wordpress.org/Function_Reference/get_terms#Parameters' ),
530
+     *         ),
531
+     *     
532
+     *     // (required)   Determines which taxonomies should be listed
533
+     *     'taxonomy_slugs'        => $aTaxnomies = get_taxonomies( '', 'names' ),    
534
+     *         
535
+     *     // (optional) This defines the default query argument. For the structure and supported arguments, see http://codex.wordpress.org/Function_Reference/get_terms#Parameters
536
+     *     'query'                 => array(
537
+     *         'depth'     => 2,
538
+     *         'orderby'   => 'term_id',       // accepts 'ID', 'term_id', or 'name'
539
+     *         'order'     => 'DESC',
540
+     *         // 'exclude'   => '1', // removes the 'Uncategorized' category.
541
+     *         // 'search' => 'PHP',   // the search keyward
542
+     *         // 'parent'    => 9,    // only show terms whose direct parent ID is 9.
543
+     *         // 'child_of'  => 8,    // only show child terms of the term ID of 8.
544
+     *     ),
545
+     *     // (optional) This allows to set a query argument for each taxonomy. 
546
+     *     // Note that each element will be merged with the above default 'query' argument array. 
547
+     *     // So unset keys here will be overridden by the default argument array above. 
548
+     *     'queries'               => array(
549
+     *         // taxonomy slug => query argument array
550
+     *         'category'  =>  array(
551
+     *             'depth'     => 2,
552
+     *             'orderby'   => 'term_id',  
553
+     *             'order'     => 'DESC',
554
+     *             'exclude'   => array( 1 ), 
555
+     *         ),
556
+     *         'post_tag'  => array(
557
+     *             'orderby'   => 'name',
558
+     *             'order'     => 'ASC',
559
+     *             // 'include'   => array( 4, ), // term ids
560
+     *         ),
561
+     *     ), 
562
+     * ),
563
+     * </code></pre>
564
+     *       </li>
565
+     *       <li>**posttype** - a post-type check list. This is a set of check boxes listing post type slugs.
566
+     *           <ul>
567
+     *               <li>**slugs_to_remove** - (optional, array) the post type slugs not to be listed. e.g.`array( 'revision', 'attachment', 'nav_menu_item' )`</li>
568
+     *               <li>**select_all_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select All` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
569
+     *               <li>**select_none_button** - [3.3.0+] (optional, array) pass `true` to enable the `Select None` button. To set a custom label, set the text such as `__( 'Check All', 'test-domain' )`. Default: `true`.</li>
570
+     *           </ul>
571
+     *       </li>
572
+     *       <li>**system** - [3.3.0+] a custom textara field that displays system information.
573
+     *           <ul>
574
+     *               <li>**data** - (optional, array) an associative array ta that holds the data to display.</li>
575
+     *               <li>**print_type** - [3.3.6+] (optional, integer) Indicates how the data array should be displayed. 1: readable array representation. 2. the output of the print_r() function. Default: `1`.</li>
576
+     *           </ul>
577
+     *       </li>
578
+     * </ul>    
579 579
      */     
580 580
     public function addSettingField( $asFieldset ) {
581 581
         if ( method_exists( $this->oForm, 'addField' ) ) {
@@ -660,28 +660,28 @@  discard block
 block discarded – undo
660 660
     }
661 661
     
662 662
     /**
663
-    * Sets the given message to be displayed in the next page load. 
664
-    * 
665
-    * This is used to inform users about the submitted input data, such as "Updated successfully." or "Problem occurred." etc. 
666
-    * and normally used in validation callback methods.
667
-    * 
668
-    * <h4>Example</h4>
669
-    * `
670
-    * if ( ! $bVerified ) {
671
-    *       $this->setFieldErrors( $aErrors );     
672
-    *       $this->setSettingNotice( 'There was an error in your input.' );
673
-    *       return $aOldPageOptions;
674
-    * }
675
-    * `
676
-    *
677
-    * @since        3.0.4     
678
-    * @access       public
679
-    * @param        string      $sMessage       the text message to be displayed.
680
-    * @param        string      $sType          (optional) the type of the message, either "error" or "updated"  is used.
681
-    * @param        array       $asAttributes   (optional) the tag attribute array applied to the message container HTML element. If a string is given, it is used as the ID attribute value.
682
-    * @param        boolean     $bOverride      (optional) If true, only one message will be shown in the next page load. false: do not override when there is a message of the same id. true: override the previous one.
683
-    * @return       void
684
-    */      
663
+     * Sets the given message to be displayed in the next page load. 
664
+     * 
665
+     * This is used to inform users about the submitted input data, such as "Updated successfully." or "Problem occurred." etc. 
666
+     * and normally used in validation callback methods.
667
+     * 
668
+     * <h4>Example</h4>
669
+     * `
670
+     * if ( ! $bVerified ) {
671
+     *       $this->setFieldErrors( $aErrors );     
672
+     *       $this->setSettingNotice( 'There was an error in your input.' );
673
+     *       return $aOldPageOptions;
674
+     * }
675
+     * `
676
+     *
677
+     * @since        3.0.4     
678
+     * @access       public
679
+     * @param        string      $sMessage       the text message to be displayed.
680
+     * @param        string      $sType          (optional) the type of the message, either "error" or "updated"  is used.
681
+     * @param        array       $asAttributes   (optional) the tag attribute array applied to the message container HTML element. If a string is given, it is used as the ID attribute value.
682
+     * @param        boolean     $bOverride      (optional) If true, only one message will be shown in the next page load. false: do not override when there is a message of the same id. true: override the previous one.
683
+     * @return       void
684
+     */      
685 685
     public function setSettingNotice( $sMessage, $sType='error', $asAttributes=array(), $bOverride=true ) {
686 686
         $this->oForm->setSubmitNotice(
687 687
             $sMessage,
Please login to merge, or discard this patch.
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
      * @return      array|string
44 44
      * @since       DEVVER
45 45
      */
46
-    public function getMessage( $sKey='' ) {
46
+    public function getMessage( $sKey = '' ) {
47 47
         return $this->oMsg->get( $sKey );
48 48
     }
49 49
        
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
      * @return      array       The array holing the queued items.
64 64
      * @internal
65 65
      */
66
-    public function enqueueStyles( $aSRCs, $_vArg2=null ) {} 
66
+    public function enqueueStyles( $aSRCs, $_vArg2 = null ) {} 
67 67
     
68 68
     /**
69 69
      * Enqueues a style of the given source.
@@ -83,7 +83,7 @@  discard block
 block discarded – undo
83 83
      * @return      string      The style handle ID. If the passed url is not a valid url string, an empty string will be returned.
84 84
      * @internal
85 85
      */
86
-    public function enqueueStyle( $sSRC, $_vArg2=null ) {}
86
+    public function enqueueStyle( $sSRC, $_vArg2 = null ) {}
87 87
     
88 88
     /**
89 89
      * Enqueues scripts by the given sources.
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
      * @return      array        The array holding the queued items.
105 105
      * @internal
106 106
      */    
107
-    public function enqueueScripts( $aSRCs, $_vArg2=null ) {}
107
+    public function enqueueScripts( $aSRCs, $_vArg2 = null ) {}
108 108
     /**
109 109
      * Enqueues a script by the given source.
110 110
      *  
@@ -136,7 +136,7 @@  discard block
 block discarded – undo
136 136
      * @return      string      The script handle ID. If the passed url is not a valid url string, an empty string will be returned.
137 137
      * @internal
138 138
      */    
139
-    public function enqueueScript( $sSRC, $_vArg2=null ) {}    
139
+    public function enqueueScript( $sSRC, $_vArg2 = null ) {}    
140 140
     
141 141
     /*
142 142
      * Help Pane
@@ -154,7 +154,7 @@  discard block
 block discarded – undo
154 154
      * @since       2.1.0
155 155
      * @remark      This method just adds the given text into the class property. The actual registration will be performed with the `replyToRegisterHelpTabTextForMetaBox()` method.
156 156
      */ 
157
-    public function addHelpText( $sHTMLContent, $sHTMLSidebarContent="" ) {
157
+    public function addHelpText( $sHTMLContent, $sHTMLSidebarContent = "" ) {
158 158
         if ( method_exists( $this->oHelpPane, '_addHelpText' ) ) {
159 159
             $this->oHelpPane->_addHelpText( $sHTMLContent, $sHTMLSidebarContent );
160 160
         }
@@ -190,7 +190,7 @@  discard block
 block discarded – undo
190 190
      */    
191 191
     public function addSettingSections( /* $aSection1, $aSection2=null, $_and_more=null */ ) {
192 192
         
193
-        foreach( func_get_args() as $_asSectionset ) { 
193
+        foreach ( func_get_args() as $_asSectionset ) { 
194 194
             $this->addSettingSection( $_asSectionset ); 
195 195
         }
196 196
         
@@ -261,7 +261,7 @@  discard block
 block discarded – undo
261 261
      */
262 262
     public function addSettingSection( $aSectionset ) {
263 263
         
264
-        if ( ! is_array( $aSectionset ) ) { 
264
+        if ( !is_array( $aSectionset ) ) { 
265 265
             return; 
266 266
         }
267 267
         
@@ -294,7 +294,7 @@  discard block
 block discarded – undo
294 294
     * @return       void
295 295
     */ 
296 296
     public function addSettingFields( /* $aField1, $aField2=null, $_and_more=null */ ) {
297
-        foreach( func_get_args() as $_aFieldset ) { 
297
+        foreach ( func_get_args() as $_aFieldset ) { 
298 298
             $this->addSettingField( $_aFieldset ); 
299 299
         }
300 300
     }    
@@ -671,7 +671,7 @@  discard block
 block discarded – undo
671 671
     * @param        boolean     $bOverride      (optional) If true, only one message will be shown in the next page load. false: do not override when there is a message of the same id. true: override the previous one.
672 672
     * @return       void
673 673
     */      
674
-    public function setSettingNotice( $sMessage, $sType='error', $asAttributes=array(), $bOverride=true ) {
674
+    public function setSettingNotice( $sMessage, $sType = 'error', $asAttributes = array(), $bOverride = true ) {
675 675
         $this->oForm->setSubmitNotice(
676 676
             $sMessage,
677 677
             $sType,
@@ -690,7 +690,7 @@  discard block
 block discarded – undo
690 690
      * @param       string      $sType If empty, the method will check if a message exists in all types. Otherwise, it checks the existence of a message of the specified type.
691 691
      * @return      boolean     True if a setting notice is set; otherwise, false.
692 692
      */
693
-    public function hasSettingNotice( $sType='' ) {
693
+    public function hasSettingNotice( $sType = '' ) {
694 694
         return $this->oForm->hasSubmitNotice( $sType );
695 695
     }
696 696
 
Please login to merge, or discard this patch.
Braces   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
      */    
170 170
     public function addSettingSections( /* $aSection1, $aSection2=null, $_and_more=null */ ) {
171 171
         
172
-        foreach( func_get_args() as $_asSectionset ) { 
172
+        foreach( func_get_args() as $_asSectionset ) {
173 173
             $this->addSettingSection( $_asSectionset ); 
174 174
         }
175 175
         
@@ -238,7 +238,7 @@  discard block
 block discarded – undo
238 238
      */
239 239
     public function addSettingSection( $aSectionset ) {
240 240
         
241
-        if ( ! is_array( $aSectionset ) ) { 
241
+        if ( ! is_array( $aSectionset ) ) {
242 242
             return; 
243 243
         }
244 244
         
@@ -271,7 +271,7 @@  discard block
 block discarded – undo
271 271
     * @return       void
272 272
     */ 
273 273
     public function addSettingFields( /* $aField1, $aField2=null, $_and_more=null */ ) {
274
-        foreach( func_get_args() as $_aFieldset ) { 
274
+        foreach( func_get_args() as $_aFieldset ) {
275 275
             $this->addSettingField( $_aFieldset ); 
276 276
         }
277 277
     }    
Please login to merge, or discard this patch.
development/factory/_common/_abstract/AdminPageFramework_Factory_Model.php 3 patches
Doc Comments   -2 removed lines patch added patch discarded remove patch
@@ -299,8 +299,6 @@
 block discarded – undo
299 299
      * @since       DEVVER      Changed back the visibility scope to protected as there is the `getFieldErrors()` public method.
300 300
      * @access      protected
301 301
      * @internal
302
-     * @param       string      $sID        deprecated
303
-     * @param       boolean     $bDelete    whether or not the transient should be deleted after retrieving it. 
304 302
      * @return      array
305 303
      * @deprecated  DEVVER      Use `getFieldErrors()` instead. Kept for backward compatibility.
306 304
      */
Please login to merge, or discard this patch.
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
         
33 33
         add_filter(
34 34
             // 'field_types_admin_page_framework',
35
-            'field_types_' . $oProp->sClassName,
35
+            'field_types_'.$oProp->sClassName,
36 36
             array( $this, '_replyToFilterFieldTypeDefinitions' )
37 37
         );
38 38
         
@@ -65,7 +65,7 @@  discard block
 block discarded – undo
65 65
             'title'      => null,
66 66
             'help_aside' => null,
67 67
         );
68
-        if ( ! $aFieldset[ 'help' ] ) {
68
+        if ( !$aFieldset[ 'help' ] ) {
69 69
             return;
70 70
         }
71 71
         $this->oHelpPane->_addHelpTextForFormFields( 
@@ -85,9 +85,9 @@  discard block
 block discarded – undo
85 85
     public function _replyToFilterFieldTypeDefinitions( $aFieldTypeDefinitions ) {
86 86
         
87 87
         // Not triggering `__call()` as the filter is fired manually in the form class.
88
-        if ( method_exists( $this, 'field_types_' . $this->oProp->sClassName ) ) {
88
+        if ( method_exists( $this, 'field_types_'.$this->oProp->sClassName ) ) {
89 89
             return call_user_func_array(
90
-                array( $this, 'field_types_' . $this->oProp->sClassName ),
90
+                array( $this, 'field_types_'.$this->oProp->sClassName ),
91 91
                 array( $aFieldTypeDefinitions )
92 92
             );
93 93
         }
@@ -108,7 +108,7 @@  discard block
 block discarded – undo
108 108
     public function _replyToModifySectionsets( $aSectionsets ) {    
109 109
         
110 110
         return $this->oUtil->addAndApplyFilter( 
111
-            $this,  // caller factory object
111
+            $this, // caller factory object
112 112
             "sections_{$this->oProp->sClassName}", 
113 113
             $aSectionsets
114 114
         );
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
     public function _replyToModifyFieldsets( $aFieldsets, $aSectionsets ) {
129 129
 
130 130
         // Apply filters to added fieldsets
131
-        foreach( $aFieldsets as $_sSectionPath => $_aFields ) {
131
+        foreach ( $aFieldsets as $_sSectionPath => $_aFields ) {
132 132
             $_aSectionPath  = explode( '|', $_sSectionPath );
133 133
             $_sFilterSuffix = implode( '_', $_aSectionPath );
134 134
             $aFieldsets[ $_sSectionPath ] = $this->oUtil->addAndApplyFilter(
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
                 $_aFields
138 138
             ); 
139 139
         }
140
-        $aFieldsets =  $this->oUtil->addAndApplyFilter( 
140
+        $aFieldsets = $this->oUtil->addAndApplyFilter( 
141 141
             $this,
142 142
             "fields_{$this->oProp->sClassName}",
143 143
             $aFieldsets
@@ -177,12 +177,12 @@  discard block
 block discarded – undo
177 177
      */
178 178
     public function _replyToModifyFieldsetDefinition( $aFieldset /*, $aSectionsets */ ) {
179 179
         
180
-        $_sFieldPart    = '_' . implode( '_', $aFieldset[ '_field_path_array' ] );
180
+        $_sFieldPart    = '_'.implode( '_', $aFieldset[ '_field_path_array' ] );
181 181
         $_sSectionPart  = implode( '_', $aFieldset[ '_section_path_array' ] );
182 182
         $_sSectionPart  = $this->oUtil->getAOrB(
183 183
             '_default' === $_sSectionPart,
184 184
             '',
185
-            '_' . $_sSectionPart
185
+            '_'.$_sSectionPart
186 186
         );
187 187
         return $this->oUtil->addAndApplyFilter(
188 188
             $this,
@@ -264,7 +264,7 @@  discard block
 block discarded – undo
264 264
     public function _replyToGetSavedFormData() {
265 265
         return $this->oUtil->addAndApplyFilter(
266 266
             $this, // the caller factory object
267
-            'options_' . $this->oProp->sClassName,
267
+            'options_'.$this->oProp->sClassName,
268 268
             $this->oProp->aOptions      // subject value to be filtered
269 269
         );
270 270
     }
@@ -342,7 +342,7 @@  discard block
 block discarded – undo
342 342
          * An alias of `_setLastInputs()`.
343 343
          * @deprecated      3.7.0
344 344
          */
345
-        public function _setLastInput( $aLastInputs )  {
345
+        public function _setLastInput( $aLastInputs ) {
346 346
             return $this->setLastInputs( $aLastInputs );
347 347
         }    
348 348
 
Please login to merge, or discard this patch.
Braces   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
      * but it requires to call the setUp() method in the overridden method so it's not that useful.
46 46
      * @internal
47 47
      */
48
-    protected function _setUp() { 
48
+    protected function _setUp() {
49 49
         $this->setUp();
50 50
     }    
51 51
     
@@ -98,7 +98,7 @@  discard block
 block discarded – undo
98 98
      * @since       DEVVER
99 99
      * @return      array       The modified sectionsets definition array.
100 100
      */    
101
-    public function _replyToModifySectionsets( $aSectionsets ) {    
101
+    public function _replyToModifySectionsets( $aSectionsets ) {
102 102
         
103 103
         return $this->oUtil->addAndApplyFilter( 
104 104
             $this,  // caller factory object
@@ -201,7 +201,7 @@  discard block
 block discarded – undo
201 201
      */
202 202
     public function _replyToFormatFieldsetDefinition( $aFieldset, $aSectionsets ) {
203 203
 
204
-        if ( empty( $aFieldset ) ) { 
204
+        if ( empty( $aFieldset ) ) {
205 205
             return $aFieldset; 
206 206
         }
207 207
         return $aFieldset;
@@ -334,7 +334,7 @@  discard block
 block discarded – undo
334 334
          * An alias of `_setLastInputs()`.
335 335
          * @deprecated      DEVVER
336 336
          */
337
-        public function _setLastInput( $aLastInputs )  {
337
+        public function _setLastInput( $aLastInputs ) {
338 338
             return $this->setLastInputs( $aLastInputs );
339 339
         }    
340 340
 
Please login to merge, or discard this patch.
factory/_common/form/_model/AdminPageFramework_Form_Model___LastInput.php 3 patches
Doc Comments   -1 removed lines patch added patch discarded remove patch
@@ -110,7 +110,6 @@
 block discarded – undo
110 110
      * Retrieves the settings error array set by the user in the validation callback.
111 111
      * 
112 112
      * @since       3.7.8
113
-     * @param       boolean     $bDelete    whether or not the transient should be deleted after retrieving it. 
114 113
      * @return      array
115 114
      */
116 115
     public function get() {
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
             $_sPageSlug = $this->getElement( $_GET, 'page', '' );
57 57
             $_sTabSlug  = $this->getElement( $_GET, 'tab', '' );            
58 58
             $_sUserID   = get_current_user_id();
59
-            return "apf_li_" . md5( 
59
+            return "apf_li_".md5( 
60 60
                 $_sPageNow 
61 61
                 . $_sPageSlug
62 62
                 . $_sTabSlug
@@ -94,13 +94,13 @@  discard block
 block discarded – undo
94 94
          * @return      void
95 95
          */ 
96 96
         public function _replyToSave() {
97
-            if ( ! isset( self::$_aLastInputs ) ) { 
97
+            if ( !isset( self::$_aLastInputs ) ) { 
98 98
                 return; 
99 99
             }
100 100
             $this->setTransient( 
101 101
                 $this->sTransientKey,
102 102
                 self::$_aLastInputs, 
103
-                60*60     // store it for 1 hour 
103
+                60 * 60     // store it for 1 hour 
104 104
             );    
105 105
         }    
106 106
     
@@ -120,9 +120,9 @@  discard block
 block discarded – undo
120 120
             $_aLastInputs = self::$_aCaches[ $this->sTransientKey ];
121 121
         } else {
122 122
             $_aLastInputs = $this->getTransient( $this->sTransientKey );
123
-            self::$_aCaches[ $this->sTransientKey ]  = $_aLastInputs;
123
+            self::$_aCaches[ $this->sTransientKey ] = $_aLastInputs;
124 124
             if ( false !== $_aLastInputs ) {
125
-                $this->delete();    // deletes at the end of the script.
125
+                $this->delete(); // deletes at the end of the script.
126 126
             }
127 127
         }        
128 128
         
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -94,7 +94,7 @@
 block discarded – undo
94 94
          * @return      void
95 95
          */ 
96 96
         public function _replyToSave() {
97
-            if ( ! isset( self::$_aLastInputs ) ) { 
97
+            if ( ! isset( self::$_aLastInputs ) ) {
98 98
                 return; 
99 99
             }
100 100
             $this->setTransient( 
Please login to merge, or discard this patch.
formatter/AdminPageFramework_Form_Model___Format_CollapsibleSection.php 3 patches
Doc Comments   +2 added lines patch added patch discarded remove patch
@@ -77,6 +77,8 @@
 block discarded – undo
77 77
     }
78 78
         /**
79 79
          * @since       3.6.0
80
+         * @param boolean $abCollapsible
81
+         * @param string $sTitle
80 82
          * @return      array
81 83
          */
82 84
         private function _getArguments( $abCollapsible, $sTitle, array $aSection ) {
Please login to merge, or discard this patch.
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -23,12 +23,12 @@  discard block
 block discarded – undo
23 23
      * @since       3.6.0       Moved from `AdminPageFramework_FormDefinition`.
24 24
      */
25 25
     static public $aStructure = array(
26
-        'title'                     => null,        // (string)  the section title will be assigned by default in the section formatting method.
27
-        'is_collapsed'              => true,        // (boolean) whether it is already collapsed or expanded
28
-        'toggle_all_button'         => null,        // (boolean|string|array) the position of where to display the toggle-all button that toggles the folding state of all collapsible sections. Accepts the following values. 'top-right', 'top-left', 'bottom-right', 'bottom-left'. If true is passed, the default 'top-right' will be used. To not to display, do not set any or pass `false` or `null`.
29
-        'collapse_others_on_expand' => true,        // (boolean) whether the other collapsible sections should be folded when the section is unfolded.
30
-        'container'                 => 'sections',  // (string) the container element that collapsible styling gets applied to. Either 'sections' or 'section' is accepted.
31
-        'type'                      => 'box',       // 3.7.0+  (string)  supported types 'box', 'button' Default: `box`. The `button` type is only supported when the `container` argument is `section`.
26
+        'title'                     => null, // (string)  the section title will be assigned by default in the section formatting method.
27
+        'is_collapsed'              => true, // (boolean) whether it is already collapsed or expanded
28
+        'toggle_all_button'         => null, // (boolean|string|array) the position of where to display the toggle-all button that toggles the folding state of all collapsible sections. Accepts the following values. 'top-right', 'top-left', 'bottom-right', 'bottom-left'. If true is passed, the default 'top-right' will be used. To not to display, do not set any or pass `false` or `null`.
29
+        'collapse_others_on_expand' => true, // (boolean) whether the other collapsible sections should be folded when the section is unfolded.
30
+        'container'                 => 'sections', // (string) the container element that collapsible styling gets applied to. Either 'sections' or 'section' is accepted.
31
+        'type'                      => 'box', // 3.7.0+  (string)  supported types 'box', 'button' Default: `box`. The `button` type is only supported when the `container` argument is `section`.
32 32
     );   
33 33
     
34 34
     public $abCollapsible = false;
@@ -41,7 +41,7 @@  discard block
 block discarded – undo
41 41
      * @remark      The framework will not pass this parameter when formatting a section definition array.
42 42
      * It will be passed when the framework is rendering a form table to generate collapsible elements.
43 43
      */
44
-    public $aSection      = array();
44
+    public $aSection = array();
45 45
     
46 46
     /**
47 47
      * Sets up properties.
@@ -84,14 +84,14 @@  discard block
 block discarded – undo
84 84
             
85 85
             $_aCollapsible = $this->getAsArray( $this->abCollapsible ) + array(
86 86
                 'title'     => $sTitle,
87
-            ) +  self::$aStructure;
87
+            ) + self::$aStructure;
88 88
             
89 89
             $_aCollapsible[ 'toggle_all_button' ] = implode( 
90 90
                 ',', 
91 91
                 $this->getAsArray( $_aCollapsible[ 'toggle_all_button' ] ) 
92 92
             );
93 93
             
94
-            if ( ! empty( $aSection ) ) {
94
+            if ( !empty( $aSection ) ) {
95 95
                 $_aCollapsible[ 'toggle_all_button' ] = $this->_getToggleAllButtonArgument( 
96 96
                     $_aCollapsible[ 'toggle_all_button' ], 
97 97
                     $aSection
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
              */
116 116
             private function _getToggleAllButtonArgument( $sToggleAll, array $aSection ) {
117 117
                 
118
-                if ( ! $aSection[ 'repeatable' ] ) {            
118
+                if ( !$aSection[ 'repeatable' ] ) {            
119 119
                     return $sToggleAll;
120 120
                 }
121 121
                 
@@ -125,13 +125,13 @@  discard block
 block discarded – undo
125 125
                 }
126 126
                 
127 127
                 // Disable the toggle all button for middle sub-sections in repeatable sections.
128
-                if ( ! $aSection[ '_is_first_index' ] && ! $aSection[ '_is_last_index' ] ) {
128
+                if ( !$aSection[ '_is_first_index' ] && !$aSection[ '_is_last_index' ] ) {
129 129
                     return 0;
130 130
                 }            
131 131
                 
132 132
                 $_aToggleAll = $this->getAOrB(
133
-                    true === $sToggleAll || 1 ===  $sToggleAll, // evaluate
134
-                    array( 'top-right', 'bottom-right' ),   // if true
133
+                    true === $sToggleAll || 1 === $sToggleAll, // evaluate
134
+                    array( 'top-right', 'bottom-right' ), // if true
135 135
                     explode( ',', $sToggleAll ) // if false
136 136
                 );            
137 137
                 $_aToggleAll = $this->getAOrB(
Please login to merge, or discard this patch.
Braces   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -114,7 +114,7 @@
 block discarded – undo
114 114
              */
115 115
             private function _getToggleAllButtonArgument( $sToggleAll, array $aSection ) {
116 116
                 
117
-                if ( ! $aSection[ 'repeatable' ] ) {            
117
+                if ( ! $aSection[ 'repeatable' ] ) {
118 118
                     return $sToggleAll;
119 119
                 }
120 120
                 
Please login to merge, or discard this patch.