PHP code example of appzz / wof
1. Go to this page and download the library: Download appzz/wof library . Choose the download type require .
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
appzz / wof example snippets
/** Composer */
#!php
use AppZz\Wp\Options\Framework as WP_Options_Framework;
if ( ! class_exists('AppZz\Wp\Options\Framework')) {
return;
}
$wof = new WP_Options_Framework ( 'Sample Plugin', 'sample_page', 'options-general.php', FALSE, FALSE );
$wof->addTab ( 'Main options', 'global', array ('player_options'=>'Define player options', 'api_options'=>'RM API') );
$wof->addTab ( 'Searh options', 'search', array ('sphinxql_options'=>'Setup SphinxQL') );
$wof->addFields ( 'global', array (
array (
'fid' => 'width',
'title' => 'Player width',
'type' => 'text',
'section' => 'player_options',
'std' => 620,
'validator' => 'intval',
'class' => NULL,
'desc' => 'Player width by default',
),
array (
'fid' => 'height',
'title' => 'Player height',
'type' => 'text',
'section' => 'player_options',
'std' => 465,
'validator' => 'intval',
'class' => NULL,
'desc' => 'Player height by default',
)
));
}