Changeset 2430948
- Timestamp:
- 12/03/2020 02:30:58 PM (5 years ago)
- Location:
- jinx-block-renderer/trunk
- Files:
-
- 3 edited
-
index.php (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
-
src/Field.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
jinx-block-renderer/trunk/index.php
r2405204 r2430948 5 5 * Plugin URI: https://wordpress.org/plugins/jinx-block-renderer/ 6 6 * Description: Manipulate Gutenberg Blocks 7 * Version: 0. 1.37 * Version: 0.2.0 8 8 * Author: SquareFlower Websolutions (Lukas Rydygel) <hallo@squareflower.de> 9 9 * Author URI: https://squareflower.de -
jinx-block-renderer/trunk/readme.txt
r2405205 r2430948 3 3 Tags: blocks, gutenberg, manipulate, template 4 4 Requires at least: 5.0 5 Tested up to: 5.5. 15 Tested up to: 5.5.3 6 6 Requires PHP: 7.1 7 7 Stable tag: trunk … … 53 53 'attr' => 'src', 54 54 //'attr' => null // default - returns the results value 55 //'filter' => 'my_filter_function' // filters each matched field 55 56 ], 56 57 ], -
jinx-block-renderer/trunk/src/Field.php
r2358333 r2430948 12 12 public $attr; 13 13 public $item; 14 public $filter; 14 15 15 16 public function init() … … 66 67 protected function getData($elment) 67 68 { 68 return isset($this->attr) ? $elment->getAttribute($this->attr) : $elment->nodeValue; 69 70 $data = isset($this->attr) ? $elment->getAttribute($this->attr) : $elment->nodeValue; 71 72 return is_callable($this->filter) ? call_user_func($this->filter, $data) : $data; 73 69 74 } 70 75
Note: See TracChangeset
for help on using the changeset viewer.