| 1 |
<?php |
| 2 |
|
| 3 |
if( ! class_exists('AF_Divider_Field') ) : |
| 4 |
|
| 5 |
/** |
| 6 |
* Custom private ACF field used for picking a form field. |
| 7 |
* |
| 8 |
* @since 1.3.2 |
| 9 |
* |
| 10 |
*/ |
| 11 |
class AF_Divider_Field extends acf_field { |
| 12 |
|
| 13 |
|
| 14 |
/** |
| 15 |
* Set up field defaults |
| 16 |
* |
| 17 |
* @since 1.3.4 |
| 18 |
* |
| 19 |
*/ |
| 20 |
function __construct() { |
| 21 |
|
| 22 |
// vars |
| 23 |
$this->name = 'divider'; |
| 24 |
$this->label = _x('Divider', 'noun', 'acf'); |
| 25 |
$this->public = false; |
| 26 |
$this->defaults = array(); |
| 27 |
|
| 28 |
// do not delete! |
| 29 |
parent::__construct(); |
| 30 |
|
| 31 |
} |
| 32 |
|
| 33 |
|
| 34 |
/** |
| 35 |
* Render interface for field |
| 36 |
* |
| 37 |
* @since 1.3.4 |
| 38 |
* |
| 39 |
*/ |
| 40 |
function render_field( $field ) { |
| 41 |
|
| 42 |
} |
| 43 |
|
| 44 |
} |
| 45 |
|
| 46 |
|
| 47 |
// initialize |
| 48 |
acf_register_field_type( new AF_Divider_Field() ); |
| 49 |
|
| 50 |
endif; // class_exists check |
| 51 |
|
| 52 |
?> |