balmet.com

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

sortable.php (1799B)


      1 <?php
      2 /**
      3  * Redux Framework sortable config.
      4  * For full documentation, please visit: http://devs.redux.io/
      5  *
      6  * @package Redux Framework
      7  */
      8 
      9 defined( 'ABSPATH' ) || exit;
     10 
     11 Redux::set_section(
     12 	$opt_name,
     13 	array(
     14 		'title'      => esc_html__( 'Sortable', 'your-textdomain-here' ),
     15 		'id'         => 'basic-sortable',
     16 		'subsection' => true,
     17 		'desc'       => esc_html__( 'For full documentation on this field, visit: ', 'your-textdomain-here' ) . '<a href="https://devs.redux.io/core-fields/sortable.html" target="_blank">https://devs.redux.io/core-fields/sortable.html</a>',
     18 		'fields'     => array(
     19 			array(
     20 				'id'       => 'opt-sortable',
     21 				'type'     => 'sortable',
     22 				'title'    => esc_html__( 'Sortable Text Option', 'your-textdomain-here' ),
     23 				'subtitle' => esc_html__( 'Define and reorder these however you want.', 'your-textdomain-here' ),
     24 				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
     25 				'label'    => true,
     26 				'options'  => array(
     27 					'Text One'   => 'Item 1',
     28 					'Text Two'   => 'Item 2',
     29 					'Text Three' => 'Item 3',
     30 				),
     31 			),
     32 			array(
     33 				'id'       => 'opt-check-sortable',
     34 				'type'     => 'sortable',
     35 				'mode'     => 'toggle', // toggle or text.
     36 				'title'    => esc_html__( 'Sortable Toggle Option', 'your-textdomain-here' ),
     37 				'subtitle' => esc_html__( 'Define and reorder these however you want.', 'your-textdomain-here' ),
     38 				'desc'     => esc_html__( 'This is the description field, again good for additional info.', 'your-textdomain-here' ),
     39 				'options'  => array(
     40 					'cb1' => 'Option One',
     41 					'cb2' => 'Option Two',
     42 					'cb3' => 'Option Three',
     43 				),
     44 				'default'  => array(
     45 					'cb1' => false,
     46 					'cb2' => true,
     47 					'cb3' => false,
     48 				),
     49 			),
     50 		),
     51 	)
     52 );