Completed
Branch dev (f35023)
by
unknown
03:44
created
_view/script/AdminPageFramework_Form_View___Script_RepeatableSection.php 1 patch
Indentation   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -513,7 +513,7 @@
 block discarded – undo
513 513
         static private function ___getRemoveButtonAttributes( $sContainerTagID, $oMsg, $iSectionCount ) {
514 514
             return array(
515 515
                 'class'     => 'repeatable-section-remove-button button-secondary '
516
-                               . 'repeatable-section-button button button-large',
516
+                                . 'repeatable-section-button button button-large',
517 517
                 'title'     => $oMsg->get( 'remove_section' ),
518 518
                 'style'     => $iSectionCount <= 1
519 519
                     ? 'display:none'
Please login to merge, or discard this patch.
factory/_common/_abstract/AdminPageFramework_Factory_Controller.php 1 patch
Indentation   +187 added lines, -187 removed lines patch added patch discarded remove patch
@@ -306,18 +306,18 @@  discard block
 block discarded – undo
306 306
     }     
307 307
         
308 308
     /**
309
-    * Adds form fields.
310
-    * 
311
-    * 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.
312
-    * 
313
-    * @since        2.0.0
314
-    * @since        3.5.3       Removed the parameter declarations as they are caught with the func_get_args().
315
-    * @remark       Accepts variadic parameters; the number of accepted parameters are not limited to three.
316
-    * @param        array       the field definition array.
317
-    * @param        array       (optional) another field array.
318
-    * @param        array       (optional) add more field arrays to the next parameters as many as necessary.
319
-    * @return       void
320
-    */ 
309
+     * Adds form fields.
310
+     * 
311
+     * 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.
312
+     * 
313
+     * @since        2.0.0
314
+     * @since        3.5.3       Removed the parameter declarations as they are caught with the func_get_args().
315
+     * @remark       Accepts variadic parameters; the number of accepted parameters are not limited to three.
316
+     * @param        array       the field definition array.
317
+     * @param        array       (optional) another field array.
318
+     * @param        array       (optional) add more field arrays to the next parameters as many as necessary.
319
+     * @return       void
320
+     */ 
321 321
     public function addSettingFields( /* $aField1, $aField2=null, $_and_more=null */ ) {
322 322
         foreach( func_get_args() as $_aFieldset ) { 
323 323
             $this->addSettingField( $_aFieldset ); 
@@ -348,57 +348,57 @@  discard block
 block discarded – undo
348 348
      * @return       void
349 349
      * @remark       The $oForm property should be created in each extended class.
350 350
      * @param        array|string       $asField        A field definition array or a string of the target section id.
351
-    * <h4>Built-in Field Types</h4>
352
-    * <ul>
353
-    *       <li>[text](./class-AdminPageFramework_FieldType_text.html) - a normal field to enter short text input.</li>
354
-    *       <li>[password](./class-AdminPageFramework_FieldType_text.html) - a masked text input field.</li>
355
-    *       <li>[textarea](./class-AdminPageFramework_FieldType_textarea.html) - a text input field with multiple lines. It supports rich text editors.</li>
356
-    *       <li>[radio](./class-AdminPageFramework_FieldType_radio.html) - a set of radio buttons that lets the user pick an option.</li>
357
-    *       <li>[checkbox](./class-AdminPageFramework_FieldType_checkbox.html) - a check box that lets the user enable/disable an item.</li>
358
-    *       <li>[select](./class-AdminPageFramework_FieldType_select.html) - a drop-down list that lest the user pick one or more item(s) from a list.</li>
359
-    *       <li>[hidden](./class-AdminPageFramework_FieldType_hidden.html) - a field with invisible input values.</li>
360
-    *       <li>[file](./class-AdminPageFramework_FieldType_file.html) - a file uploader that lets the user upload files.</li>
361
-    *       <li>[image](./class-AdminPageFramework_FieldType_image.html) - a text field with an image uploader that lets the user set the image URL.</li>
362
-    *       <li>[media](./class-AdminPageFramework_FieldType_media.html) - a text field with a media uploader that lets the user set the file URL.</li>
363
-    *       <li>[color](./class-AdminPageFramework_FieldType_color.html) - a text field with a color picker.</li>
364
-    *       <li>[submit](./class-AdminPageFramework_FieldType_submit.html) - a submit button that lets the user send the form.</li>
365
-    *       <li>[export](./class-AdminPageFramework_FieldType_export.html) - a custom submit field that lets the user export stored data.</li>
366
-    *       <li>[import](./class-AdminPageFramework_FieldType_import.html) - a custom combination field of file and submit fields that let the user import data.</li>
367
-    *       <li>[posttype](./class-AdminPageFramework_FieldType_posttype.html) - a check-list of post types enabled on the site.</li>
368
-    *       <li>[taxonomy](./class-AdminPageFramework_FieldType_taxonomy.html) - a set of check-lists of taxonomies enabled on the site in a tabbed box.</li>
369
-    *       <li>[size](./class-AdminPageFramework_FieldType_size.html) - a combination field of the text and the select fields that let the user set sizes with a selectable unit.</li>
370
-    *       <li>[section_title](./class-AdminPageFramework_FieldType_section_title.html) - [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>
371
-    *       <li>[system](./class-AdminPageFramework_FieldType_system.html) - [3.3.0+] a custom text area field that displays the system information including the PHP settings, the framework version, MySQL version etc.</li>
372
-    *       <li>[inline_mixed](./class-AdminPageFramework_FieldType_inline_mixed.html) - [3.8.0+] a field that include inner fields with different field types. </li>
373
-    * </ul>
374
-    * <h4>Field Definition Arguments</h4>
375
-    * <ul>
376
-    *       <li>**field_id** - (required, string) the field ID. Avoid using non-alphabetic characters except underscore and numbers.</li>
377
-    *       <li>**type** - (optional, string) the type of the field. The supported types are listed below. When creating nested fields, this argument can be omitted.</li>
378
-    *       <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>
379
-    *       <li>**title** - (optional, string) the title of the section.</li>
380
-    *       <li>**description** - (optional, string) the description of the field which is inserted into the after the input field tag.</li>
381
-    *       <li>**tip** - (optional, string) the tip for the field which is displayed when the mouse is hovered over the field title.</li>
382
-    *       <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>
383
-    *       <li>**error_message** - (optional, string) the error message to display above the input field.</li>
384
-    *       <li>**before_field** - (optional, string) the HTML string to insert before the input field output.</li>
385
-    *       <li>**after_field** - (optional, string) the HTML string to insert after the input field output.</li>
386
-    *       <li>**if** - (optional, boolean) if the passed value is false, the section will not be registered.</li>
387
-    *       <li>**order** - (optional, integer) the order number of the section. The higher the number is, the lower the position it gets.</li>
388
-    *       <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>
389
-    *       <li>**default** - (optional, string|array) the default value(s) assigned to the input tag's value attribute.</li>
390
-    *       <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>
391
-    *       <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>
392
-    *       <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>
393
-    *       <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>
394
-    *       <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> 
395
-    *       <li>**help** - (optional, string) the help description added to the contextual help tab.</li>
396
-    *       <li>**help_aside** - (optional, string) the additional help description for the side bar of the contextual help tab.</li>
397
-    *       <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.
398
-    *           <h5>Repeatable Fields Setting Array</h5>
399
-    *           <ul>
400
-    *                 <li>**max** - the allowed maximum number of fields to be repeated.</li>
401
-    *                 <li>**min** - the allowed minimum number of fields to be repeated.</li>
351
+     * <h4>Built-in Field Types</h4>
352
+     * <ul>
353
+     *       <li>[text](./class-AdminPageFramework_FieldType_text.html) - a normal field to enter short text input.</li>
354
+     *       <li>[password](./class-AdminPageFramework_FieldType_text.html) - a masked text input field.</li>
355
+     *       <li>[textarea](./class-AdminPageFramework_FieldType_textarea.html) - a text input field with multiple lines. It supports rich text editors.</li>
356
+     *       <li>[radio](./class-AdminPageFramework_FieldType_radio.html) - a set of radio buttons that lets the user pick an option.</li>
357
+     *       <li>[checkbox](./class-AdminPageFramework_FieldType_checkbox.html) - a check box that lets the user enable/disable an item.</li>
358
+     *       <li>[select](./class-AdminPageFramework_FieldType_select.html) - a drop-down list that lest the user pick one or more item(s) from a list.</li>
359
+     *       <li>[hidden](./class-AdminPageFramework_FieldType_hidden.html) - a field with invisible input values.</li>
360
+     *       <li>[file](./class-AdminPageFramework_FieldType_file.html) - a file uploader that lets the user upload files.</li>
361
+     *       <li>[image](./class-AdminPageFramework_FieldType_image.html) - a text field with an image uploader that lets the user set the image URL.</li>
362
+     *       <li>[media](./class-AdminPageFramework_FieldType_media.html) - a text field with a media uploader that lets the user set the file URL.</li>
363
+     *       <li>[color](./class-AdminPageFramework_FieldType_color.html) - a text field with a color picker.</li>
364
+     *       <li>[submit](./class-AdminPageFramework_FieldType_submit.html) - a submit button that lets the user send the form.</li>
365
+     *       <li>[export](./class-AdminPageFramework_FieldType_export.html) - a custom submit field that lets the user export stored data.</li>
366
+     *       <li>[import](./class-AdminPageFramework_FieldType_import.html) - a custom combination field of file and submit fields that let the user import data.</li>
367
+     *       <li>[posttype](./class-AdminPageFramework_FieldType_posttype.html) - a check-list of post types enabled on the site.</li>
368
+     *       <li>[taxonomy](./class-AdminPageFramework_FieldType_taxonomy.html) - a set of check-lists of taxonomies enabled on the site in a tabbed box.</li>
369
+     *       <li>[size](./class-AdminPageFramework_FieldType_size.html) - a combination field of the text and the select fields that let the user set sizes with a selectable unit.</li>
370
+     *       <li>[section_title](./class-AdminPageFramework_FieldType_section_title.html) - [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>
371
+     *       <li>[system](./class-AdminPageFramework_FieldType_system.html) - [3.3.0+] a custom text area field that displays the system information including the PHP settings, the framework version, MySQL version etc.</li>
372
+     *       <li>[inline_mixed](./class-AdminPageFramework_FieldType_inline_mixed.html) - [3.8.0+] a field that include inner fields with different field types. </li>
373
+     * </ul>
374
+     * <h4>Field Definition Arguments</h4>
375
+     * <ul>
376
+     *       <li>**field_id** - (required, string) the field ID. Avoid using non-alphabetic characters except underscore and numbers.</li>
377
+     *       <li>**type** - (optional, string) the type of the field. The supported types are listed below. When creating nested fields, this argument can be omitted.</li>
378
+     *       <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>
379
+     *       <li>**title** - (optional, string) the title of the section.</li>
380
+     *       <li>**description** - (optional, string) the description of the field which is inserted into the after the input field tag.</li>
381
+     *       <li>**tip** - (optional, string) the tip for the field which is displayed when the mouse is hovered over the field title.</li>
382
+     *       <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>
383
+     *       <li>**error_message** - (optional, string) the error message to display above the input field.</li>
384
+     *       <li>**before_field** - (optional, string) the HTML string to insert before the input field output.</li>
385
+     *       <li>**after_field** - (optional, string) the HTML string to insert after the input field output.</li>
386
+     *       <li>**if** - (optional, boolean) if the passed value is false, the section will not be registered.</li>
387
+     *       <li>**order** - (optional, integer) the order number of the section. The higher the number is, the lower the position it gets.</li>
388
+     *       <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>
389
+     *       <li>**default** - (optional, string|array) the default value(s) assigned to the input tag's value attribute.</li>
390
+     *       <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>
391
+     *       <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>
392
+     *       <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>
393
+     *       <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>
394
+     *       <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> 
395
+     *       <li>**help** - (optional, string) the help description added to the contextual help tab.</li>
396
+     *       <li>**help_aside** - (optional, string) the additional help description for the side bar of the contextual help tab.</li>
397
+     *       <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.
398
+     *           <h5>Repeatable Fields Setting Array</h5>
399
+     *           <ul>
400
+     *                 <li>**max** - the allowed maximum number of fields to be repeated.</li>
401
+     *                 <li>**min** - the allowed minimum number of fields to be repeated.</li>
402 402
      *                <li>**disabled** - (optional, boolean|array) [3.8.13+]
403 403
      *                    <ul>
404 404
      *                        <li>**label** - (optional, string) the message to show when the user clicks on the `Add` repeatable button.</li>
@@ -407,108 +407,108 @@  discard block
 block discarded – undo
407 407
      *                        <li>**box_width** - (optional, integer) the height of the modal window that displays the message. Default: 100.</li>
408 408
      *                    <ul>
409 409
      *                </li>
410
-    *           </ul>
411
-    *       </li>
412
-    *       <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.
413
-    *       <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.
414
-    *           <ul>
415
-    *               <li>**fieldrow** - the `td` tag element containing the field output.</li>
416
-    *               <li>**fieldset** - the `fieldset` tag element containing the field output.</li>
417
-    *               <li>**fields** - the `div` tag element containing the sub-fields and the main field.</li>
418
-    *               <li>**field** - the `div` tag element containing each field.</li>
419
-    *           </ul>
420
-    *       </li>
421
-    *       <li>**show_title_column** - [3.0.0+] (optional, boolean) If true, the field title column will be omitted from the output.</li>
422
-    *       <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>
423
-    *       <li>**save** - [3.6.0+] (optional, boolean) If `false`, the field value will not be saved. Default: `true`</li>
424
-    *       <li>**content** - (optional, string|array) [3.6.1+] a custom section output. [3.8.0+] Supports an array to be passed for nested and inline-mixed fields. If an array holding field definitions is set, those fields will be nested.
425
-    *           <h4>Example</h4>
426
-    * <pre><code>
427
-    *   $this->addSettingFields(
428
-    *       'my_section_id', // the target section ID - pass dimensional keys of the section
429
-    *       array(
430
-    *           'field_id'      => 'Y',
431
-    *           'title'         => __( 'Y', 'admin-page-framework-loader' ),
432
-    *           'description'   => __( 'By passing an array of field definition to the <code>content</code> argument, you can nest fields.', 'admin-page-framework-loader' )
433
-    *               . ' ' . __( 'Also the <code>type</code> argument can be omitted.', 'admin-page-framework-loader' ),
434
-    *           'content'       => array(
435
-    *               array(
436
-    *                   'field_id'      => 'i',
437
-    *                   'title'         => __( 'i', 'admin-page-framework-loader' ),                    
438
-    *                   'type'          => 'textarea',
439
-    *               ),
440
-    *               array(
441
-    *                   'field_id'      => 'ii',
442
-    *                   'title'         => __( 'ii', 'admin-page-framework-loader' ),                    
443
-    *                   'type'          => 'color',                    
444
-    *               ),
445
-    *               array(
446
-    *                   'field_id'      => 'iii',
447
-    *                   'title'         => __( 'iii', 'admin-page-framework-loader' ),
448
-    *                   'repeatable'    => true,
449
-    *                   'sortable'      => true,
450
-    *                   'content'       => array(
451
-    *                       array(
452
-    *                           'field_id'      => 'a',
453
-    *                           'title'         => __( 'a', 'admin-page-framework-loader' ),                    
454
-    *                           'type'          => 'image',
455
-    *                           'attributes'    => array(
456
-    *                               'preview' => array(
457
-    *                                   'style' => 'max-width: 200px;',
458
-    *                               ),
459
-    *                           ),                                
460
-    *                       ),
461
-    *                       array(
462
-    *                           'field_id'      => 'b',
463
-    *                           'title'         => __( 'b', 'admin-page-framework-loader' ),
464
-    *                           'content'       => array(
465
-    *                               array(
466
-    *                                   'field_id'      => 'first',
467
-    *                                   'title'         => __( '1st', 'admin-page-framework-loader' ),                    
468
-    *                                   'type'          => 'color',
469
-    *                                   'repeatable'    => true,
470
-    *                                   'sortable'      => true,
471
-    *                               ),                                
472
-    *                               array(
473
-    *                                   'field_id'      => 'second',
474
-    *                                   'title'         => __( '2nd', 'admin-page-framework-loader' ),                    
475
-    *                                   'type'          => 'size',
476
-    *                               ),
477
-    *                               array(
478
-    *                                   'field_id'      => 'third',
479
-    *                                   'title'         => __( '3rd', 'admin-page-framework-loader' ),                    
480
-    *                                   'type'          => 'select',
481
-    *                                   'label'         => array(
482
-    *                                       'x' => 'X',
483
-    *                                       'y' => 'Y',
484
-    *                                       'z' => 'Z',                                        
485
-    *                                   ),
486
-    *                               ),                                    
487
-    *                           ),
488
-    *                           // 'description'   => '',
489
-    *                       ),                            
490
-    *                       array(
491
-    *                           'field_id'      => 'c',
492
-    *                           'title'         => __( 'c', 'admin-page-framework-loader' ),                    
493
-    *                           'type'          => 'radio',                    
494
-    *                           'label'         => array(
495
-    *                               'a' => __( 'Apple', 'admin-page-framework-loader' ),
496
-    *                               'b' => __( 'Banana', 'admin-page-framework-loader' ),
497
-    *                               'c' => __( 'Cherry', 'admin-page-framework-loader' ),
498
-    *                           ),
499
-    *                           'default'       => 'b',
500
-    *                       ),                        
501
-    *                   )
502
-    *               ),                    
503
-    *           ),
504
-    *       )
505
-    *   );
506
-    * </code></pre>
507
-    *       </li>
508
-    *       <li>**placement** - [3.8.0+] (optional, string) Specifies where the field is rendered. Either `normal` `section_title` or `field_title` is accepted. `field_title` can only be used by nested fields defined in the `content` argument.  Default: `normal`</li>
509
-    *       <li>**show_debug_info** - (optional, boolean) [3.8.8+] Whether to show debug information such as field definition tool-tips. Default: `true`.</li>
510
-    * </ul>
511
-    */
410
+     *           </ul>
411
+     *       </li>
412
+     *       <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.
413
+     *       <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.
414
+     *           <ul>
415
+     *               <li>**fieldrow** - the `td` tag element containing the field output.</li>
416
+     *               <li>**fieldset** - the `fieldset` tag element containing the field output.</li>
417
+     *               <li>**fields** - the `div` tag element containing the sub-fields and the main field.</li>
418
+     *               <li>**field** - the `div` tag element containing each field.</li>
419
+     *           </ul>
420
+     *       </li>
421
+     *       <li>**show_title_column** - [3.0.0+] (optional, boolean) If true, the field title column will be omitted from the output.</li>
422
+     *       <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>
423
+     *       <li>**save** - [3.6.0+] (optional, boolean) If `false`, the field value will not be saved. Default: `true`</li>
424
+     *       <li>**content** - (optional, string|array) [3.6.1+] a custom section output. [3.8.0+] Supports an array to be passed for nested and inline-mixed fields. If an array holding field definitions is set, those fields will be nested.
425
+     *           <h4>Example</h4>
426
+     * <pre><code>
427
+     *   $this->addSettingFields(
428
+     *       'my_section_id', // the target section ID - pass dimensional keys of the section
429
+     *       array(
430
+     *           'field_id'      => 'Y',
431
+     *           'title'         => __( 'Y', 'admin-page-framework-loader' ),
432
+     *           'description'   => __( 'By passing an array of field definition to the <code>content</code> argument, you can nest fields.', 'admin-page-framework-loader' )
433
+     *               . ' ' . __( 'Also the <code>type</code> argument can be omitted.', 'admin-page-framework-loader' ),
434
+     *           'content'       => array(
435
+     *               array(
436
+     *                   'field_id'      => 'i',
437
+     *                   'title'         => __( 'i', 'admin-page-framework-loader' ),                    
438
+     *                   'type'          => 'textarea',
439
+     *               ),
440
+     *               array(
441
+     *                   'field_id'      => 'ii',
442
+     *                   'title'         => __( 'ii', 'admin-page-framework-loader' ),                    
443
+     *                   'type'          => 'color',                    
444
+     *               ),
445
+     *               array(
446
+     *                   'field_id'      => 'iii',
447
+     *                   'title'         => __( 'iii', 'admin-page-framework-loader' ),
448
+     *                   'repeatable'    => true,
449
+     *                   'sortable'      => true,
450
+     *                   'content'       => array(
451
+     *                       array(
452
+     *                           'field_id'      => 'a',
453
+     *                           'title'         => __( 'a', 'admin-page-framework-loader' ),                    
454
+     *                           'type'          => 'image',
455
+     *                           'attributes'    => array(
456
+     *                               'preview' => array(
457
+     *                                   'style' => 'max-width: 200px;',
458
+     *                               ),
459
+     *                           ),                                
460
+     *                       ),
461
+     *                       array(
462
+     *                           'field_id'      => 'b',
463
+     *                           'title'         => __( 'b', 'admin-page-framework-loader' ),
464
+     *                           'content'       => array(
465
+     *                               array(
466
+     *                                   'field_id'      => 'first',
467
+     *                                   'title'         => __( '1st', 'admin-page-framework-loader' ),                    
468
+     *                                   'type'          => 'color',
469
+     *                                   'repeatable'    => true,
470
+     *                                   'sortable'      => true,
471
+     *                               ),                                
472
+     *                               array(
473
+     *                                   'field_id'      => 'second',
474
+     *                                   'title'         => __( '2nd', 'admin-page-framework-loader' ),                    
475
+     *                                   'type'          => 'size',
476
+     *                               ),
477
+     *                               array(
478
+     *                                   'field_id'      => 'third',
479
+     *                                   'title'         => __( '3rd', 'admin-page-framework-loader' ),                    
480
+     *                                   'type'          => 'select',
481
+     *                                   'label'         => array(
482
+     *                                       'x' => 'X',
483
+     *                                       'y' => 'Y',
484
+     *                                       'z' => 'Z',                                        
485
+     *                                   ),
486
+     *                               ),                                    
487
+     *                           ),
488
+     *                           // 'description'   => '',
489
+     *                       ),                            
490
+     *                       array(
491
+     *                           'field_id'      => 'c',
492
+     *                           'title'         => __( 'c', 'admin-page-framework-loader' ),                    
493
+     *                           'type'          => 'radio',                    
494
+     *                           'label'         => array(
495
+     *                               'a' => __( 'Apple', 'admin-page-framework-loader' ),
496
+     *                               'b' => __( 'Banana', 'admin-page-framework-loader' ),
497
+     *                               'c' => __( 'Cherry', 'admin-page-framework-loader' ),
498
+     *                           ),
499
+     *                           'default'       => 'b',
500
+     *                       ),                        
501
+     *                   )
502
+     *               ),                    
503
+     *           ),
504
+     *       )
505
+     *   );
506
+     * </code></pre>
507
+     *       </li>
508
+     *       <li>**placement** - [3.8.0+] (optional, string) Specifies where the field is rendered. Either `normal` `section_title` or `field_title` is accepted. `field_title` can only be used by nested fields defined in the `content` argument.  Default: `normal`</li>
509
+     *       <li>**show_debug_info** - (optional, boolean) [3.8.8+] Whether to show debug information such as field definition tool-tips. Default: `true`.</li>
510
+     * </ul>
511
+     */
512 512
     public function addSettingField( $asFieldset ) {
513 513
         if ( method_exists( $this->oForm, 'addField' ) ) {
514 514
             $this->oForm->addField( $asFieldset );     
@@ -572,28 +572,28 @@  discard block
 block discarded – undo
572 572
     }
573 573
     
574 574
     /**
575
-    * Sets the given message to be displayed in the next page load. 
576
-    * 
577
-    * This is used to inform users about the submitted input data, such as "Updated successfully." or "Problem occurred." etc. 
578
-    * and normally used in validation callback methods.
579
-    * 
580
-    * <h4>Example</h4>
581
-    * `
582
-    * if ( ! $bVerified ) {
583
-    *       $this->setFieldErrors( $aErrors );     
584
-    *       $this->setSettingNotice( 'There was an error in your input.' );
585
-    *       return $aOldPageOptions;
586
-    * }
587
-    * `
588
-    *
589
-    * @since        3.0.4     
590
-    * @access       public
591
-    * @param        string      $sMessage       the text message to be displayed.
592
-    * @param        string      $sType          (optional) the type of the message, either "error" or "updated"  is used.
593
-    * @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.
594
-    * @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.
595
-    * @return       void
596
-    */      
575
+     * Sets the given message to be displayed in the next page load. 
576
+     * 
577
+     * This is used to inform users about the submitted input data, such as "Updated successfully." or "Problem occurred." etc. 
578
+     * and normally used in validation callback methods.
579
+     * 
580
+     * <h4>Example</h4>
581
+     * `
582
+     * if ( ! $bVerified ) {
583
+     *       $this->setFieldErrors( $aErrors );     
584
+     *       $this->setSettingNotice( 'There was an error in your input.' );
585
+     *       return $aOldPageOptions;
586
+     * }
587
+     * `
588
+     *
589
+     * @since        3.0.4     
590
+     * @access       public
591
+     * @param        string      $sMessage       the text message to be displayed.
592
+     * @param        string      $sType          (optional) the type of the message, either "error" or "updated"  is used.
593
+     * @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.
594
+     * @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.
595
+     * @return       void
596
+     */      
597 597
     public function setSettingNotice( $sMessage, $sType='error', $asAttributes=array(), $bOverride=true ) {
598 598
         $this->oForm->setSubmitNotice(
599 599
             $sMessage,
Please login to merge, or discard this patch.