section
$content_sections['content-head'] = array(
'panel' => $panel,
'title' => __( 'Site <HEAD> Section', 'absolute-weaver' ),
'options' => array(
'content-headsec-heading' => aweaver_cz_heading( __( 'Introductory Help for <HEAD> Section', 'absolute-weaver' ),
__( 'This panel allows you to add HTML to the <HEAD> Section of every page on your site.
PLEASE NOTE: Only minimal validation is made on the field values, so be careful not to use invalid code. Invalid code is usually harmless, but it can make your site display incorrectly. If your site looks broken after make changes here, please double check that what you entered uses valid HTML or CSS rules.', 'absolute-weaver' )),
'head_opts' => aweaver_cz_textarea(__( '<HEAD> Section Content', 'absolute-weaver' ),
/* $description = */ __(
'This input area allows you to enter allowed HTML head elements to the <head> section, including <title>, <base>, <link>, <meta>, <script>, and <style>.
Code entered into this box is included right before the </head> HTML tag on each page of your site.
We recommend using dedicated WordPress plugins to add things like ad tracking, SEO tags, Facebook code, and so on.
Note: You can add CSS Rules using the "Custom CSS Rules" option on the Main Options tab.', 'absolute-weaver' ),
/* $rows = */ '4', /* $placeholder = */ __('Any HTML allowed in .', 'absolute-weaver'),
/*$refresh = */ 'refresh', /*$plus = */false),
),
);
/**
* Site Header
*/
$content_sections['content-header'] = array(
'panel' => $panel,
'title' => __( 'Site Header Area', 'absolute-weaver' ),
'options' => array(
'header_html_text' => aweaver_cz_html_textarea(__( 'Header HTML Content', 'absolute-weaver' ),
__( 'Add arbitrary HTML to Header Area (in <div id="header-html">)', 'absolute-weaver' ),
'4'),
),
);
/**
* Main Menu
*/
$logo_html = aweaver_get_logo_html();
$content_sections['content-menus'] = array(
'panel' => $panel,
'title' => __( 'Primary Menu', 'absolute-weaver' ),
'description' => __( 'Set added content for Primary Menu.', 'absolute-weaver' ),
'options' => array(
'content-mm-heading' => aweaver_cz_group_title( __( 'Primary Menu', 'absolute-weaver' )),
'm_primary_html_right' => aweaver_cz_textarea(__( 'Right HTML', 'absolute-weaver' ),
'',
'1', __('Any HTML, including shortcodes.', 'absolute-weaver'),
'postMessage', false), // only primary right is in free version
'm_primary_logo_left' => aweaver_cz_checkbox_refresh(
__( 'Add Site Logo to Left', 'absolute-weaver' ),
__('Add the Site Logo to the primary menu. Add custom CSS for .custom-logo-on-menu to style. (Use Customize : Site Identity to set Site Logo.)', 'absolute-weaver') . $logo_html
),
'm_primary_logo_height_dec' => array(
'setting' => array( 'sanitize_callback' => 'aweaver_cz_sanitize_float', 'transport' => 'refresh', 'default' => 0
),
'control' => array(
'control_type' => 'WeaverA_Range_Control',
'label' => __( 'Logo on Menu Bar Height (em)', 'absolute-weaver' ) . ABSOLUTE_WVR_REFRESH_ICON,
'description' => __( 'Set height of Logo on Menu. Will interact with padding. Default 0 uses current line height.', 'absolute-weaver' ) ,
'type' => 'range',
'input_attrs' => array(
'min' => 0,
'max' => 10,
'step' => .1,
),
),
),
'm_primary_logo_home_link' => aweaver_cz_checkbox_refresh(
__( 'Logo Links to Home', 'absolute-weaver' ),
__('Add a link to home page to logo on menu bar (must use with defined custom menu).', 'absolute-weaver')
),
),
);
/**
* Post Specific
*/
$content_sections['content-post-specific'] = array(
'panel' => $panel,
'title' => __( 'Post Specific', 'absolute-weaver' ),
'description' => __('Post Specific Content - override Content Content.', 'absolute-weaver'),
'options' => array(
'excerpt_more_msg' => aweaver_cz_html_textarea(__( '"Continue reading" Message', 'absolute-weaver' ),
__( 'Change default Continue reading → message for excerpts. You can include HTML (e.g., <img>).', 'absolute-weaver' ),
'1'),
),
);
/**
* Footer
*/
$content_sections['content-footer'] = array(
'panel' => $panel,
'title' => __( 'Footer Area', 'absolute-weaver' ),
'options' => array(
'footer_html_text' => array(
'setting' => array( 'sanitize_callback' => 'aweaver_filter_code', 'transport' => 'postMessage',
'default' => ''
),
'control' => array(
'control_type' => 'WeaverA_Textarea_Control',
'label' => __( 'Footer HTML Content', 'absolute-weaver' ),
'description' => __( 'Add arbitrary HTML to Footer Area (in <div id="footer-html">)', 'absolute-weaver' ),
'type' => 'textarea',
'input_attrs' => array(
'rows' => '3',
'placeholder' => __('', 'absolute-weaver'),
),
),
),
'copyright' => array(
'setting' => array( 'sanitize_callback' => 'aweaver_filter_code', 'transport' => 'postMessage',
'default' => ''
),
'control' => array(
'control_type' => 'WeaverA_Textarea_Control',
'label' => __( '© Site Copyright', 'absolute-weaver' ) ,
'description' => __( 'If you fill this in, the default copyright notice in the footer will be replaced with the text here. It will not automatically update from year to year. Use © to display ©. You can use other HTML and shortcodes as well.
Use to hide the copyright notice. ♦', 'absolute-weaver' ),
'type' => 'textarea',
'input_attrs' => array(
'rows' => '2',
'placeholder' => __('', 'absolute-weaver'),
),
),
),
'postfooter_insert' => array(
'setting' => array( 'sanitize_callback' => 'aweaver_filter_code', 'transport' => 'postMessage',
'default' => ''
),
'control' => array(
'control_type' => 'WeaverA_Textarea_Control',
'label' => __( 'Post Footer HTML/Javascript Content', 'absolute-weaver' ),
'description' => __( 'Add arbitrary HTML or Javascript after the Footer Area (in <div id="footer-html">). Suitable for adding scripts at bottom of site HTML.', 'absolute-weaver' ),
'type' => 'textarea',
'input_attrs' => array(
'rows' => '3',
'placeholder' => __('', 'absolute-weaver'),
),
),
),
),
);
/**
* Injection areas
*/
/*
$content_sections['content-injection'] = array(
'panel' => $panel,
'title' => __( 'HTML Injection Areas', 'absolute-weaver' ),
'description' => __( 'HTML Injection Areas. The injection areas include Prewrapper and Postfooter for all versions of the theme. Absolute Weaver Plus also includes Preheader, Header Top, Container Top, Content Top, Page Content Bottom, Post-Post Content, Pre-Comments, Post-Comments, Pre-Footer, Primary Sidebar Top, Fixed Browser Top, and Fixed Browser Bottom. Note: unlike most other options, the HTML Injections area options provide all relevant associated options: content, color, custom CSS, and visibility.', 'absolute-weaver' ),
'options' => array(
),
);
$new_opts = aweaver_cz_add_injection('prewrapper', __('Prewrapper Injection Area', 'absolute-weaver'),
__('This code will be inserted just before the #wrapper and #branding <div>s, before any other site content.(Area ID: #inject_prewrapper) ', 'absolute-weaver'), 'standard');
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('postfooter', __('Post Footer Injection Area', 'absolute-weaver'),
__('This code will be inserted just after the footer #colophon <div>, outside the #wrapper div.(Area ID: #inject_postfooter)', 'absolute-weaver'), 'standard');
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
// X Plus Injection
$new_opts = aweaver_cz_add_injection('preheader', __('Preheader Injection Area', 'absolute-weaver'),
__('This code will be inserted just before the #header <div>. It will have the same width as the #wrapper area. This area may require extra styling to eliminate unwanted margins. (Area ID: #inject_preheader) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('header', __('Header Top Injection Area', 'absolute-weaver'),
__('This code will be inserted at the top of the #header <div>, before the top menu. It will have the same width as the header area. (Area ID: #inject_header) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('postheader', __('Post Header', 'absolute-weaver'),
__('This code will be inserted between the #header <div> and the #container <div>. It will have the same width as the #wrapper area. (Area ID: #inject_postheader) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('container_top', __('Container Top', 'absolute-weaver'),
__('This code will be inserted inside the #container <div> that wraps content, including before the top widget areas. It will have the same width as the container area. (Area ID: #inject_container_top) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('postinfobar', __('Pre Content', 'absolute-weaver'),
__('This code will be inserted inside the #content div that wraps content. It will have the same width as the container area. (Area ID: #inject_postinfobar) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('precontent', __('Content Top', 'absolute-weaver'),
__('This code will be inserted inside the #content div that wraps content. It will have the same width as the container area. (Area ID: #inject_precontent) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('pagecontentbottom', __('Page Content Bottom', 'absolute-weaver'),
__('This code will be at the bottom of page (including post single page view and page with posts) content. It will have the same width as the content area. (Area ID: #inject_pagecontentbottom) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('postpostcontent', __('Post-Post Content', 'absolute-weaver'),
__('This code will be inserted after the content area of each post (not page). (Area class: .inject_postpostcontent) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('precomments', __('Pre-Comments', 'absolute-weaver'),
__('This code will be inserted just before the #comments div where comments are displayed. If comments
are open for the page, this area will include the class .precomments-comments, if closed .precomments-nocomments. (Area ID: #inject_precomments) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('postcomments', __('Post-Comments', 'absolute-weaver'),
__('This code will be inserted right after the #comments div where comments are displayed. If comments
are open for the page, this area will include the class .postcomments-comments, if closed .postcomments-nocomments. (Area ID: #inject_postcomments) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('prefooter', __('Pre-Footer', 'absolute-weaver'),
__('This code will be inserted just before the footer #colophon div. (Area ID: #inject_prefooter) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('presidebar', __('Primary Sidebar Top', 'absolute-weaver'),
__('This code will be inserted inside the primary sidebar area at the top. Not shown if no primary sidebar defined. (Area ID: #inject_presidebar) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('fixedtop', __('Fixed Browser Top', 'absolute-weaver'),
__('This code will be inserted in a fixed location at the top of the (non-IE8) desktop browser window. It will have the same width as the Wrapper Area. You will need to add a Top Margin to the Wrapper Area. Do not make this area too tall! (Area ID: #inject_fixedtop) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
$new_opts = aweaver_cz_add_injection('fixedbottom', __('Fixed Browser Bottom', 'absolute-weaver'),
__('This code will be inserted in a fixed location at the bottom of the (non-IE8) desktop browser window. It will have the same width as the Wrapper Area. You will need to add a Bottom Margin to the Wrapper Area. Do not make this area too tall! (Area ID: #inject_fixedbottom) (☆Plus)', 'absolute-weaver'));
$content_sections['content-injection']['options'] = array_merge( $content_sections['content-injection']['options'], $new_opts);
*/
return $content_sections;
}
endif;
if (false) : // injection areas
function aweaver_cz_add_injection($root, $label = '', $description = '' , $version = 'XPlus' ) {
$opt = array();
if ($version == 'XPlus') $label .= ABSOLUTE_WVR_PLUS_ICON;
$opt[$root . '-heading'] = aweaver_cz_group_title( $label );
if ($description) {
$opt[$root . '-desc'] = array(
'control' => array( 'control_type' => 'WeaverA_Misc_Control',
'description' => $description,
'type' => 'text'));
}
if ($version != 'XPlus' || aweaver_cz_is_plus()) {
$opt["{$root}_insert"] = array(
'setting' => array( 'sanitize_callback' => 'aweaver_cz_sanitize_html', 'transport' => 'postMessage', 'default' => ''
),
'control' => array(
'control_type' => 'WeaverA_Textarea_Control',
'label' => __( 'HTML', 'absolute-weaver' ), // . ABSOLUTE_WVR_REFRESH_ICON,
'type' => 'textarea',
'input_attrs' => array(
'rows' => '3',
'placeholder' => __('Any HTML, including shortcodes.', 'absolute-weaver'),
),
),
);
$opt["inject_{$root}_bgcolor"] = array (
'setting' => array(
'sanitize_callback' => ABSOLUTE_WVR_CZ_SANITIZE_COLOR,
'transport' => 'postMessage',
'default' => aweaver_cz_getopt("inject_{$root}_bgcolor"),
),
'control' => array(
'control_type' => ABSOLUTE_WVR_COLOR_CONTROL,
'label' => __('BG Color', 'absolute-weaver'),
'description' => ''
),
);
$opt["inject_{$root}_bgcolor_css"] = aweaver_cz_css(__( 'Custom CSS', 'absolute-weaver' ));
$opt["inject_add_class_{$root}"] = array(
'setting' => array( 'sanitize_callback' => 'aweaver_cz_sanitize_html', 'transport' => 'refresh', 'default' => ''
),
'control' => array(
'control_type' => ABSOLUTE_WVR_PLUS_TEXT_CONTROL,
'label' => __( 'Add Classes', 'absolute-weaver' ) . ABSOLUTE_WVR_PLUS_ICON . ABSOLUTE_WVR_REFRESH_ICON,
'description' => __( 'Space separated class names to add to this area (Advanced option) (★Plus)', 'absolute-weaver' ),
'type' => 'text',
'input_attrs' => array(
),
),
);
$opt["hide_front_{$root}"] = aweaver_cz_checkbox_refresh(
__( 'Hide on front page', 'absolute-weaver' ),
__('If you check this box, then the code from this area will not be displayed on the front (home) page.', 'absolute-weaver')
);
$opt["hide_rest_{$root}"] = aweaver_cz_checkbox_refresh(
__( 'Hide on non-front pages', 'absolute-weaver' ),
__('If you check this box, then the code from this area will not be displayed on non-front pages.', 'absolute-weaver')
);
} // is plus
$opt[$root . '-line-break'] = array(
'control' => array( 'control_type' => 'WeaverA_Misc_Control',
'label' => '',
'type' => 'line'));
return $opt;
}
endif;
?>