From 3d9b77af13f8f0152b8ffd34e152ff60bc02eaa1 Mon Sep 17 00:00:00 2001 From: "Anthony G. Basile" Date: Sun, 17 Apr 2016 17:05:14 -0400 Subject: Update theme mantra to 2.5.0 --- themes/mantra/admin/admin-functions.php | 20 + themes/mantra/admin/css/admin.css | 22 +- themes/mantra/admin/defaults.php | 6 +- themes/mantra/admin/images/mantra-logo.png | Bin 9168 -> 11148 bytes themes/mantra/admin/js/admin.js | 27 +- themes/mantra/admin/main.php | 323 +-- themes/mantra/admin/sanitize.php | 1 - themes/mantra/admin/settings.php | 83 +- themes/mantra/functions.php | 27 +- themes/mantra/includes/tgm.php | 3671 ++++++++++++++++++++++++ themes/mantra/includes/theme-functions.php | 2 +- themes/mantra/includes/theme-seo.php | 194 -- themes/mantra/includes/theme-styles.php | 8 +- themes/mantra/languages/_mantra.mo | Bin 443 -> 444 bytes themes/mantra/languages/_mantra.po | 2040 +++++++------ themes/mantra/readme.txt | 294 +- themes/mantra/style.css | 2 +- themes/mantra/template-onecolumn.php | 3 +- themes/mantra/template-page-with-intro.php | 4 +- themes/mantra/template-threecolumns-center.php | 9 +- themes/mantra/template-threecolumns-left.php | 9 +- themes/mantra/template-threecolumns-right.php | 9 +- themes/mantra/template-twocolumns-left.php | 7 +- themes/mantra/template-twocolumns-right.php | 7 +- 24 files changed, 5395 insertions(+), 1373 deletions(-) create mode 100644 themes/mantra/includes/tgm.php delete mode 100644 themes/mantra/includes/theme-seo.php diff --git a/themes/mantra/admin/admin-functions.php b/themes/mantra/admin/admin-functions.php index bc70fa17..22e77a6c 100644 --- a/themes/mantra/admin/admin-functions.php +++ b/themes/mantra/admin/admin-functions.php @@ -1,4 +1,24 @@ +
+

Where are the theme settings?

+

Following the Wordpress Theme Review Guidelines, starting with Mantra v2.5 we had to remove the settings page from the theme and transfer all the settings to the Customizer interface.

+

However, we feel that the Customizer interface does not provide the right medium (in space of terms and usability) for our existing theme options. We've created our settings with a certain layout that is not yet compatible with the Customizer interface.

+

As an alternative solution that allows us to keep updating and improving our theme we have moved the settings functionality to the separate Cryout Serious Theme Settings plugin. To restore the theme settings page to previous functionality, all you need to do is install this free plugin with a couple of clicks.

+

How do I restore the settings?

+

Navigate to this page to install and activate the Cryout Serious Theme Settings plugin, then return here to find the settings page in all its past glory.

+

The plugin is compatible with all our themes that are affected by this change and only needs to be installed once.

+

If you already have the plugin installed make sure you have it updated to the latest available version.

+
+ h3 { +#accordion > h3, #accordion > h2 { display:block; } @@ -630,3 +630,19 @@ padding:5px 10px; margin:0 8px; } +#mantra-settings-placeholder { + background: #fff; + padding: 0 10px 10px 10px; } + +#mantra-settings-placeholder h3 { + background: #444; + color: #fff; + text-transform: uppercase; + font-weight: 400; + padding: 10px; + margin: 0 -10px; + font-size: 14px; } + +#mantra-settings-placeholder a { + color: #24C1BB; } + diff --git a/themes/mantra/admin/defaults.php b/themes/mantra/admin/defaults.php index 00c15d9e..3ba7d711 100644 --- a/themes/mantra/admin/defaults.php +++ b/themes/mantra/admin/defaults.php @@ -208,10 +208,6 @@ $mantra_defaults = array( "mantra_copyright" => "", "mantra_customcss" => "/* Mantra Custom CSS */ ", -"mantra_customjs" => "", -"mantra_seo" => "Enable", -"mantra_seo_home_desc" => "", -"mantra_seo_gen_desc" => "Auto", -"mantra_seo_author" => "Do not use"); +"mantra_customjs" => ""); ?> \ No newline at end of file diff --git a/themes/mantra/admin/images/mantra-logo.png b/themes/mantra/admin/images/mantra-logo.png index 4e861909..a39712e2 100644 Binary files a/themes/mantra/admin/images/mantra-logo.png and b/themes/mantra/admin/images/mantra-logo.png differ diff --git a/themes/mantra/admin/js/admin.js b/themes/mantra/admin/js/admin.js index 4b554662..c3002104 100644 --- a/themes/mantra/admin/js/admin.js +++ b/themes/mantra/admin/js/admin.js @@ -163,18 +163,29 @@ else jQuery('#slider-post-number').hide(); // Create accordion from existing settings table jQuery('.form-table').wrap('
'); jQuery(function() { + if (jQuery( "#accordion h2" ).length > 0) { + // wordpress 4.4+ changed headings to h2 + jQuery( "#accordion" ).accordion({ + header: 'h2', + heightStyle: "content", + collapsible: true, + navigation: true, + active: false + }); + } else { jQuery( "#accordion" ).accordion({ - header: 'h3', - autoHeight: false, // for jQueryUI <1.10 - heightStyle: "content", // required in jQueryUI 1.10 - collapsible: true, - navigation: true, - active: false + header: 'h3', + autoHeight: false, // for jQueryUI <1.10 + heightStyle: "content", // required in jQueryUI 1.10 + collapsible: true, + navigation: true, + active: false }); - }); + } + }); - });// ready +});// ready // Change border for selecte inputs function changeBorder (idName, className) { diff --git a/themes/mantra/admin/main.php b/themes/mantra/admin/main.php index 96bb826e..fe8e7ff6 100644 --- a/themes/mantra/admin/main.php +++ b/themes/mantra/admin/main.php @@ -1,20 +1,13 @@ $value) { // Hooks/Filters -add_action('admin_init', 'mantra_init_fn' ); +// add_action('admin_init', 'mantra_init_fn' ); // hooked by the settings plugin add_action('admin_menu', 'mantra_add_page_fn'); add_action('init', 'mantra_init'); @@ -41,13 +34,13 @@ $mantra_options= mantra_get_theme_options(); // Registering and enqueuing all scripts and styles for the init hook function mantra_init() { -//Loading Mantra text domain into the admin section - load_theme_textdomain( 'mantra', get_template_directory_uri() . '/languages' ); + //Loading Mantra text domain into the admin section + load_theme_textdomain( 'mantra', get_template_directory_uri() . '/languages' ); } // Creating the mantra subpage function mantra_add_page_fn() { -$page = add_theme_page('Mantra Settings', 'Mantra Settings', 'edit_theme_options', 'mantra-page', 'mantra_page_fn'); + $page = add_theme_page('Mantra Settings', 'Mantra Settings', 'edit_theme_options', 'mantra-page', 'mantra_page_fn'); add_action( 'admin_print_styles-'.$page, 'mantra_admin_styles' ); add_action('admin_print_scripts-'.$page, 'mantra_admin_scripts'); @@ -55,44 +48,44 @@ $page = add_theme_page('Mantra Settings', 'Mantra Settings', 'edit_theme_options // Adding the styles for the Mantra admin page used when mantra_add_page_fn() is launched function mantra_admin_styles() { - - wp_register_style( 'mantra-admin-style',get_template_directory_uri() . '/admin/css/admin.css' ); - wp_register_style( 'jquery-ui-style',get_template_directory_uri() . '/js/jqueryui/css/ui-lightness/jquery-ui-1.8.16.custom.css' ); + wp_register_style( 'mantra-admin-style',get_template_directory_uri() . '/admin/css/admin.css', NULL, _CRYOUT_THEME_VERSION ); + wp_register_style( 'jquery-ui-style',get_template_directory_uri() . '/js/jqueryui/css/ui-lightness/jquery-ui-1.8.16.custom.css', NULL, _CRYOUT_THEME_VERSION ); wp_enqueue_style( 'mantra-admin-style' ); wp_enqueue_style( 'jquery-ui-style' ); - } // Adding the styles for the Mantra admin page used when mantra_add_page_fn() is launched function mantra_admin_scripts() { -// The farbtastic color selector already included in WP + // The farbtastic color selector already included in WP wp_enqueue_script("farbtastic"); wp_enqueue_style( 'farbtastic' ); -//Jquery accordion and slider libraries alreay included in WP + //jQuery accordion and slider libraries already included in WP wp_enqueue_script('jquery-ui-accordion'); wp_enqueue_script('jquery-ui-slider'); wp_enqueue_script('jquery-ui-tooltip'); -// For backwards compatibility where Mantra is installed on older versions of WP where the ui accordion and slider are not included + + // For backwards compatibility where Mantra is installed on older versions of WP where the ui accordion and slider are not included if (!wp_script_is('jquery-ui-accordion',$list='registered')) { - wp_register_script('cryout_accordion',get_template_directory_uri() . '/admin/js/accordion-slider.js', array('jquery') ); + wp_register_script('cryout_accordion',get_template_directory_uri() . '/admin/js/accordion-slider.js', array('jquery'), _CRYOUT_THEME_VERSION ); wp_enqueue_script('cryout_accordion'); } + // For the WP uploader if(function_exists('wp_enqueue_media')) { - wp_enqueue_media(); - } - else { - wp_enqueue_script('media-upload'); - wp_enqueue_script('thickbox'); - wp_enqueue_style('thickbox'); - } -// The js used in the admin - wp_register_script('cryout-admin-js',get_template_directory_uri() . '/admin/js/admin.js' ); + wp_enqueue_media(); + } else { + wp_enqueue_script('media-upload'); + wp_enqueue_script('thickbox'); + wp_enqueue_style('thickbox'); + } + + // The JS used in the admin + wp_register_script('cryout-admin-js',get_template_directory_uri() . '/admin/js/admin.js', NULL, _CRYOUT_THEME_VERSION ); wp_enqueue_script('cryout-admin-js'); } -// The settings sectoions. All the referenced functions are found in admin-functions.php +// The settings sections. All the referenced functions are found in admin-functions.php function mantra_init_fn(){ @@ -102,154 +95,154 @@ function mantra_init_fn(){ sections **************/ - add_settings_section('layout_section', __('Layout Settings','mantra'), 'cryout_section_layout_fn', __FILE__); - add_settings_section('header_section', __('Header Settings','mantra'), 'cryout_section_header_fn', __FILE__); - add_settings_section('presentation_section', __('Presentation Page','mantra'), 'cryout_section_presentation_fn', __FILE__); - add_settings_section('text_section', __('Text Settings','mantra'), 'cryout_section_text_fn', __FILE__); - add_settings_section('appereance_section',__('Color Settings','mantra') , 'cryout_section_appereance_fn', __FILE__); - add_settings_section('graphics_section', __('Graphics Settings','mantra') , 'cryout_section_graphics_fn', __FILE__); - add_settings_section('post_section', __('Post Information Settings','mantra') , 'cryout_section_post_fn', __FILE__); - add_settings_section('excerpt_section', __('Post Excerpt Settings','mantra') , 'cryout_section_excerpt_fn', __FILE__); - add_settings_section('featured_section', __('Featured Image Settings','mantra') , 'cryout_section_featured_fn', __FILE__); - add_settings_section('socials_section', __('Social Media Settings','mantra') , 'cryout_section_social_fn', __FILE__); - add_settings_section('misc_section', __('Miscellaneous Settings','mantra') , 'cryout_section_misc_fn', __FILE__); + add_settings_section('layout_section', __('Layout Settings','mantra'), 'cryout_section_layout_fn', 'mantra-page'); + add_settings_section('header_section', __('Header Settings','mantra'), 'cryout_section_header_fn', 'mantra-page'); + add_settings_section('presentation_section', __('Presentation Page','mantra'), 'cryout_section_presentation_fn', 'mantra-page'); + add_settings_section('text_section', __('Text Settings','mantra'), 'cryout_section_text_fn', 'mantra-page'); + add_settings_section('appereance_section',__('Color Settings','mantra') , 'cryout_section_appereance_fn', 'mantra-page'); + add_settings_section('graphics_section', __('Graphics Settings','mantra') , 'cryout_section_graphics_fn', 'mantra-page'); + add_settings_section('post_section', __('Post Information Settings','mantra') , 'cryout_section_post_fn', 'mantra-page'); + add_settings_section('excerpt_section', __('Post Excerpt Settings','mantra') , 'cryout_section_excerpt_fn', 'mantra-page'); + add_settings_section('featured_section', __('Featured Image Settings','mantra') , 'cryout_section_featured_fn', 'mantra-page'); + add_settings_section('socials_section', __('Social Media Settings','mantra') , 'cryout_section_social_fn', 'mantra-page'); + add_settings_section('misc_section', __('Miscellaneous Settings','mantra') , 'cryout_section_misc_fn', 'mantra-page'); /*** layout ***/ - add_settings_field('mantra_side', __('Main Layout','mantra') , 'cryout_setting_side_fn', __FILE__, 'layout_section'); - add_settings_field('mantra_sidewidth', __('Content / Sidebar Width','mantra') , 'cryout_setting_sidewidth_fn', __FILE__, 'layout_section'); - add_settings_field('mantra_mobile', __('Responsiveness','mantra') , 'cryout_setting_mobile_fn', __FILE__, 'layout_section'); + add_settings_field('mantra_side', __('Main Layout','mantra') , 'cryout_setting_side_fn', 'mantra-page', 'layout_section'); + add_settings_field('mantra_sidewidth', __('Content / Sidebar Width','mantra') , 'cryout_setting_sidewidth_fn', 'mantra-page', 'layout_section'); + add_settings_field('mantra_mobile', __('Responsiveness','mantra') , 'cryout_setting_mobile_fn', 'mantra-page', 'layout_section'); /*** presentation ***/ - add_settings_field('mantra_frontpage', __('Enable Presentation Page','mantra') , 'cryout_setting_frontpage_fn', __FILE__, 'presentation_section'); - add_settings_field('mantra_frontposts', __('Show Posts on Presentation Page','mantra') , 'cryout_setting_frontposts_fn', __FILE__, 'presentation_section'); - add_settings_field('mantra_frontslider', __('Slider Settings','mantra') , 'cryout_setting_frontslider_fn', __FILE__, 'presentation_section'); - add_settings_field('mantra_frontslider2', __('Slides','mantra') , 'cryout_setting_frontslider2_fn', __FILE__, 'presentation_section'); - add_settings_field('mantra_frontcolumns', __('Presentation Page Columns','mantra') , 'cryout_setting_frontcolumns_fn', __FILE__, 'presentation_section'); - add_settings_field('mantra_fronttext', __('Extras','mantra') , 'cryout_setting_fronttext_fn', __FILE__, 'presentation_section'); + add_settings_field('mantra_frontpage', __('Enable Presentation Page','mantra') , 'cryout_setting_frontpage_fn', 'mantra-page', 'presentation_section'); + add_settings_field('mantra_frontposts', __('Show Posts on Presentation Page','mantra') , 'cryout_setting_frontposts_fn', 'mantra-page', 'presentation_section'); + add_settings_field('mantra_frontslider', __('Slider Settings','mantra') , 'cryout_setting_frontslider_fn', 'mantra-page', 'presentation_section'); + add_settings_field('mantra_frontslider2', __('Slides','mantra') , 'cryout_setting_frontslider2_fn', 'mantra-page', 'presentation_section'); + add_settings_field('mantra_frontcolumns', __('Presentation Page Columns','mantra') , 'cryout_setting_frontcolumns_fn', 'mantra-page', 'presentation_section'); + add_settings_field('mantra_fronttext', __('Extras','mantra') , 'cryout_setting_fronttext_fn', 'mantra-page', 'presentation_section'); /*** header ***/ - add_settings_field('mantra_hheight', __('Header Height','mantra') , 'cryout_setting_hheight_fn', __FILE__, 'header_section'); - add_settings_field('mantra_himage', __('Header Image','mantra') , 'cryout_setting_himage_fn', __FILE__, 'header_section'); - add_settings_field('mantra_siteheader', __('Site Header','mantra') , 'cryout_setting_siteheader_fn', __FILE__, 'header_section'); - add_settings_field('mantra_logoupload', __('Custom Logo Upload','mantra') , 'cryout_setting_logoupload_fn', __FILE__, 'header_section'); - add_settings_field('mantra_headermargin', __('Header Spacing','mantra') , 'cryout_setting_headermargin_fn', __FILE__, 'header_section'); - add_settings_field('mantra_menurounded', __('Rounded Menu Corners','mantra') , 'cryout_setting_menurounded_fn', __FILE__, 'header_section'); - add_settings_field('mantra_favicon', __('FavIcon Upload','mantra') , 'cryout_setting_favicon_fn', __FILE__, 'header_section'); + add_settings_field('mantra_hheight', __('Header Height','mantra') , 'cryout_setting_hheight_fn', 'mantra-page', 'header_section'); + add_settings_field('mantra_himage', __('Header Image','mantra') , 'cryout_setting_himage_fn', 'mantra-page', 'header_section'); + add_settings_field('mantra_siteheader', __('Site Header','mantra') , 'cryout_setting_siteheader_fn', 'mantra-page', 'header_section'); + add_settings_field('mantra_logoupload', __('Custom Logo Upload','mantra') , 'cryout_setting_logoupload_fn', 'mantra-page', 'header_section'); + add_settings_field('mantra_headermargin', __('Header Spacing','mantra') , 'cryout_setting_headermargin_fn', 'mantra-page', 'header_section'); + add_settings_field('mantra_menurounded', __('Rounded Menu Corners','mantra') , 'cryout_setting_menurounded_fn', 'mantra-page', 'header_section'); + add_settings_field('mantra_favicon', __('FavIcon Upload','mantra') , 'cryout_setting_favicon_fn', 'mantra-page', 'header_section'); /*** text ***/ - add_settings_field('mantra_fontfamily', __('General Font','mantra') , 'cryout_setting_fontfamily_fn', __FILE__, 'text_section'); - add_settings_field('mantra_fontsize', __('General Font Size','mantra') , 'cryout_setting_fontsize_fn', __FILE__, 'text_section'); - add_settings_field('mantra_fonttitle', __('Post Title Font ','mantra') , 'cryout_setting_fonttitle_fn', __FILE__, 'text_section'); - add_settings_field('mantra_headfontsize', __('Post Title Font Size','mantra') , 'cryout_setting_headfontsize_fn', __FILE__, 'text_section'); - add_settings_field('mantra_fontside', __('Sidebar Font','mantra') , 'cryout_setting_fontside_fn', __FILE__, 'text_section'); - add_settings_field('mantra_sidefontsize', __('SideBar Font Size','mantra') , 'cryout_setting_sidefontsize_fn', __FILE__, 'text_section'); - add_settings_field('mantra_fontsubheader', __('Headings Font','mantra') , 'cryout_setting_fontsubheader_fn', __FILE__, 'text_section'); - add_settings_field('mantra_textalign', __('Force Text Align','mantra') , 'cryout_setting_textalign_fn', __FILE__, 'text_section'); - add_settings_field('mantra_parmargin', __('Paragraph spacing','mantra') , 'cryout_setting_parmargin_fn', __FILE__, 'text_section'); - add_settings_field('mantra_parindent', __('Paragraph indent','mantra') , 'cryout_setting_parindent_fn', __FILE__, 'text_section'); - add_settings_field('mantra_headerindent', __('Header indent','mantra') , 'cryout_setting_headerindent_fn', __FILE__, 'text_section'); - add_settings_field('mantra_lineheight', __('Line Height','mantra') , 'cryout_setting_lineheight_fn', __FILE__, 'text_section'); - add_settings_field('mantra_wordspace', __('Word spacing','mantra') , 'cryout_setting_wordspace_fn', __FILE__, 'text_section'); - add_settings_field('mantra_letterspace', __('Letter spacing','mantra') , 'cryout_setting_letterspace_fn', __FILE__, 'text_section'); - add_settings_field('mantra_textshadow', __('Text shadow','mantra') , 'cryout_setting_textshadow_fn', __FILE__, 'text_section'); + add_settings_field('mantra_fontfamily', __('General Font','mantra') , 'cryout_setting_fontfamily_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_fontsize', __('General Font Size','mantra') , 'cryout_setting_fontsize_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_fonttitle', __('Post Title Font ','mantra') , 'cryout_setting_fonttitle_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_headfontsize', __('Post Title Font Size','mantra') , 'cryout_setting_headfontsize_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_fontside', __('Sidebar Font','mantra') , 'cryout_setting_fontside_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_sidefontsize', __('SideBar Font Size','mantra') , 'cryout_setting_sidefontsize_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_fontsubheader', __('Headings Font','mantra') , 'cryout_setting_fontsubheader_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_textalign', __('Force Text Align','mantra') , 'cryout_setting_textalign_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_parmargin', __('Paragraph spacing','mantra') , 'cryout_setting_parmargin_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_parindent', __('Paragraph indent','mantra') , 'cryout_setting_parindent_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_headerindent', __('Header indent','mantra') , 'cryout_setting_headerindent_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_lineheight', __('Line Height','mantra') , 'cryout_setting_lineheight_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_wordspace', __('Word spacing','mantra') , 'cryout_setting_wordspace_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_letterspace', __('Letter spacing','mantra') , 'cryout_setting_letterspace_fn', 'mantra-page', 'text_section'); + add_settings_field('mantra_textshadow', __('Text shadow','mantra') , 'cryout_setting_textshadow_fn', 'mantra-page', 'text_section'); /*** appereance ***/ - add_settings_field('mantra_sitebackground', __('Background Image','mantra') , 'cryout_setting_sitebackground_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_backcolor', __('Background Color','mantra') , 'cryout_setting_backcolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_headercolor', __('Header (Banner and Menu) Background Color','mantra') , 'cryout_setting_headercolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_contentbg', __('Content Background Color','mantra') , 'cryout_setting_contentbg_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_menubg', __('Menu Items Background Color','mantra') , 'cryout_setting_menubg_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_s1bg', __('First Sidebar Background Color','mantra') , 'cryout_setting_first_sidebar_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_s2bg', __('Second Sidebar Background Color','mantra') , 'cryout_setting_second_sidebar_fn', __FILE__, 'appereance_section'); - - add_settings_field('mantra_titlecolor', __('Site Title Color','mantra') , 'cryout_setting_titlecolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_descriptioncolor', __('Site Description Color','mantra') , 'cryout_setting_descriptioncolor_fn', __FILE__, 'appereance_section'); - - add_settings_field('mantra_contentcolor', __('Content Text Color','mantra') , 'cryout_setting_contentcolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_linkscolor', __('Links Color','mantra') , 'cryout_setting_linkscolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_hovercolor', __('Links Hover Color','mantra') , 'cryout_setting_hovercolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_headtextcolor',__( 'Post Title Color','mantra') , 'cryout_setting_headtextcolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_headtexthover', __('Post Title Hover Color','mantra') , 'cryout_setting_headtexthover_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_sideheadbackcolor', __('Sidebar Header Background Color','mantra') , 'cryout_setting_sideheadbackcolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_sideheadtextcolor', __('Sidebar Header Text Color','mantra') , 'cryout_setting_sideheadtextcolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_prefootercolor', __('Footer Widget Background Color','mantra') , 'cryout_setting_prefootercolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_footercolor', __('Footer Background Color','mantra') , 'cryout_setting_footercolor_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_footerheader', __('Footer Widget Header Text Color','mantra') , 'cryout_setting_footerheader_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_footertext', __('Footer Widget Link Color','mantra') , 'cryout_setting_footertext_fn', __FILE__, 'appereance_section'); - add_settings_field('mantra_footerhover', __('Footer Widget Hover Color','mantra') , 'cryout_setting_footerhover_fn', __FILE__, 'appereance_section'); + add_settings_field('mantra_sitebackground', __('Background Image','mantra') , 'cryout_setting_sitebackground_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_backcolor', __('Background Color','mantra') , 'cryout_setting_backcolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_headercolor', __('Header (Banner and Menu) Background Color','mantra') , 'cryout_setting_headercolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_contentbg', __('Content Background Color','mantra') , 'cryout_setting_contentbg_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_menubg', __('Menu Items Background Color','mantra') , 'cryout_setting_menubg_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_s1bg', __('First Sidebar Background Color','mantra') , 'cryout_setting_first_sidebar_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_s2bg', __('Second Sidebar Background Color','mantra') , 'cryout_setting_second_sidebar_fn', 'mantra-page', 'appereance_section'); + + add_settings_field('mantra_titlecolor', __('Site Title Color','mantra') , 'cryout_setting_titlecolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_descriptioncolor', __('Site Description Color','mantra') , 'cryout_setting_descriptioncolor_fn', 'mantra-page', 'appereance_section'); + + add_settings_field('mantra_contentcolor', __('Content Text Color','mantra') , 'cryout_setting_contentcolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_linkscolor', __('Links Color','mantra') , 'cryout_setting_linkscolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_hovercolor', __('Links Hover Color','mantra') , 'cryout_setting_hovercolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_headtextcolor',__( 'Post Title Color','mantra') , 'cryout_setting_headtextcolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_headtexthover', __('Post Title Hover Color','mantra') , 'cryout_setting_headtexthover_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_sideheadbackcolor', __('Sidebar Header Background Color','mantra') , 'cryout_setting_sideheadbackcolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_sideheadtextcolor', __('Sidebar Header Text Color','mantra') , 'cryout_setting_sideheadtextcolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_prefootercolor', __('Footer Widget Background Color','mantra') , 'cryout_setting_prefootercolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_footercolor', __('Footer Background Color','mantra') , 'cryout_setting_footercolor_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_footerheader', __('Footer Widget Header Text Color','mantra') , 'cryout_setting_footerheader_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_footertext', __('Footer Widget Link Color','mantra') , 'cryout_setting_footertext_fn', 'mantra-page', 'appereance_section'); + add_settings_field('mantra_footerhover', __('Footer Widget Hover Color','mantra') , 'cryout_setting_footerhover_fn', 'mantra-page', 'appereance_section'); /*** graphics ***/ - add_settings_field('mantra_breadcrumbs', __('Breadcrumbs','mantra') , 'cryout_setting_breadcrumbs_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_pagination', __('Pagination','mantra') , 'cryout_setting_pagination_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_menualign', __('Main Menu Alignment','mantra') , 'cryout_setting_menualign_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_image', __('Post Images Border','mantra') , 'cryout_setting_image_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_caption', __('Caption Border','mantra') , 'cryout_setting_caption_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_pin', __('Caption Pin','mantra') , 'cryout_setting_pin_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_sidebullet', __('Sidebar Menu Bullets','mantra') , 'cryout_setting_sidebullet_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_metaback', __('Meta Area Background','mantra') , 'cryout_setting_metaback_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_postseparator', __('Post Separator','mantra') , 'cryout_setting_postseparator_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_contentlist', __('Content List Bullets','mantra') , 'cryout_setting_contentlist_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_pagetitle', __('Page Titles','mantra') , 'cryout_setting_pagetitle_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_categetitle', __('Category Page Titles','mantra') , 'cryout_setting_categtitle_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_tables', __('Hide Tables','mantra') , 'cryout_setting_tables_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_backtop', __('Back to Top button','mantra') , 'cryout_setting_backtop_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_comtext', __('Text Under Comments','mantra') , 'cryout_setting_comtext_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_comclosed', __('Comments are closed text','mantra') , 'cryout_setting_comclosed_fn', __FILE__, 'graphics_section'); - add_settings_field('mantra_comoff', __('Comments off','mantra') , 'cryout_setting_comoff_fn', __FILE__, 'graphics_section'); + add_settings_field('mantra_breadcrumbs', __('Breadcrumbs','mantra') , 'cryout_setting_breadcrumbs_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_pagination', __('Pagination','mantra') , 'cryout_setting_pagination_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_menualign', __('Main Menu Alignment','mantra') , 'cryout_setting_menualign_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_image', __('Post Images Border','mantra') , 'cryout_setting_image_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_caption', __('Caption Border','mantra') , 'cryout_setting_caption_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_pin', __('Caption Pin','mantra') , 'cryout_setting_pin_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_sidebullet', __('Sidebar Menu Bullets','mantra') , 'cryout_setting_sidebullet_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_metaback', __('Meta Area Background','mantra') , 'cryout_setting_metaback_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_postseparator', __('Post Separator','mantra') , 'cryout_setting_postseparator_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_contentlist', __('Content List Bullets','mantra') , 'cryout_setting_contentlist_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_pagetitle', __('Page Titles','mantra') , 'cryout_setting_pagetitle_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_categetitle', __('Category Page Titles','mantra') , 'cryout_setting_categtitle_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_tables', __('Hide Tables','mantra') , 'cryout_setting_tables_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_backtop', __('Back to Top button','mantra') , 'cryout_setting_backtop_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_comtext', __('Text Under Comments','mantra') , 'cryout_setting_comtext_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_comclosed', __('Comments are closed text','mantra') , 'cryout_setting_comclosed_fn', 'mantra-page', 'graphics_section'); + add_settings_field('mantra_comoff', __('Comments off','mantra') , 'cryout_setting_comoff_fn', 'mantra-page', 'graphics_section'); /*** post metas***/ - add_settings_field('mantra_postcomlink', __('Post Comments Link','mantra') , 'cryout_setting_postcomlink_fn', __FILE__, 'post_section'); - add_settings_field('mantra_postdate', __('Post Date','mantra') , 'cryout_setting_postdate_fn', __FILE__, 'post_section'); - add_settings_field('mantra_posttime', __('Post Time','mantra') , 'cryout_setting_posttime_fn', __FILE__, 'post_section'); - add_settings_field('mantra_postauthor', __('Post Author','mantra') , 'cryout_setting_postauthor_fn', __FILE__, 'post_section'); - add_settings_field('mantra_postcateg', __('Post Category','mantra') , 'cryout_setting_postcateg_fn', __FILE__, 'post_section'); - add_settings_field('mantra_postmetas', __('Meta Bar','mantra') , 'cryout_setting_postmetas_fn', __FILE__, 'post_section'); - add_settings_field('mantra_posttag', __('Post Tags','mantra') , 'cryout_setting_posttag_fn', __FILE__, 'post_section'); - add_settings_field('mantra_postbook', __('Post Permalink','mantra') , 'cryout_setting_postbook_fn', __FILE__, 'post_section'); + add_settings_field('mantra_postcomlink', __('Post Comments Link','mantra') , 'cryout_setting_postcomlink_fn', 'mantra-page', 'post_section'); + add_settings_field('mantra_postdate', __('Post Date','mantra') , 'cryout_setting_postdate_fn', 'mantra-page', 'post_section'); + add_settings_field('mantra_posttime', __('Post Time','mantra') , 'cryout_setting_posttime_fn', 'mantra-page', 'post_section'); + add_settings_field('mantra_postauthor', __('Post Author','mantra') , 'cryout_setting_postauthor_fn', 'mantra-page', 'post_section'); + add_settings_field('mantra_postcateg', __('Post Category','mantra') , 'cryout_setting_postcateg_fn', 'mantra-page', 'post_section'); + add_settings_field('mantra_postmetas', __('Meta Bar','mantra') , 'cryout_setting_postmetas_fn', 'mantra-page', 'post_section'); + add_settings_field('mantra_posttag', __('Post Tags','mantra') , 'cryout_setting_posttag_fn', 'mantra-page', 'post_section'); + add_settings_field('mantra_postbook', __('Post Permalink','mantra') , 'cryout_setting_postbook_fn', 'mantra-page', 'post_section'); /*** post exceprts***/ - add_settings_field('mantra_excerpthome', __('Post Excerpts on Home Page','mantra') , 'cryout_setting_excerpthome_fn', __FILE__, 'excerpt_section'); - add_settings_field('mantra_excerptsticky', __('Affect Sticky Posts','mantra') , 'cryout_setting_excerptsticky_fn', __FILE__, 'excerpt_section'); - add_settings_field('mantra_excerptarchive', __('Post Excerpts on Archive and Category Pages','mantra') , 'cryout_setting_excerptarchive_fn', __FILE__, 'excerpt_section'); - add_settings_field('mantra_excerptwords', __('Number of Words for Post Excerpts ','mantra') , 'cryout_setting_excerptwords_fn', __FILE__, 'excerpt_section'); - add_settings_field('mantra_magazinelayout', __('Magazine Layout','mantra') , 'cryout_setting_magazinelayout_fn', __FILE__, 'excerpt_section'); - add_settings_field('mantra_excerptdots', __('Excerpt suffix','mantra') , 'cryout_setting_excerptdots_fn', __FILE__, 'excerpt_section'); - add_settings_field('mantra_excerptcont', __('Continue reading link text ','mantra') , 'cryout_setting_excerptcont_fn', __FILE__, 'excerpt_section'); - add_settings_field('mantra_excerpttags', __('HTML tags in Excerpts','mantra') , 'cryout_setting_excerpttags_fn', __FILE__, 'excerpt_section'); + add_settings_field('mantra_excerpthome', __('Post Excerpts on Home Page','mantra') , 'cryout_setting_excerpthome_fn', 'mantra-page', 'excerpt_section'); + add_settings_field('mantra_excerptsticky', __('Affect Sticky Posts','mantra') , 'cryout_setting_excerptsticky_fn', 'mantra-page', 'excerpt_section'); + add_settings_field('mantra_excerptarchive', __('Post Excerpts on Archive and Category Pages','mantra') , 'cryout_setting_excerptarchive_fn', 'mantra-page', 'excerpt_section'); + add_settings_field('mantra_excerptwords', __('Number of Words for Post Excerpts ','mantra') , 'cryout_setting_excerptwords_fn', 'mantra-page', 'excerpt_section'); + add_settings_field('mantra_magazinelayout', __('Magazine Layout','mantra') , 'cryout_setting_magazinelayout_fn', 'mantra-page', 'excerpt_section'); + add_settings_field('mantra_excerptdots', __('Excerpt suffix','mantra') , 'cryout_setting_excerptdots_fn', 'mantra-page', 'excerpt_section'); + add_settings_field('mantra_excerptcont', __('Continue reading link text ','mantra') , 'cryout_setting_excerptcont_fn', 'mantra-page', 'excerpt_section'); + add_settings_field('mantra_excerpttags', __('HTML tags in Excerpts','mantra') , 'cryout_setting_excerpttags_fn', 'mantra-page', 'excerpt_section'); /*** featured ***/ - add_settings_field('mantra_fpost', __('Featured Images as POST Thumbnails ','mantra') , 'cryout_setting_fpost_fn', __FILE__, 'featured_section'); - add_settings_field('mantra_fauto', __('Auto Select Images From Posts ','mantra') , 'cryout_setting_fauto_fn', __FILE__, 'featured_section'); - add_settings_field('mantra_falign', __('Thumbnails Alignment ','mantra') , 'cryout_setting_falign_fn', __FILE__, 'featured_section'); - add_settings_field('mantra_fsize', __('Thumbnails Size ','mantra') , 'cryout_setting_fsize_fn', __FILE__, 'featured_section'); - add_settings_field('mantra_fheader', __('Featured Images as HEADER Images ','mantra') , 'cryout_setting_fheader_fn', __FILE__, 'featured_section'); + add_settings_field('mantra_fpost', __('Featured Images as POST Thumbnails ','mantra') , 'cryout_setting_fpost_fn', 'mantra-page', 'featured_section'); + add_settings_field('mantra_fauto', __('Auto Select Images From Posts ','mantra') , 'cryout_setting_fauto_fn', 'mantra-page', 'featured_section'); + add_settings_field('mantra_falign', __('Thumbnails Alignment ','mantra') , 'cryout_setting_falign_fn', 'mantra-page', 'featured_section'); + add_settings_field('mantra_fsize', __('Thumbnails Size ','mantra') , 'cryout_setting_fsize_fn', 'mantra-page', 'featured_section'); + add_settings_field('mantra_fheader', __('Featured Images as HEADER Images ','mantra') , 'cryout_setting_fheader_fn', 'mantra-page', 'featured_section'); /*** socials ***/ - add_settings_field('mantra_socials1', __('Link nr. 1','mantra') , 'cryout_setting_socials1_fn', __FILE__, 'socials_section'); - add_settings_field('mantra_socials2', __('Link nr. 2','mantra') , 'cryout_setting_socials2_fn', __FILE__, 'socials_section'); - add_settings_field('mantra_socials3', __('Link nr. 3','mantra') , 'cryout_setting_socials3_fn', __FILE__, 'socials_section'); - add_settings_field('mantra_socials4', __('Link nr. 4','mantra') , 'cryout_setting_socials4_fn', __FILE__, 'socials_section'); - add_settings_field('mantra_socials5', __('Link nr. 5','mantra') , 'cryout_setting_socials5_fn', __FILE__, 'socials_section'); - add_settings_field('mantra_socialshow', __('Socials display','mantra') , 'cryout_setting_socialsdisplay_fn', __FILE__, 'socials_section'); + add_settings_field('mantra_socials1', __('Link nr. 1','mantra') , 'cryout_setting_socials1_fn', 'mantra-page', 'socials_section'); + add_settings_field('mantra_socials2', __('Link nr. 2','mantra') , 'cryout_setting_socials2_fn', 'mantra-page', 'socials_section'); + add_settings_field('mantra_socials3', __('Link nr. 3','mantra') , 'cryout_setting_socials3_fn', 'mantra-page', 'socials_section'); + add_settings_field('mantra_socials4', __('Link nr. 4','mantra') , 'cryout_setting_socials4_fn', 'mantra-page', 'socials_section'); + add_settings_field('mantra_socials5', __('Link nr. 5','mantra') , 'cryout_setting_socials5_fn', 'mantra-page', 'socials_section'); + add_settings_field('mantra_socialshow', __('Socials display','mantra') , 'cryout_setting_socialsdisplay_fn', 'mantra-page', 'socials_section'); /*** misc ***/ - add_settings_field('mantra_seo', __('SEO Settings','mantra') , 'cryout_setting_seo_fn', __FILE__, 'misc_section'); - add_settings_field('mantra_copyright', __('Custom Footer Text','mantra') , 'cryout_setting_copyright_fn', __FILE__, 'misc_section'); - add_settings_field('mantra_customcss', __('Custom CSS','mantra') , 'cryout_setting_customcss_fn', __FILE__, 'misc_section'); - add_settings_field('mantra_customjs', __('Custom JavaScript','mantra') , 'cryout_setting_customjs_fn', __FILE__, 'misc_section'); + add_settings_field('mantra_copyright', __('Custom Footer Text','mantra') , 'cryout_setting_copyright_fn', 'mantra-page', 'misc_section'); + add_settings_field('mantra_customcss', __('Custom CSS','mantra') , 'cryout_setting_customcss_fn', 'mantra-page', 'misc_section'); + add_settings_field('mantra_customjs', __('Custom JavaScript','mantra') , 'cryout_setting_customjs_fn', 'mantra-page', 'misc_section'); } - // Display the admin options page +// Display the admin options page function mantra_page_fn() { - // Load the import form page if the import button has been pressed + // Load the import form page if the import button has been pressed if (isset($_POST['mantra_import'])) { mantra_import_form(); return; } - // Load the import form page after upload button has been pressed + // Load the import form page after upload button has been pressed if (isset($_POST['mantra_import_confirmed'])) { mantra_import_file(); return; } - if (!current_user_can('edit_theme_options')) { - wp_die( __('Sorry, but you do not have sufficient permissions to access this page.','mantra') ); - }?> + if (!current_user_can('edit_theme_options')) { + wp_die( __('Sorry, but you do not have sufficient permissions to access this page.','mantra') ); + } ?>
+

@@ -273,20 +266,11 @@ function mantra_page_fn() { The Parabola Settings page cannot function without jQuery.
-
-
- - -
-
-
- - -
-
- + - Mantra v by Cryout Creations + Mantra v by Cryout Creations
@@ -348,9 +332,10 @@ The Parabola Settings page cannot function without jQuery.
get_item_quantity( 10 ); - $news_items = $mantra_news->get_items( 0, $maxitems ); + $news_items = $mantra_news->get_items( 0, (int)$maxitems ); } ?>
    diff --git a/themes/mantra/admin/sanitize.php b/themes/mantra/admin/sanitize.php index bc25e3a8..a95a7c9e 100644 --- a/themes/mantra/admin/sanitize.php +++ b/themes/mantra/admin/sanitize.php @@ -134,7 +134,6 @@ global $mantra_defaults; $input['mantra_customcss'] = wp_kses_post(trim($input['mantra_customcss'])); $input['mantra_customjs'] = wp_kses_post(trim($input['mantra_customjs'])); - $input['mantra_seo_home_desc'] = wp_kses_post(trim($input['mantra_seo_home_desc'])); $input['mantra_googlefont'] = trim(wp_kses_data($input['mantra_googlefont'])); $input['mantra_googlefonttitle'] = trim(wp_kses_data($input['mantra_googlefonttitle'])); diff --git a/themes/mantra/admin/settings.php b/themes/mantra/admin/settings.php index 3f73a4d4..ed038549 100644 --- a/themes/mantra/admin/settings.php +++ b/themes/mantra/admin/settings.php @@ -257,6 +257,9 @@ foreach($items as $id=>$item) { echo ""; echo "
    ".__("Enable the presentation front-page. This will become your new home page. It has a slider and columns for presentation text and images.
    If you have this enabled but don't see a Presentation page then go to Settings » Reading and make sure you have selected Front Page Displays as Your Latest Posts.","mantra")."
    "; + if ($mantra_options['mantra_frontpage'] == 'Enable' && get_option('show_on_front') != 'posts') { + printf ( '
    '.__('You have enabled the Presentation Page but your WordPress\' Front page displays option is set to use a static page. WordPress guidelines require that the static page option have priority over theme options.
    Go to %1$s and set the Front page displays option to Your latest posts to display the presentation page.',"mantra").'
    ', ' Settings » Reading'); + }; } @@ -673,23 +676,23 @@ echo "
    ".__("Choose the areas to hide on the first page. echo " "; + echo " value='1' id='$items[0]$items[0]' name='ma_options[mantra_fronthideheader]' type='checkbox' /> ".__("Hide the header area (image or background color).","mantra")." "; echo " "; + echo " value='1' id='$items[1]$items[1]' name='ma_options[mantra_fronthidemenu]' type='checkbox' /> ".__("Hide the main menu (the top navigation tabs).","mantra")." "; echo " "; + echo " value='1' id='$items[2]$items[2]' name='ma_options[mantra_fronthidewidget]' type='checkbox' /> ".__("Hide the footer widgets. ","mantra")." "; echo " "; + echo " value='1' id='$items[3]$items[3]' name='ma_options[mantra_fronthidefooter]' type='checkbox' /> ".__("Hide the footer (copyright area).","mantra")." "; echo " "; + echo " value='1' id='$items[4]$items[4]' name='ma_options[mantra_fronthideback]' type='checkbox' /> ".__("Hide the white color. Only the background color remains.","mantra")." "; echo "
"; @@ -1408,9 +1411,9 @@ function cryout_setting_image_fn() { $checkedClass = ($mantra_options['mantra_image']==$item) ? ' checkedClass' : ''; - echo " "; + echo " value='$item' id='$item$item' onClick=\"changeBorder('$item','images');\" name='ma_options[mantra_image]' type='radio' />"; } echo "
".__("The border around your inserted images. ","mantra")."
"; @@ -1859,7 +1862,7 @@ foreach($items as $id=>$item) { echo " "; + echo " value='1' id='$items[0]$items[0]' name='ma_options[mantra_fpostlink]' type='checkbox' /> Link the thumbail to the post "; echo "
".__("Show featured images as thumbnails on posts. The images must be selected for each post in the Featured Image section.","mantra")."
"; @@ -1907,7 +1910,7 @@ function cryout_setting_fsize_fn() { echo " "; + echo " value='1' id='mantra_fcrop' name='ma_options[mantra_fcrop]' type='checkbox' /> Crop images to exact size. "; echo "
".__("The size you want the thumbnails to have (in pixels). By default imges will be scaled with aspect ratio kept. Choose to crop the images if you want the exact size.","mantra")."
"; @@ -2005,19 +2008,19 @@ global $mantra_options; echo " "; + echo " value='1' id='$items[0]$items[0]' name='ma_options[mantra_socialsdisplay0]' type='checkbox' /> Top right corner of header "; echo " "; + echo " value='1' id='$items[1]$items[1]' name='ma_options[mantra_socialsdisplay1]' type='checkbox' /> Under menu - left side "; echo " "; + echo " value='1' id='$items[2]$items[2]' name='ma_options[mantra_socialsdisplay2]' type='checkbox' /> Under menu - right side "; echo " "; + echo " value='1' id='$items[3]$items[3]' name='ma_options[mantra_socialsdisplay3]' type='checkbox' /> In the footer (smaller icons) "; @@ -2051,58 +2054,4 @@ function cryout_setting_customjs_fn() { echo ""; echo "
".__("Insert your custom Javascript code here. (Google Analytics and any other forms of Analytic software).
The <script> tags are not needed.","mantra")."
"; } -function cryout_setting_seo_fn() { - global $mantra_options; - $items = array ("Enable" , "Disable"); - $itemsare = array( __("Enable","mantra"), __("Disable","mantra")); - echo ""; - echo "
".__("Enable Mantra's Search Engine Optimization. This is enabled by default and should only be disabled if you are using a SEO plugin.","mantra")."
"; - echo "
".__("All title tags are handled automatically by Mantra.","mantra").""; - - echo "
"; - echo "".__("Homepage Meta Description","mantra").""; - echo ""; - echo "".__("This is unique and you should fill this in. Describe your site the best you can and try not to go over 160 characters.","mantra").""; - echo "
"; - - echo "
"; - echo " Meta Descriptions for all other pages: "; - $moreitems = array ("Auto" , "Manual"); - $moreitemsare = array( __("Auto","mantra"), __("Manual","mantra")); - echo ""; - echo "".__("Auto - Mantra will automatically add post expcerpts to 'page' and 'post' meta descriptions.
- Manual - you will enable a new custom field in your post/page admin section where you can type the exact description you want for every post and page.
- For category pages, the actual category descriptions will be used. Go to Posts > Categories and you can fill in a description for every category you have.","mantra")."
"; - echo "
"; - - echo "
"; - echo "".__("Post Author","mantra").""; - $authors=wp_list_authors (array("echo"=>false,"html"=> false)); - $authors_array = explode ("," , $authors); - array_unshift($authors_array,__("Do not use","mantra")); - echo ""; - - - echo "".__("If you want to show an author in the meta tags.","mantra").""; - echo "
"; - -} ?> \ No newline at end of file diff --git a/themes/mantra/functions.php b/themes/mantra/functions.php index 19301e73..c23cef67 100644 --- a/themes/mantra/functions.php +++ b/themes/mantra/functions.php @@ -1,25 +1,26 @@ \ No newline at end of file diff --git a/themes/mantra/includes/tgm.php b/themes/mantra/includes/tgm.php new file mode 100644 index 00000000..cf9d89b8 --- /dev/null +++ b/themes/mantra/includes/tgm.php @@ -0,0 +1,3671 @@ + 'Cryout Serious Theme Settings', + 'slug' => 'cryout-theme-settings', + 'required' => false, + 'version' => '0.5.6', + //'force_activation' => true, + //'force_deactivation' => true, + ), + + ); + + $config = array( + 'default_path' => '', // Default absolute path to pre-packaged plugins. + 'menu' => 'mantra-extra-plugins', // Menu slug. + 'has_notices' => true, // Show admin notices or not. + 'dismissable' => true, // If false, a user cannot dismiss the nag message. + 'dismiss_msg' => '', // If 'dismissable' is false, this message will be output at top of nag. + 'is_automatic' => true, // Automatically activate plugins after installation or not. + 'message' => '', // Message to output right before the plugins table. + 'strings' => array( + 'page_title' => __( 'Recommended Plugins', 'cryout' ), + 'menu_title' => ucwords(_CRYOUT_THEME_NAME) . __( ' Plugins', 'cryout' ), + 'installing' => __( 'Installing Plugin: %s', 'cryout' ), // %s = plugin name. + 'oops' => __( 'Something went wrong with the plugin API.', 'cryout' ), + 'notice_can_install_required' => _n_noop( ucwords(_CRYOUT_THEME_NAME) . ' requires the following plugin: %1$s.', ucwords(_CRYOUT_THEME_NAME) . ' requires the following plugins: %1$s.', 'cryout' ), // %1$s = plugin name(s). + 'notice_can_install_recommended' => _n_noop( ucwords(_CRYOUT_THEME_NAME) . ' recommends the following plugin: %1$s.', ucwords(_CRYOUT_THEME_NAME) . ' recommends the following plugins: %1$s.', 'cryout' ), // %1$s = plugin name(s). + 'notice_cannot_install' => _n_noop( 'Sorry, but you do not have the correct permissions to install the %s plugin. Contact the administrator of this site for help on getting the plugin installed.', 'Sorry, but you do not have the correct permissions to install the %s plugins. Contact the administrator of this site for help on getting the plugins installed.', 'cryout' ), // %1$s = plugin name(s). + 'notice_can_activate_required' => _n_noop( 'The following required plugin is currently inactive: %1$s.', 'The following required plugins are currently inactive: %1$s.', 'cryout' ), // %1$s = plugin name(s). + 'notice_can_activate_recommended' => _n_noop( 'The following recommended plugin is currently inactive: %1$s.', 'The following recommended plugins are currently inactive: %1$s.', 'cryout' ), // %1$s = plugin name(s). + 'notice_cannot_activate' => _n_noop( 'Sorry, but you do not have the correct permissions to activate the %s plugin. Contact the administrator of this site for help on getting the plugin activated.', 'Sorry, but you do not have the correct permissions to activate the %s plugins. Contact the administrator of this site for help on getting the plugins activated.', 'cryout' ), // %1$s = plugin name(s). + 'notice_ask_to_update' => _n_noop( 'The following plugin needs to be updated to its latest version to ensure maximum compatibility with this theme: %1$s.', 'The following plugins need to be updated to their latest version to ensure maximum compatibility with this theme: %1$s.', 'cryout' ), // %1$s = plugin name(s). + 'notice_cannot_update' => _n_noop( 'Sorry, but you do not have the correct permissions to update the %s plugin. Contact the administrator of this site for help on getting the plugin updated.', 'Sorry, but you do not have the correct permissions to update the %s plugins. Contact the administrator of this site for help on getting the plugins updated.', 'cryout' ), // %1$s = plugin name(s). + 'install_link' => _n_noop( 'Begin installing plugin', 'Begin installing plugins', 'cryout' ), + 'activate_link' => _n_noop( 'Begin activating plugin', 'Begin activating plugins', 'cryout' ), + 'return' => __( 'Return to Required Plugins Installer', 'cryout' ), + 'plugin_activated' => __( 'Plugin activated successfully.', 'cryout' ), + 'complete' => __( 'All plugins installed and activated successfully. %s', 'cryout' ), // %s = dashboard link. + 'nag_type' => 'updated' // Determines admin notice type - can only be 'updated', 'update-nag' or 'error'. + ) + ); + + tgmpa( $plugins, $config ); + +} + + +/***************** TGM class below *******************/ + +/** + * Plugin installation and activation for WordPress themes. + * + * Please note that this is a drop-in library for a theme or plugin. + * The authors of this library (Thomas, Gary and Juliette) are NOT responsible + * for the support of your plugin or theme. Please contact the plugin + * or theme author for support. + * + * @package TGM-Plugin-Activation + * @version 2.5.2 + * @link http://tgmpluginactivation.com/ + * @author Thomas Griffin, Gary Jones, Juliette Reinders Folmer + * @copyright Copyright (c) 2011, Thomas Griffin + * @license GPL-2.0+ + * + * @wordpress-plugin + * Plugin Name: TGM Plugin Activation + * Plugin URI: + * Description: Plugin installation and activation for WordPress themes. + * Version: 2.5.2 + * Author: Thomas Griffin, Gary Jones, Juliette Reinders Folmer + * Author URI: http://tgmpluginactivation.com/ + * Text Domain: tgmpa + * Domain Path: /languages/ + * Copyright: 2011, Thomas Griffin + */ + +/* + Copyright 2011 Thomas Griffin (thomasgriffinmedia.com) + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License, version 2, as + published by the Free Software Foundation. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +*/ + +if ( ! class_exists( 'TGM_Plugin_Activation' ) ) { + + /** + * Automatic plugin installation and activation library. + * + * Creates a way to automatically install and activate plugins from within themes. + * The plugins can be either bundled, downloaded from the WordPress + * Plugin Repository or downloaded from another external source. + * + * @since 1.0.0 + * + * @package TGM-Plugin-Activation + * @author Thomas Griffin + * @author Gary Jones + */ + class TGM_Plugin_Activation { + /** + * TGMPA version number. + * + * @since 2.5.0 + * + * @const string Version number. + */ + const TGMPA_VERSION = '2.5.2'; + + /** + * Regular expression to test if a URL is a WP plugin repo URL. + * + * @const string Regex. + * + * @since 2.5.0 + */ + const WP_REPO_REGEX = '|^http[s]?://wordpress\.org/(?:extend/)?plugins/|'; + + /** + * Arbitrary regular expression to test if a string starts with a URL. + * + * @const string Regex. + * + * @since 2.5.0 + */ + const IS_URL_REGEX = '|^http[s]?://|'; + + /** + * Holds a copy of itself, so it can be referenced by the class name. + * + * @since 1.0.0 + * + * @var TGM_Plugin_Activation + */ + public static $instance; + + /** + * Holds arrays of plugin details. + * + * @since 1.0.0 + * + * @since 2.5.0 the array has the plugin slug as an associative key. + * + * @var array + */ + public $plugins = array(); + + /** + * Holds arrays of plugin names to use to sort the plugins array. + * + * @since 2.5.0 + * + * @var array + */ + protected $sort_order = array(); + + /** + * Whether any plugins have the 'force_activation' setting set to true. + * + * @since 2.5.0 + * + * @var bool + */ + protected $has_forced_activation = false; + + /** + * Whether any plugins have the 'force_deactivation' setting set to true. + * + * @since 2.5.0 + * + * @var bool + */ + protected $has_forced_deactivation = false; + + /** + * Name of the unique ID to hash notices. + * + * @since 2.4.0 + * + * @var string + */ + public $id = 'tgmpa'; + + /** + * Name of the query-string argument for the admin page. + * + * @since 1.0.0 + * + * @var string + */ + protected $menu = 'tgmpa-install-plugins'; + + /** + * Parent menu file slug. + * + * @since 2.5.0 + * + * @var string + */ + public $parent_slug = 'themes.php'; + + /** + * Capability needed to view the plugin installation menu item. + * + * @since 2.5.0 + * + * @var string + */ + public $capability = 'edit_theme_options'; + + /** + * Default absolute path to folder containing bundled plugin zip files. + * + * @since 2.0.0 + * + * @var string Absolute path prefix to zip file location for bundled plugins. Default is empty string. + */ + public $default_path = ''; + + /** + * Flag to show admin notices or not. + * + * @since 2.1.0 + * + * @var boolean + */ + public $has_notices = true; + + /** + * Flag to determine if the user can dismiss the notice nag. + * + * @since 2.4.0 + * + * @var boolean + */ + public $dismissable = true; + + /** + * Message to be output above nag notice if dismissable is false. + * + * @since 2.4.0 + * + * @var string + */ + public $dismiss_msg = ''; + + /** + * Flag to set automatic activation of plugins. Off by default. + * + * @since 2.2.0 + * + * @var boolean + */ + public $is_automatic = false; + + /** + * Optional message to display before the plugins table. + * + * @since 2.2.0 + * + * @var string Message filtered by wp_kses_post(). Default is empty string. + */ + public $message = ''; + + /** + * Holds configurable array of strings. + * + * Default values are added in the constructor. + * + * @since 2.0.0 + * + * @var array + */ + public $strings = array(); + + /** + * Holds the version of WordPress. + * + * @since 2.4.0 + * + * @var int + */ + public $wp_version; + + /** + * Holds the hook name for the admin page. + * + * @since 2.5.0 + * + * @var string + */ + public $page_hook; + + /** + * Adds a reference of this object to $instance, populates default strings, + * does the tgmpa_init action hook, and hooks in the interactions to init. + * + * @internal This method should be `protected`, but as too many TGMPA implementations + * haven't upgraded beyond v2.3.6 yet, this gives backward compatibility issues. + * Reverted back to public for the time being. + * + * @since 1.0.0 + * + * @see TGM_Plugin_Activation::init() + */ + public function __construct() { + // Set the current WordPress version. + $this->wp_version = $GLOBALS['wp_version']; + + // Announce that the class is ready, and pass the object (for advanced use). + do_action_ref_array( 'tgmpa_init', array( $this ) ); + + // When the rest of WP has loaded, kick-start the rest of the class. + add_action( 'init', array( $this, 'init' ) ); + } + + /** + * Magic method to (not) set protected properties from outside of this class. + * + * @internal hackedihack... There is a serious bug in v2.3.2 - 2.3.6 where the `menu` property + * is being assigned rather than tested in a conditional, effectively rendering it useless. + * This 'hack' prevents this from happening. + * + * @see https://github.com/TGMPA/TGM-Plugin-Activation/blob/2.3.6/tgm-plugin-activation/class-tgm-plugin-activation.php#L1593 + * + * @param string $name Name of an inaccessible property. + * @param mixed $value Value to assign to the property. + * @return void Silently fail to set the property when this is tried from outside of this class context. + * (Inside this class context, the __set() method if not used as there is direct access.) + */ + public function __set( $name, $value ) { + return; + } + + /** + * Magic method to get the value of a protected property outside of this class context. + * + * @param string $name Name of an inaccessible property. + * @return mixed The property value. + */ + public function __get( $name ) { + return $this->{$name}; + } + + /** + * Initialise the interactions between this class and WordPress. + * + * Hooks in three new methods for the class: admin_menu, notices and styles. + * + * @since 2.0.0 + * + * @see TGM_Plugin_Activation::admin_menu() + * @see TGM_Plugin_Activation::notices() + * @see TGM_Plugin_Activation::styles() + */ + public function init() { + /** + * By default TGMPA only loads on the WP back-end and not in an Ajax call. Using this filter + * you can overrule that behaviour. + * + * @since 2.5.0 + * + * @param bool $load Whether or not TGMPA should load. + * Defaults to the return of `is_admin() && ! defined( 'DOING_AJAX' )`. + */ + if ( true !== apply_filters( 'tgmpa_load', ( is_admin() && ! defined( 'DOING_AJAX' ) ) ) ) { + return; + } + + // Load class strings. + $this->strings = array( + 'page_title' => __( 'Install Required Plugins', 'cryout' ), + 'menu_title' => __( 'Install Plugins', 'cryout' ), + 'installing' => __( 'Installing Plugin: %s', 'cryout' ), + 'oops' => __( 'Something went wrong with the plugin API.', 'cryout' ), + 'notice_can_install_required' => _n_noop( + 'This theme requires the following plugin: %1$s.', + 'This theme requires the following plugins: %1$s.', + 'cryout' + ), + 'notice_can_install_recommended' => _n_noop( + 'This theme recommends the following plugin: %1$s.', + 'This theme recommends the following plugins: %1$s.', + 'cryout' + ), + 'notice_cannot_install' => _n_noop( + 'Sorry, but you do not have the correct permissions to install the %1$s plugin.', + 'Sorry, but you do not have the correct permissions to install the %1$s plugins.', + 'cryout' + ), + 'notice_ask_to_update' => _n_noop( + 'The following plugin needs to be updated to its latest version to ensure maximum compatibility with this theme: %1$s.', + 'The following plugins need to be updated to their latest version to ensure maximum compatibility with this theme: %1$s.', + 'cryout' + ), + 'notice_ask_to_update_maybe' => _n_noop( + 'There is an update available for: %1$s.', + 'There are updates available for the following plugins: %1$s.', + 'cryout' + ), + 'notice_cannot_update' => _n_noop( + 'Sorry, but you do not have the correct permissions to update the %1$s plugin.', + 'Sorry, but you do not have the correct permissions to update the %1$s plugins.', + 'cryout' + ), + 'notice_can_activate_required' => _n_noop( + 'The following required plugin is currently inactive: %1$s.', + 'The following required plugins are currently inactive: %1$s.', + 'cryout' + ), + 'notice_can_activate_recommended' => _n_noop( + 'The following recommended plugin is currently inactive: %1$s.', + 'The following recommended plugins are currently inactive: %1$s.', + 'cryout' + ), + 'notice_cannot_activate' => _n_noop( + 'Sorry, but you do not have the correct permissions to activate the %1$s plugin.', + 'Sorry, but you do not have the correct permissions to activate the %1$s plugins.', + 'cryout' + ), + 'install_link' => _n_noop( + 'Begin installing plugin', + 'Begin installing plugins', + 'cryout' + ), + 'update_link' => _n_noop( + 'Begin updating plugin', + 'Begin updating plugins', + 'cryout' + ), + 'activate_link' => _n_noop( + 'Begin activating plugin', + 'Begin activating plugins', + 'cryout' + ), + 'return' => __( 'Return to Required Plugins Installer', 'cryout' ), + 'dashboard' => __( 'Return to the dashboard', 'cryout' ), + 'plugin_activated' => __( 'Plugin activated successfully.', 'cryout' ), + 'activated_successfully' => __( 'The following plugin was activated successfully:', 'cryout' ), + 'plugin_already_active' => __( 'No action taken. Plugin %1$s was already active.', 'cryout' ), + 'plugin_needs_higher_version' => __( 'Plugin not activated. A higher version of %s is needed for this theme. Please update the plugin.', 'cryout' ), + 'complete' => __( 'All plugins installed and activated successfully. %1$s', 'cryout' ), + 'dismiss' => __( 'Dismiss this notice', 'cryout' ), + 'contact_admin' => __( 'Please contact the administrator of this site for help.', 'cryout' ), + ); + + do_action( 'tgmpa_register' ); + + /* After this point, the plugins should be registered and the configuration set. */ + + // Proceed only if we have plugins to handle. + if ( empty( $this->plugins ) || ! is_array( $this->plugins ) ) { + return; + } + + // Set up the menu and notices if we still have outstanding actions. + if ( true !== $this->is_tgmpa_complete() ) { + // Sort the plugins. + array_multisort( $this->sort_order, SORT_ASC, $this->plugins ); + + add_action( 'admin_menu', array( $this, 'admin_menu' ) ); + add_action( 'admin_head', array( $this, 'dismiss' ) ); + + // Prevent the normal links from showing underneath a single install/update page. + add_filter( 'install_plugin_complete_actions', array( $this, 'actions' ) ); + add_filter( 'update_plugin_complete_actions', array( $this, 'actions' ) ); + + if ( $this->has_notices ) { + add_action( 'admin_notices', array( $this, 'notices' ) ); + add_action( 'admin_init', array( $this, 'admin_init' ), 1 ); + add_action( 'admin_enqueue_scripts', array( $this, 'thickbox' ) ); + } + + add_action( 'load-plugins.php', array( $this, 'add_plugin_action_link_filters' ), 1 ); + } + + // Make sure things get reset on switch theme. + add_action( 'switch_theme', array( $this, 'flush_plugins_cache' ) ); + + if ( $this->has_notices ) { + add_action( 'switch_theme', array( $this, 'update_dismiss' ) ); + } + + // Setup the force activation hook. + if ( true === $this->has_forced_activation ) { + add_action( 'admin_init', array( $this, 'force_activation' ) ); + } + + // Setup the force deactivation hook. + if ( true === $this->has_forced_deactivation ) { + add_action( 'switch_theme', array( $this, 'force_deactivation' ) ); + } + } + + /** + * Prevent activation of plugins which don't meet the minimum version requirement from the + * WP native plugins page. + * + * @since 2.5.0 + */ + public function add_plugin_action_link_filters() { + foreach ( $this->plugins as $slug => $plugin ) { + if ( false === $this->can_plugin_activate( $slug ) ) { + add_filter( 'plugin_action_links_' . $plugin['file_path'], array( $this, 'filter_plugin_action_links_activate' ), 20 ); + } + + if ( true === $plugin['force_activation'] ) { + add_filter( 'plugin_action_links_' . $plugin['file_path'], array( $this, 'filter_plugin_action_links_deactivate' ), 20 ); + } + + if ( false !== $this->does_plugin_require_update( $slug ) ) { + add_filter( 'plugin_action_links_' . $plugin['file_path'], array( $this, 'filter_plugin_action_links_update' ), 20 ); + } + } + } + + /** + * Remove the 'Activate' link on the WP native plugins page if the plugin does not meet the + * minimum version requirements. + * + * @since 2.5.0 + * + * @param array $actions Action links. + * @return array + */ + public function filter_plugin_action_links_activate( $actions ) { + unset( $actions['activate'] ); + + return $actions; + } + + /** + * Remove the 'Deactivate' link on the WP native plugins page if the plugin has been set to force activate. + * + * @since 2.5.0 + * + * @param array $actions Action links. + * @return array + */ + public function filter_plugin_action_links_deactivate( $actions ) { + unset( $actions['deactivate'] ); + + return $actions; + } + + /** + * Add a 'Requires update' link on the WP native plugins page if the plugin does not meet the + * minimum version requirements. + * + * @since 2.5.0 + * + * @param array $actions Action links. + * @return array + */ + public function filter_plugin_action_links_update( $actions ) { + $actions['update'] = sprintf( + '%3$s', + esc_url( $this->get_tgmpa_status_url( 'update' ) ), + esc_attr__( 'This plugin needs to be updated to be compatible with your theme.', 'cryout' ), + esc_html__( 'Update Required', 'cryout' ) + ); + + return $actions; + } + + /** + * Handles calls to show plugin information via links in the notices. + * + * We get the links in the admin notices to point to the TGMPA page, rather + * than the typical plugin-install.php file, so we can prepare everything + * beforehand. + * + * WP does not make it easy to show the plugin information in the thickbox - + * here we have to require a file that includes a function that does the + * main work of displaying it, enqueue some styles, set up some globals and + * finally call that function before exiting. + * + * Down right easy once you know how... + * + * Returns early if not the TGMPA page. + * + * @since 2.1.0 + * + * @global string $tab Used as iframe div class names, helps with styling + * @global string $body_id Used as the iframe body ID, helps with styling + * + * @return null Returns early if not the TGMPA page. + */ + public function admin_init() { + if ( ! $this->is_tgmpa_page() ) { + return; + } + + if ( isset( $_REQUEST['tab'] ) && 'plugin-information' === $_REQUEST['tab'] ) { + // Needed for install_plugin_information(). + require_once ABSPATH . 'wp-admin/includes/plugin-install.php'; + + wp_enqueue_style( 'plugin-install' ); + + global $tab, $body_id; + $body_id = 'plugin-information'; + // @codingStandardsIgnoreStart + $tab = 'plugin-information'; + // @codingStandardsIgnoreEnd + + install_plugin_information(); + + exit; + } + } + + /** + * Enqueue thickbox scripts/styles for plugin info. + * + * Thickbox is not automatically included on all admin pages, so we must + * manually enqueue it for those pages. + * + * Thickbox is only loaded if the user has not dismissed the admin + * notice or if there are any plugins left to install and activate. + * + * @since 2.1.0 + */ + public function thickbox() { + if ( ! get_user_meta( get_current_user_id(), 'tgmpa_dismissed_notice_' . $this->id, true ) ) { + add_thickbox(); + } + } + + /** + * Adds submenu page if there are plugin actions to take. + * + * This method adds the submenu page letting users know that a required + * plugin needs to be installed. + * + * This page disappears once the plugin has been installed and activated. + * + * @since 1.0.0 + * + * @see TGM_Plugin_Activation::init() + * @see TGM_Plugin_Activation::install_plugins_page() + * + * @return null Return early if user lacks capability to install a plugin. + */ + public function admin_menu() { + // Make sure privileges are correct to see the page. + if ( ! current_user_can( 'install_plugins' ) ) { + return; + } + + $args = apply_filters( + 'tgmpa_admin_menu_args', + array( + 'parent_slug' => $this->parent_slug, // Parent Menu slug. + 'page_title' => $this->strings['page_title'], // Page title. + 'menu_title' => $this->strings['menu_title'], // Menu title. + 'capability' => $this->capability, // Capability. + 'menu_slug' => $this->menu, // Menu slug. + 'function' => array( $this, 'install_plugins_page' ), // Callback. + ) + ); + + $this->add_admin_menu( $args ); + } + + /** + * Add the menu item. + * + * @since 2.5.0 + * + * @param array $args Menu item configuration. + */ + protected function add_admin_menu( array $args ) { + if ( has_filter( 'tgmpa_admin_menu_use_add_theme_page' ) ) { + _deprecated_function( 'The "tgmpa_admin_menu_use_add_theme_page" filter', '2.5.0', esc_html__( 'Set the parent_slug config variable instead.', 'cryout' ) ); + } + + // modified to pass theme check requirement + $this->page_hook = call_user_func( 'add_theme_page', $args['page_title'], $args['menu_title'], $args['capability'], $args['menu_slug'], $args['function'] ); + } + + /** + * Echoes plugin installation form. + * + * This method is the callback for the admin_menu method function. + * This displays the admin page and form area where the user can select to install and activate the plugin. + * Aborts early if we're processing a plugin installation action. + * + * @since 1.0.0 + * + * @return null Aborts early if we're processing a plugin installation action. + */ + public function install_plugins_page() { + // Store new instance of plugin table in object. + $plugin_table = new TGMPA_List_Table; + + // Return early if processing a plugin installation action. + if ( ( ( 'tgmpa-bulk-install' === $plugin_table->current_action() || 'tgmpa-bulk-update' === $plugin_table->current_action() ) && $plugin_table->process_bulk_actions() ) || $this->do_plugin_install() ) { + return; + } + + // Force refresh of available plugin information so we'll know about manual updates/deletes. + wp_clean_plugins_cache( false ); + + ?> +
+

+ prepare_items(); ?> + + message ) && is_string( $this->message ) ) { + echo wp_kses_post( $this->message ); + } + ?> + views(); ?> + +
+ + + display(); ?> +
+
+ sanitize_key( urldecode( $_GET['plugin'] ) ); + + if ( ! isset( $this->plugins[ $slug ] ) ) { + return false; + } + + // Was an install or upgrade action link clicked? + if ( ( isset( $_GET['tgmpa-install'] ) && 'install-plugin' === $_GET['tgmpa-install'] ) || ( isset( $_GET['tgmpa-update'] ) && 'update-plugin' === $_GET['tgmpa-update'] ) ) { + + $install_type = 'install'; + if ( isset( $_GET['tgmpa-update'] ) && 'update-plugin' === $_GET['tgmpa-update'] ) { + $install_type = 'update'; + } + + check_admin_referer( 'tgmpa-' . $install_type, 'tgmpa-nonce' ); + + // Pass necessary information via URL if WP_Filesystem is needed. + $url = wp_nonce_url( + add_query_arg( + array( + 'plugin' => urlencode( $slug ), + 'tgmpa-' . $install_type => $install_type . '-plugin', + ), + $this->get_tgmpa_url() + ), + 'tgmpa-' . $install_type, + 'tgmpa-nonce' + ); + + $method = ''; // Leave blank so WP_Filesystem can populate it as necessary. + + if ( false === ( $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, array() ) ) ) { + return true; + } + + if ( ! WP_Filesystem( $creds ) ) { + request_filesystem_credentials( esc_url_raw( $url ), $method, true, false, array() ); // Setup WP_Filesystem. + return true; + } + + /* If we arrive here, we have the filesystem. */ + + // Prep variables for Plugin_Installer_Skin class. + $extra = array(); + $extra['slug'] = $slug; // Needed for potentially renaming of directory name. + $source = $this->get_download_url( $slug ); + $api = ( 'repo' === $this->plugins[ $slug ]['source_type'] ) ? $this->get_plugins_api( $slug ) : null; + $api = ( false !== $api ) ? $api : null; + + $url = add_query_arg( + array( + 'action' => $install_type . '-plugin', + 'plugin' => urlencode( $slug ), + ), + 'update.php' + ); + + if ( ! class_exists( 'Plugin_Upgrader', false ) ) { + require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php'; + } + + $skin_args = array( + 'type' => ( 'bundled' !== $this->plugins[ $slug ]['source_type'] ) ? 'web' : 'upload', + 'title' => sprintf( $this->strings['installing'], $this->plugins[ $slug ]['name'] ), + 'url' => esc_url_raw( $url ), + 'nonce' => $install_type . '-plugin_' . $slug, + 'plugin' => '', + 'api' => $api, + 'extra' => $extra, + ); + + if ( 'update' === $install_type ) { + $skin_args['plugin'] = $this->plugins[ $slug ]['file_path']; + $skin = new Plugin_Upgrader_Skin( $skin_args ); + } else { + $skin = new Plugin_Installer_Skin( $skin_args ); + } + + // Create a new instance of Plugin_Upgrader. + $upgrader = new Plugin_Upgrader( $skin ); + + // Perform the action and install the plugin from the $source urldecode(). + add_filter( 'upgrader_source_selection', array( $this, 'maybe_adjust_source_dir' ), 1, 3 ); + + if ( 'update' === $install_type ) { + // Inject our info into the update transient. + $to_inject = array( $slug => $this->plugins[ $slug ] ); + $to_inject[ $slug ]['source'] = $source; + $this->inject_update_info( $to_inject ); + + $upgrader->upgrade( $this->plugins[ $slug ]['file_path'] ); + } else { + $upgrader->install( $source ); + } + + remove_filter( 'upgrader_source_selection', array( $this, 'maybe_adjust_source_dir' ), 1, 3 ); + + // Make sure we have the correct file path now the plugin is installed/updated. + $this->populate_file_path( $slug ); + + // Only activate plugins if the config option is set to true and the plugin isn't + // already active (upgrade). + if ( $this->is_automatic && ! $this->is_plugin_active( $slug ) ) { + $plugin_activate = $upgrader->plugin_info(); // Grab the plugin info from the Plugin_Upgrader method. + if ( false === $this->activate_single_plugin( $plugin_activate, $slug, true ) ) { + return true; // Finish execution of the function early as we encountered an error. + } + } + + $this->show_tgmpa_version(); + + // Display message based on if all plugins are now active or not. + if ( $this->is_tgmpa_complete() ) { + echo '

', sprintf( esc_html( $this->strings['complete'] ), '' . esc_html__( 'Return to the Dashboard', 'cryout' ) . '' ), '

'; + echo ''; + } else { + echo '

', esc_html( $this->strings['return'] ), '

'; + } + + return true; + } elseif ( isset( $this->plugins[ $slug ]['file_path'], $_GET['tgmpa-activate'] ) && 'activate-plugin' === $_GET['tgmpa-activate'] ) { + // Activate action link was clicked. + check_admin_referer( 'tgmpa-activate', 'tgmpa-nonce' ); + + if ( false === $this->activate_single_plugin( $this->plugins[ $slug ]['file_path'], $slug ) ) { + return true; // Finish execution of the function early as we encountered an error. + } + } + + return false; + } + + /** + * Inject information into the 'update_plugins' site transient as WP checks that before running an update. + * + * @since 2.5.0 + * + * @param array $plugins The plugin information for the plugins which are to be updated. + */ + public function inject_update_info( $plugins ) { + $repo_updates = get_site_transient( 'update_plugins' ); + + if ( ! is_object( $repo_updates ) ) { + $repo_updates = new stdClass; + } + + foreach ( $plugins as $slug => $plugin ) { + $file_path = $plugin['file_path']; + + if ( empty( $repo_updates->response[ $file_path ] ) ) { + $repo_updates->response[ $file_path ] = new stdClass; + } + + // We only really need to set package, but let's do all we can in case WP changes something. + $repo_updates->response[ $file_path ]->slug = $slug; + $repo_updates->response[ $file_path ]->plugin = $file_path; + $repo_updates->response[ $file_path ]->new_version = $plugin['version']; + $repo_updates->response[ $file_path ]->package = $plugin['source']; + if ( empty( $repo_updates->response[ $file_path ]->url ) && ! empty( $plugin['external_url'] ) ) { + $repo_updates->response[ $file_path ]->url = $plugin['external_url']; + } + } + + set_site_transient( 'update_plugins', $repo_updates ); + } + + /** + * Adjust the plugin directory name if necessary. + * + * The final destination directory of a plugin is based on the subdirectory name found in the + * (un)zipped source. In some cases - most notably GitHub repository plugin downloads -, this + * subdirectory name is not the same as the expected slug and the plugin will not be recognized + * as installed. This is fixed by adjusting the temporary unzipped source subdirectory name to + * the expected plugin slug. + * + * @since 2.5.0 + * + * @param string $source Path to upgrade/zip-file-name.tmp/subdirectory/. + * @param string $remote_source Path to upgrade/zip-file-name.tmp. + * @param \WP_Upgrader $upgrader Instance of the upgrader which installs the plugin. + * @return string $source + */ + public function maybe_adjust_source_dir( $source, $remote_source, $upgrader ) { + if ( ! $this->is_tgmpa_page() || ! is_object( $GLOBALS['wp_filesystem'] ) ) { + return $source; + } + + // Check for single file plugins. + $source_files = array_keys( $GLOBALS['wp_filesystem']->dirlist( $remote_source ) ); + if ( 1 === count( $source_files ) && false === $GLOBALS['wp_filesystem']->is_dir( $source ) ) { + return $source; + } + + // Multi-file plugin, let's see if the directory is correctly named. + $desired_slug = ''; + + // Figure out what the slug is supposed to be. + if ( false === $upgrader->bulk && ! empty( $upgrader->skin->options['extra']['slug'] ) ) { + $desired_slug = $upgrader->skin->options['extra']['slug']; + } else { + // Bulk installer contains less info, so fall back on the info registered here. + foreach ( $this->plugins as $slug => $plugin ) { + if ( ! empty( $upgrader->skin->plugin_names[ $upgrader->skin->i ] ) && $plugin['name'] === $upgrader->skin->plugin_names[ $upgrader->skin->i ] ) { + $desired_slug = $slug; + break; + } + } + unset( $slug, $plugin ); + } + + if ( ! empty( $desired_slug ) ) { + $subdir_name = untrailingslashit( str_replace( trailingslashit( $remote_source ), '', $source ) ); + + if ( ! empty( $subdir_name ) && $subdir_name !== $desired_slug ) { + $from = untrailingslashit( $source ); + $to = trailingslashit( $remote_source ) . $desired_slug; + + if ( true === $GLOBALS['wp_filesystem']->move( $from, $to ) ) { + return trailingslashit( $to ); + } else { + return new WP_Error( 'rename_failed', esc_html__( 'The remote plugin package does not contain a folder with the desired slug and renaming did not work.', 'cryout' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'cryout' ), array( 'found' => $subdir_name, 'expected' => $desired_slug ) ); + } + } elseif ( empty( $subdir_name ) ) { + return new WP_Error( 'packaged_wrong', esc_html__( 'The remote plugin package consists of more than one file, but the files are not packaged in a folder.', 'cryout' ) . ' ' . esc_html__( 'Please contact the plugin provider and ask them to package their plugin according to the WordPress guidelines.', 'cryout' ), array( 'found' => $subdir_name, 'expected' => $desired_slug ) ); + } + } + + return $source; + } + + /** + * Activate a single plugin and send feedback about the result to the screen. + * + * @since 2.5.0 + * + * @param string $file_path Path within wp-plugins/ to main plugin file. + * @param string $slug Plugin slug. + * @param bool $automatic Whether this is an automatic activation after an install. Defaults to false. + * This determines the styling of the output messages. + * @return bool False if an error was encountered, true otherwise. + */ + protected function activate_single_plugin( $file_path, $slug, $automatic = false ) { + if ( $this->can_plugin_activate( $slug ) ) { + $activate = activate_plugin( $file_path ); + + if ( is_wp_error( $activate ) ) { + echo '

', wp_kses_post( $activate->get_error_message() ), '

', + '

', esc_html( $this->strings['return'] ), '

'; + + return false; // End it here if there is an error with activation. + } else { + if ( ! $automatic ) { + // Make sure message doesn't display again if bulk activation is performed + // immediately after a single activation. + if ( ! isset( $_POST['action'] ) ) { // WPCS: CSRF OK. + echo '

', esc_html( $this->strings['activated_successfully'] ), ' ', esc_html( $this->plugins[ $slug ]['name'] ), '.

'; + } + } else { + // Simpler message layout for use on the plugin install page. + echo '

', esc_html( $this->strings['plugin_activated'] ), '

'; + } + } + } elseif ( $this->is_plugin_active( $slug ) ) { + // No simpler message format provided as this message should never be encountered + // on the plugin install page. + echo '

', + sprintf( + esc_html( $this->strings['plugin_already_active'] ), + '' . esc_html( $this->plugins[ $slug ]['name'] ) . '' + ), + '

'; + } elseif ( $this->does_plugin_require_update( $slug ) ) { + if ( ! $automatic ) { + // Make sure message doesn't display again if bulk activation is performed + // immediately after a single activation. + if ( ! isset( $_POST['action'] ) ) { // WPCS: CSRF OK. + echo '

', + sprintf( + esc_html( $this->strings['plugin_needs_higher_version'] ), + '' . esc_html( $this->plugins[ $slug ]['name'] ) . '' + ), + '

'; + } + } else { + // Simpler message layout for use on the plugin install page. + echo '

', sprintf( esc_html( $this->strings['plugin_needs_higher_version'] ), esc_html( $this->plugins[ $slug ]['name'] ) ), '

'; + } + } + + return true; + } + + /** + * Echoes required plugin notice. + * + * Outputs a message telling users that a specific plugin is required for + * their theme. If appropriate, it includes a link to the form page where + * users can install and activate the plugin. + * + * Returns early if we're on the Install page. + * + * @since 1.0.0 + * + * @global object $current_screen + * + * @return null Returns early if we're on the Install page. + */ + public function notices() { + // Remove nag on the install page / Return early if the nag message has been dismissed. + if ( $this->is_tgmpa_page() || get_user_meta( get_current_user_id(), 'tgmpa_dismissed_notice_' . $this->id, true ) ) { + return; + } + + // Store for the plugin slugs by message type. + $message = array(); + + // Initialize counters used to determine plurality of action link texts. + $install_link_count = 0; + $update_link_count = 0; + $activate_link_count = 0; + + foreach ( $this->plugins as $slug => $plugin ) { + if ( $this->is_plugin_active( $slug ) && false === $this->does_plugin_have_update( $slug ) ) { + continue; + } + + if ( ! $this->is_plugin_installed( $slug ) ) { + if ( current_user_can( 'install_plugins' ) ) { + $install_link_count++; + + if ( true === $plugin['required'] ) { + $message['notice_can_install_required'][] = $slug; + } else { + $message['notice_can_install_recommended'][] = $slug; + } + } else { + // Need higher privileges to install the plugin. + $message['notice_cannot_install'][] = $slug; + } + } else { + if ( ! $this->is_plugin_active( $slug ) && $this->can_plugin_activate( $slug ) ) { + if ( current_user_can( 'activate_plugins' ) ) { + $activate_link_count++; + + if ( true === $plugin['required'] ) { + $message['notice_can_activate_required'][] = $slug; + } else { + $message['notice_can_activate_recommended'][] = $slug; + } + } else { + // Need higher privileges to activate the plugin. + $message['notice_cannot_activate'][] = $slug; + } + } + + if ( $this->does_plugin_require_update( $slug ) || false !== $this->does_plugin_have_update( $slug ) ) { + + if ( current_user_can( 'install_plugins' ) ) { + $update_link_count++; + + if ( $this->does_plugin_require_update( $slug ) ) { + $message['notice_ask_to_update'][] = $slug; + } elseif ( false !== $this->does_plugin_have_update( $slug ) ) { + $message['notice_ask_to_update_maybe'][] = $slug; + } + } else { + // Need higher privileges to update the plugin. + $message['notice_cannot_update'][] = $slug; + } + } + } + } + unset( $slug, $plugin ); + + // If we have notices to display, we move forward. + if ( ! empty( $message ) ) { + krsort( $message ); // Sort messages. + $rendered = ''; + + // As add_settings_error() wraps the final message in a

and as the final message can't be + // filtered, using

's in our html would render invalid html output. + $line_template = '%s' . "\n"; + + // If dismissable is false and a message is set, output it now. + if ( ! $this->dismissable && ! empty( $this->dismiss_msg ) ) { + $rendered .= sprintf( $line_template, wp_kses_post( $this->dismiss_msg ) ); + } + + // Render the individual message lines for the notice. + foreach ( $message as $type => $plugin_group ) { + $linked_plugins = array(); + + // Get the external info link for a plugin if one is available. + foreach ( $plugin_group as $plugin_slug ) { + $linked_plugins[] = $this->get_info_link( $plugin_slug ); + } + unset( $plugin_slug ); + + $count = count( $plugin_group ); + $linked_plugins = array_map( array( 'TGMPA_Utils', 'wrap_in_em' ), $linked_plugins ); + $last_plugin = array_pop( $linked_plugins ); // Pop off last name to prep for readability. + $imploded = empty( $linked_plugins ) ? $last_plugin : ( implode( ', ', $linked_plugins ) . ' ' . esc_html_x( 'and', 'plugin A *and* plugin B', 'cryout' ) . ' ' . $last_plugin ); + + $rendered .= sprintf( + $line_template, + sprintf( + translate_nooped_plural( $this->strings[ $type ], $count, 'cryout' ), + $imploded, + $count + ) + ); + + if ( 0 === strpos( $type, 'notice_cannot' ) ) { + $rendered .= $this->strings['contact_admin']; + } + } + unset( $type, $plugin_group, $linked_plugins, $count, $last_plugin, $imploded ); + + // Setup action links. + $action_links = array( + 'install' => '', + 'update' => '', + 'activate' => '', + 'dismiss' => $this->dismissable ? '' . esc_html( $this->strings['dismiss'] ) . '' : '', + ); + + $link_template = '%1$s'; + + if ( current_user_can( 'install_plugins' ) ) { + if ( $install_link_count > 0 ) { + $action_links['install'] = sprintf( + $link_template, + translate_nooped_plural( $this->strings['install_link'], $install_link_count, 'cryout' ), + esc_url( $this->get_tgmpa_status_url( 'install' ) ) + ); + } + if ( $update_link_count > 0 ) { + $action_links['update'] = sprintf( + $link_template, + translate_nooped_plural( $this->strings['update_link'], $update_link_count, 'cryout' ), + esc_url( $this->get_tgmpa_status_url( 'update' ) ) + ); + } + } + + if ( current_user_can( 'activate_plugins' ) && $activate_link_count > 0 ) { + $action_links['activate'] = sprintf( + $link_template, + translate_nooped_plural( $this->strings['activate_link'], $activate_link_count, 'cryout' ), + esc_url( $this->get_tgmpa_status_url( 'activate' ) ) + ); + } + + $action_links = apply_filters( 'tgmpa_notice_action_links', $action_links ); + + $action_links = array_filter( (array) $action_links ); // Remove any empty array items. + + if ( ! empty( $action_links ) && is_array( $action_links ) ) { + $action_links = sprintf( $line_template, implode( ' | ', $action_links ) ); + $rendered .= apply_filters( 'tgmpa_notice_rendered_action_links', $action_links ); + } + + // Register the nag messages and prepare them to be processed. + if ( ! empty( $this->strings['nag_type'] ) ) { + add_settings_error( 'tgmpa', 'tgmpa', $rendered, sanitize_html_class( strtolower( $this->strings['nag_type'] ) ) ); + } else { + $nag_class = version_compare( $this->wp_version, '3.8', '<' ) ? 'updated' : 'update-nag'; + add_settings_error( 'tgmpa', 'tgmpa', $rendered, $nag_class ); + } + } + + // Admin options pages already output settings_errors, so this is to avoid duplication. + if ( 'options-general' !== $GLOBALS['current_screen']->parent_base ) { + $this->display_settings_errors(); + } + } + + /** + * Display settings errors and remove those which have been displayed to avoid duplicate messages showing + * + * @since 2.5.0 + */ + protected function display_settings_errors() { + global $wp_settings_errors; + + settings_errors( 'tgmpa' ); + + foreach ( (array) $wp_settings_errors as $key => $details ) { + if ( 'tgmpa' === $details['setting'] ) { + unset( $wp_settings_errors[ $key ] ); + break; + } + } + } + + /** + * Add dismissable admin notices. + * + * Appends a link to the admin nag messages. If clicked, the admin notice disappears and no longer is visible to users. + * + * @since 2.1.0 + */ + public function dismiss() { + if ( isset( $_GET['tgmpa-dismiss'] ) ) { + update_user_meta( get_current_user_id(), 'tgmpa_dismissed_notice_' . $this->id, 1 ); + } + } + + /** + * Add individual plugin to our collection of plugins. + * + * If the required keys are not set or the plugin has already + * been registered, the plugin is not added. + * + * @since 2.0.0 + * + * @param array|null $plugin Array of plugin arguments or null if invalid argument. + * @return null Return early if incorrect argument. + */ + public function register( $plugin ) { + if ( empty( $plugin['slug'] ) || empty( $plugin['name'] ) ) { + return; + } + + if ( empty( $plugin['slug'] ) || ! is_string( $plugin['slug'] ) || isset( $this->plugins[ $plugin['slug'] ] ) ) { + return; + } + + $defaults = array( + 'name' => '', // String + 'slug' => '', // String + 'source' => 'repo', // String + 'required' => false, // Boolean + 'version' => '', // String + 'force_activation' => false, // Boolean + 'force_deactivation' => false, // Boolean + 'external_url' => '', // String + 'is_callable' => '', // String|Array. + ); + + // Prepare the received data. + $plugin = wp_parse_args( $plugin, $defaults ); + + // Standardize the received slug. + $plugin['slug'] = $this->sanitize_key( $plugin['slug'] ); + + // Forgive users for using string versions of booleans or floats for version number. + $plugin['version'] = (string) $plugin['version']; + $plugin['source'] = empty( $plugin['source'] ) ? 'repo' : $plugin['source']; + $plugin['required'] = TGMPA_Utils::validate_bool( $plugin['required'] ); + $plugin['force_activation'] = TGMPA_Utils::validate_bool( $plugin['force_activation'] ); + $plugin['force_deactivation'] = TGMPA_Utils::validate_bool( $plugin['force_deactivation'] ); + + // Enrich the received data. + $plugin['file_path'] = $this->_get_plugin_basename_from_slug( $plugin['slug'] ); + $plugin['source_type'] = $this->get_plugin_source_type( $plugin['source'] ); + + // Set the class properties. + $this->plugins[ $plugin['slug'] ] = $plugin; + $this->sort_order[ $plugin['slug'] ] = $plugin['name']; + + // Should we add the force activation hook ? + if ( true === $plugin['force_activation'] ) { + $this->has_forced_activation = true; + } + + // Should we add the force deactivation hook ? + if ( true === $plugin['force_deactivation'] ) { + $this->has_forced_deactivation = true; + } + } + + /** + * Determine what type of source the plugin comes from. + * + * @since 2.5.0 + * + * @param string $source The source of the plugin as provided, either empty (= WP repo), a file path + * (= bundled) or an external URL. + * @return string 'repo', 'external', or 'bundled' + */ + protected function get_plugin_source_type( $source ) { + if ( 'repo' === $source || preg_match( self::WP_REPO_REGEX, $source ) ) { + return 'repo'; + } elseif ( preg_match( self::IS_URL_REGEX, $source ) ) { + return 'external'; + } else { + return 'bundled'; + } + } + + /** + * Sanitizes a string key. + * + * Near duplicate of WP Core `sanitize_key()`. The difference is that uppercase characters *are* + * allowed, so as not to break upgrade paths from non-standard bundled plugins using uppercase + * characters in the plugin directory path/slug. Silly them. + * + * @see https://developer.wordpress.org/reference/hooks/sanitize_key/ + * + * @since 2.5.0 + * + * @param string $key String key. + * @return string Sanitized key + */ + public function sanitize_key( $key ) { + $raw_key = $key; + $key = preg_replace( '`[^A-Za-z0-9_-]`', '', $key ); + + /** + * Filter a sanitized key string. + * + * @since 3.0.0 + * + * @param string $key Sanitized key. + * @param string $raw_key The key prior to sanitization. + */ + return apply_filters( 'tgmpa_sanitize_key', $key, $raw_key ); + } + + /** + * Amend default configuration settings. + * + * @since 2.0.0 + * + * @param array $config Array of config options to pass as class properties. + */ + public function config( $config ) { + $keys = array( + 'id', + 'default_path', + 'has_notices', + 'dismissable', + 'dismiss_msg', + 'menu', + 'parent_slug', + 'capability', + 'is_automatic', + 'message', + 'strings', + ); + + foreach ( $keys as $key ) { + if ( isset( $config[ $key ] ) ) { + if ( is_array( $config[ $key ] ) ) { + $this->$key = array_merge( $this->$key, $config[ $key ] ); + } else { + $this->$key = $config[ $key ]; + } + } + } + } + + /** + * Amend action link after plugin installation. + * + * @since 2.0.0 + * + * @param array $install_actions Existing array of actions. + * @return array Amended array of actions. + */ + public function actions( $install_actions ) { + // Remove action links on the TGMPA install page. + if ( $this->is_tgmpa_page() ) { + return false; + } + + return $install_actions; + } + + /** + * Flushes the plugins cache on theme switch to prevent stale entries + * from remaining in the plugin table. + * + * @since 2.4.0 + * + * @param bool $clear_update_cache Optional. Whether to clear the Plugin updates cache. + * Parameter added in v2.5.0. + */ + public function flush_plugins_cache( $clear_update_cache = true ) { + wp_clean_plugins_cache( $clear_update_cache ); + } + + /** + * Set file_path key for each installed plugin. + * + * @since 2.1.0 + * + * @param string $plugin_slug Optional. If set, only (re-)populates the file path for that specific plugin. + * Parameter added in v2.5.0. + */ + public function populate_file_path( $plugin_slug = '' ) { + if ( ! empty( $plugin_slug ) && is_string( $plugin_slug ) && isset( $this->plugins[ $plugin_slug ] ) ) { + $this->plugins[ $plugin_slug ]['file_path'] = $this->_get_plugin_basename_from_slug( $plugin_slug ); + } else { + // Add file_path key for all plugins. + foreach ( $this->plugins as $slug => $values ) { + $this->plugins[ $slug ]['file_path'] = $this->_get_plugin_basename_from_slug( $slug ); + } + } + } + + /** + * Helper function to extract the file path of the plugin file from the + * plugin slug, if the plugin is installed. + * + * @since 2.0.0 + * + * @param string $slug Plugin slug (typically folder name) as provided by the developer. + * @return string Either file path for plugin if installed, or just the plugin slug. + */ + protected function _get_plugin_basename_from_slug( $slug ) { + $keys = array_keys( $this->get_plugins() ); + + foreach ( $keys as $key ) { + if ( preg_match( '|^' . $slug . '/|', $key ) ) { + return $key; + } + } + + return $slug; + } + + /** + * Retrieve plugin data, given the plugin name. + * + * Loops through the registered plugins looking for $name. If it finds it, + * it returns the $data from that plugin. Otherwise, returns false. + * + * @since 2.1.0 + * + * @param string $name Name of the plugin, as it was registered. + * @param string $data Optional. Array key of plugin data to return. Default is slug. + * @return string|boolean Plugin slug if found, false otherwise. + */ + public function _get_plugin_data_from_name( $name, $data = 'slug' ) { + foreach ( $this->plugins as $values ) { + if ( $name === $values['name'] && isset( $values[ $data ] ) ) { + return $values[ $data ]; + } + } + + return false; + } + + /** + * Retrieve the download URL for a package. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return string Plugin download URL or path to local file or empty string if undetermined. + */ + public function get_download_url( $slug ) { + $dl_source = ''; + + switch ( $this->plugins[ $slug ]['source_type'] ) { + case 'repo': + return $this->get_wp_repo_download_url( $slug ); + case 'external': + return $this->plugins[ $slug ]['source']; + case 'bundled': + return $this->default_path . $this->plugins[ $slug ]['source']; + } + + return $dl_source; // Should never happen. + } + + /** + * Retrieve the download URL for a WP repo package. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return string Plugin download URL. + */ + protected function get_wp_repo_download_url( $slug ) { + $source = ''; + $api = $this->get_plugins_api( $slug ); + + if ( false !== $api && isset( $api->download_link ) ) { + $source = $api->download_link; + } + + return $source; + } + + /** + * Try to grab information from WordPress API. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return object Plugins_api response object on success, WP_Error on failure. + */ + protected function get_plugins_api( $slug ) { + static $api = array(); // Cache received responses. + + if ( ! isset( $api[ $slug ] ) ) { + if ( ! function_exists( 'plugins_api' ) ) { + require_once ABSPATH . 'wp-admin/includes/plugin-install.php'; + } + + $response = plugins_api( 'plugin_information', array( 'slug' => $slug, 'fields' => array( 'sections' => false ) ) ); + + $api[ $slug ] = false; + + if ( is_wp_error( $response ) ) { + wp_die( esc_html( $this->strings['oops'] ) ); + } else { + $api[ $slug ] = $response; + } + } + + return $api[ $slug ]; + } + + /** + * Retrieve a link to a plugin information page. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return string Fully formed html link to a plugin information page if available + * or the plugin name if not. + */ + public function get_info_link( $slug ) { + if ( ! empty( $this->plugins[ $slug ]['external_url'] ) && preg_match( self::IS_URL_REGEX, $this->plugins[ $slug ]['external_url'] ) ) { + $link = sprintf( + '%2$s', + esc_url( $this->plugins[ $slug ]['external_url'] ), + esc_html( $this->plugins[ $slug ]['name'] ) + ); + } elseif ( 'repo' === $this->plugins[ $slug ]['source_type'] ) { + $url = add_query_arg( + array( + 'tab' => 'plugin-information', + 'plugin' => urlencode( $slug ), + 'TB_iframe' => 'true', + 'width' => '640', + 'height' => '500', + ), + self_admin_url( 'plugin-install.php' ) + ); + + $link = sprintf( + '%2$s', + esc_url( $url ), + esc_html( $this->plugins[ $slug ]['name'] ) + ); + } else { + $link = esc_html( $this->plugins[ $slug ]['name'] ); // No hyperlink. + } + + return $link; + } + + /** + * Determine if we're on the TGMPA Install page. + * + * @since 2.1.0 + * + * @return boolean True when on the TGMPA page, false otherwise. + */ + protected function is_tgmpa_page() { + return isset( $_GET['page'] ) && $this->menu === $_GET['page']; + } + + /** + * Retrieve the URL to the TGMPA Install page. + * + * I.e. depending on the config settings passed something along the lines of: + * http://example.com/wp-admin/themes.php?page=tgmpa-install-plugins + * + * @since 2.5.0 + * + * @return string Properly encoded URL (not escaped). + */ + public function get_tgmpa_url() { + static $url; + + if ( ! isset( $url ) ) { + $parent = $this->parent_slug; + if ( false === strpos( $parent, '.php' ) ) { + $parent = 'admin.php'; + } + $url = add_query_arg( + array( + 'page' => urlencode( $this->menu ), + ), + self_admin_url( $parent ) + ); + } + + return $url; + } + + /** + * Retrieve the URL to the TGMPA Install page for a specific plugin status (view). + * + * I.e. depending on the config settings passed something along the lines of: + * http://example.com/wp-admin/themes.php?page=tgmpa-install-plugins&plugin_status=install + * + * @since 2.5.0 + * + * @param string $status Plugin status - either 'install', 'update' or 'activate'. + * @return string Properly encoded URL (not escaped). + */ + public function get_tgmpa_status_url( $status ) { + return add_query_arg( + array( + 'plugin_status' => urlencode( $status ), + ), + $this->get_tgmpa_url() + ); + } + + /** + * Determine whether there are open actions for plugins registered with TGMPA. + * + * @since 2.5.0 + * + * @return bool True if complete, i.e. no outstanding actions. False otherwise. + */ + public function is_tgmpa_complete() { + $complete = true; + foreach ( $this->plugins as $slug => $plugin ) { + if ( ! $this->is_plugin_active( $slug ) || false !== $this->does_plugin_have_update( $slug ) ) { + $complete = false; + break; + } + } + + return $complete; + } + + /** + * Check if a plugin is installed. Does not take must-use plugins into account. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return bool True if installed, false otherwise. + */ + public function is_plugin_installed( $slug ) { + $installed_plugins = $this->get_plugins(); // Retrieve a list of all installed plugins (WP cached). + + return ( ! empty( $installed_plugins[ $this->plugins[ $slug ]['file_path'] ] ) ); + } + + /** + * Check if a plugin is active. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return bool True if active, false otherwise. + */ + public function is_plugin_active( $slug ) { + return ( ( ! empty( $this->plugins[ $slug ]['is_callable'] ) && is_callable( $this->plugins[ $slug ]['is_callable'] ) ) || is_plugin_active( $this->plugins[ $slug ]['file_path'] ) ); + } + + /** + * Check if a plugin can be updated, i.e. if we have information on the minimum WP version required + * available, check whether the current install meets them. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return bool True if OK to update, false otherwise. + */ + public function can_plugin_update( $slug ) { + // We currently can't get reliable info on non-WP-repo plugins - issue #380. + if ( 'repo' !== $this->plugins[ $slug ]['source_type'] ) { + return true; + } + + $api = $this->get_plugins_api( $slug ); + + if ( false !== $api && isset( $api->requires ) ) { + return version_compare( $GLOBALS['wp_version'], $api->requires, '>=' ); + } + + // No usable info received from the plugins API, presume we can update. + return true; + } + + /** + * Check if a plugin can be activated, i.e. is not currently active and meets the minimum + * plugin version requirements set in TGMPA (if any). + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return bool True if OK to activate, false otherwise. + */ + public function can_plugin_activate( $slug ) { + return ( ! $this->is_plugin_active( $slug ) && ! $this->does_plugin_require_update( $slug ) ); + } + + /** + * Retrieve the version number of an installed plugin. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return string Version number as string or an empty string if the plugin is not installed + * or version unknown (plugins which don't comply with the plugin header standard). + */ + public function get_installed_version( $slug ) { + $installed_plugins = $this->get_plugins(); // Retrieve a list of all installed plugins (WP cached). + + if ( ! empty( $installed_plugins[ $this->plugins[ $slug ]['file_path'] ]['Version'] ) ) { + return $installed_plugins[ $this->plugins[ $slug ]['file_path'] ]['Version']; + } + + return ''; + } + + /** + * Check whether a plugin complies with the minimum version requirements. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return bool True when a plugin needs to be updated, otherwise false. + */ + public function does_plugin_require_update( $slug ) { + $installed_version = $this->get_installed_version( $slug ); + $minimum_version = $this->plugins[ $slug ]['version']; + + return version_compare( $minimum_version, $installed_version, '>' ); + } + + /** + * Check whether there is an update available for a plugin. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return false|string Version number string of the available update or false if no update available. + */ + public function does_plugin_have_update( $slug ) { + // Presume bundled and external plugins will point to a package which meets the minimum required version. + if ( 'repo' !== $this->plugins[ $slug ]['source_type'] ) { + if ( $this->does_plugin_require_update( $slug ) ) { + return $this->plugins[ $slug ]['version']; + } + + return false; + } + + $repo_updates = get_site_transient( 'update_plugins' ); + + if ( isset( $repo_updates->response[ $this->plugins[ $slug ]['file_path'] ]->new_version ) ) { + return $repo_updates->response[ $this->plugins[ $slug ]['file_path'] ]->new_version; + } + + return false; + } + + /** + * Retrieve potential upgrade notice for a plugin. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return string The upgrade notice or an empty string if no message was available or provided. + */ + public function get_upgrade_notice( $slug ) { + // We currently can't get reliable info on non-WP-repo plugins - issue #380. + if ( 'repo' !== $this->plugins[ $slug ]['source_type'] ) { + return ''; + } + + $repo_updates = get_site_transient( 'update_plugins' ); + + if ( ! empty( $repo_updates->response[ $this->plugins[ $slug ]['file_path'] ]->upgrade_notice ) ) { + return $repo_updates->response[ $this->plugins[ $slug ]['file_path'] ]->upgrade_notice; + } + + return ''; + } + + /** + * Wrapper around the core WP get_plugins function, making sure it's actually available. + * + * @since 2.5.0 + * + * @param string $plugin_folder Optional. Relative path to single plugin folder. + * @return array Array of installed plugins with plugin information. + */ + public function get_plugins( $plugin_folder = '' ) { + if ( ! function_exists( 'get_plugins' ) ) { + require_once ABSPATH . 'wp-admin/includes/plugin.php'; + } + + return get_plugins( $plugin_folder ); + } + + /** + * Delete dismissable nag option when theme is switched. + * + * This ensures that the user(s) is/are again reminded via nag of required + * and/or recommended plugins if they re-activate the theme. + * + * @since 2.1.1 + */ + public function update_dismiss() { + delete_metadata( 'user', null, 'tgmpa_dismissed_notice_' . $this->id, null, true ); + } + + /** + * Forces plugin activation if the parameter 'force_activation' is + * set to true. + * + * This allows theme authors to specify certain plugins that must be + * active at all times while using the current theme. + * + * Please take special care when using this parameter as it has the + * potential to be harmful if not used correctly. Setting this parameter + * to true will not allow the specified plugin to be deactivated unless + * the user switches themes. + * + * @since 2.2.0 + */ + public function force_activation() { + foreach ( $this->plugins as $slug => $plugin ) { + if ( true === $plugin['force_activation'] ) { + if ( ! $this->is_plugin_installed( $slug ) ) { + // Oops, plugin isn't there so iterate to next condition. + continue; + } elseif ( $this->can_plugin_activate( $slug ) ) { + // There we go, activate the plugin. + activate_plugin( $plugin['file_path'] ); + } + } + } + } + + /** + * Forces plugin deactivation if the parameter 'force_deactivation' + * is set to true. + * + * This allows theme authors to specify certain plugins that must be + * deactivated upon switching from the current theme to another. + * + * Please take special care when using this parameter as it has the + * potential to be harmful if not used correctly. + * + * @since 2.2.0 + */ + public function force_deactivation() { + foreach ( $this->plugins as $slug => $plugin ) { + // Only proceed forward if the parameter is set to true and plugin is active. + if ( true === $plugin['force_deactivation'] && $this->is_plugin_active( $slug ) ) { + deactivate_plugins( $plugin['file_path'] ); + } + } + } + + /** + * Echo the current TGMPA version number to the page. + */ + public function show_tgmpa_version() { + echo '

', + esc_html( sprintf( _x( 'TGMPA v%s', '%s = version number', 'cryout' ), self::TGMPA_VERSION ) ), + '

'; + } + + /** + * Returns the singleton instance of the class. + * + * @since 2.4.0 + * + * @return object The TGM_Plugin_Activation object. + */ + public static function get_instance() { + if ( ! isset( self::$instance ) && ! ( self::$instance instanceof self ) ) { + self::$instance = new self(); + } + + return self::$instance; + } + } + + if ( ! function_exists( 'load_tgm_plugin_activation' ) ) { + /** + * Ensure only one instance of the class is ever invoked. + */ + function load_tgm_plugin_activation() { + $GLOBALS['tgmpa'] = TGM_Plugin_Activation::get_instance(); + } + } + + if ( did_action( 'plugins_loaded' ) ) { + load_tgm_plugin_activation(); + } else { + add_action( 'plugins_loaded', 'load_tgm_plugin_activation' ); + } +} + +if ( ! function_exists( 'tgmpa' ) ) { + /** + * Helper function to register a collection of required plugins. + * + * @since 2.0.0 + * @api + * + * @param array $plugins An array of plugin arrays. + * @param array $config Optional. An array of configuration values. + */ + function tgmpa( $plugins, $config = array() ) { + $instance = call_user_func( array( get_class( $GLOBALS['tgmpa'] ), 'get_instance' ) ); + + foreach ( $plugins as $plugin ) { + call_user_func( array( $instance, 'register' ), $plugin ); + } + + if ( ! empty( $config ) && is_array( $config ) ) { + // Send out notices for deprecated arguments passed. + if ( isset( $config['notices'] ) ) { + _deprecated_argument( __FUNCTION__, '2.2.0', 'The `notices` config parameter was renamed to `has_notices` in TGMPA 2.2.0. Please adjust your configuration.' ); + if ( ! isset( $config['has_notices'] ) ) { + $config['has_notices'] = $config['notices']; + } + } + + if ( isset( $config['parent_menu_slug'] ) ) { + _deprecated_argument( __FUNCTION__, '2.4.0', 'The `parent_menu_slug` config parameter was removed in TGMPA 2.4.0. In TGMPA 2.5.0 an alternative was (re-)introduced. Please adjust your configuration. For more information visit the website: http://tgmpluginactivation.com/configuration/#h-configuration-options.' ); + } + if ( isset( $config['parent_url_slug'] ) ) { + _deprecated_argument( __FUNCTION__, '2.4.0', 'The `parent_url_slug` config parameter was removed in TGMPA 2.4.0. In TGMPA 2.5.0 an alternative was (re-)introduced. Please adjust your configuration. For more information visit the website: http://tgmpluginactivation.com/configuration/#h-configuration-options.' ); + } + + call_user_func( array( $instance, 'config' ), $config ); + } + } +} + +/** + * WP_List_Table isn't always available. If it isn't available, + * we load it here. + * + * @since 2.2.0 + */ +if ( ! class_exists( 'WP_List_Table' ) ) { + require_once ABSPATH . 'wp-admin/includes/class-wp-list-table.php'; +} + +if ( ! class_exists( 'TGMPA_List_Table' ) ) { + + /** + * List table class for handling plugins. + * + * Extends the WP_List_Table class to provide a future-compatible + * way of listing out all required/recommended plugins. + * + * Gives users an interface similar to the Plugin Administration + * area with similar (albeit stripped down) capabilities. + * + * This class also allows for the bulk install of plugins. + * + * @since 2.2.0 + * + * @package TGM-Plugin-Activation + * @author Thomas Griffin + * @author Gary Jones + */ + class TGMPA_List_Table extends WP_List_Table { + /** + * TGMPA instance. + * + * @since 2.5.0 + * + * @var object + */ + protected $tgmpa; + + /** + * The currently chosen view. + * + * @since 2.5.0 + * + * @var string One of: 'all', 'install', 'update', 'activate' + */ + public $view_context = 'all'; + + /** + * The plugin counts for the various views. + * + * @since 2.5.0 + * + * @var array + */ + protected $view_totals = array( + 'all' => 0, + 'install' => 0, + 'update' => 0, + 'activate' => 0, + ); + + /** + * References parent constructor and sets defaults for class. + * + * @since 2.2.0 + */ + public function __construct() { + $this->tgmpa = call_user_func( array( get_class( $GLOBALS['tgmpa'] ), 'get_instance' ) ); + + parent::__construct( + array( + 'singular' => 'plugin', + 'plural' => 'plugins', + 'ajax' => false, + ) + ); + + if ( isset( $_REQUEST['plugin_status'] ) && in_array( $_REQUEST['plugin_status'], array( 'install', 'update', 'activate' ), true ) ) { + $this->view_context = sanitize_key( $_REQUEST['plugin_status'] ); + } + + add_filter( 'tgmpa_table_data_items', array( $this, 'sort_table_items' ) ); + } + + /** + * Get a list of CSS classes for the tag. + * + * Overruled to prevent the 'plural' argument from being added. + * + * @since 2.5.0 + * + * @return array CSS classnames. + */ + public function get_table_classes() { + return array( 'widefat', 'fixed' ); + } + + /** + * Gathers and renames all of our plugin information to be used by WP_List_Table to create our table. + * + * @since 2.2.0 + * + * @return array $table_data Information for use in table. + */ + protected function _gather_plugin_data() { + // Load thickbox for plugin links. + $this->tgmpa->admin_init(); + $this->tgmpa->thickbox(); + + // Categorize the plugins which have open actions. + $plugins = $this->categorize_plugins_to_views(); + + // Set the counts for the view links. + $this->set_view_totals( $plugins ); + + // Prep variables for use and grab list of all installed plugins. + $table_data = array(); + $i = 0; + + // Redirect to the 'all' view if no plugins were found for the selected view context. + if ( empty( $plugins[ $this->view_context ] ) ) { + $this->view_context = 'all'; + } + + foreach ( $plugins[ $this->view_context ] as $slug => $plugin ) { + $table_data[ $i ]['sanitized_plugin'] = $plugin['name']; + $table_data[ $i ]['slug'] = $slug; + $table_data[ $i ]['plugin'] = '' . $this->tgmpa->get_info_link( $slug ) . ''; + $table_data[ $i ]['source'] = $this->get_plugin_source_type_text( $plugin['source_type'] ); + $table_data[ $i ]['type'] = $this->get_plugin_advise_type_text( $plugin['required'] ); + $table_data[ $i ]['status'] = $this->get_plugin_status_text( $slug ); + $table_data[ $i ]['installed_version'] = $this->tgmpa->get_installed_version( $slug ); + $table_data[ $i ]['minimum_version'] = $plugin['version']; + $table_data[ $i ]['available_version'] = $this->tgmpa->does_plugin_have_update( $slug ); + + // Prep the upgrade notice info. + $upgrade_notice = $this->tgmpa->get_upgrade_notice( $slug ); + if ( ! empty( $upgrade_notice ) ) { + $table_data[ $i ]['upgrade_notice'] = $upgrade_notice; + + add_action( "tgmpa_after_plugin_row_$slug", array( $this, 'wp_plugin_update_row' ), 10, 2 ); + } + + $table_data[ $i ] = apply_filters( 'tgmpa_table_data_item', $table_data[ $i ], $plugin ); + + $i++; + } + + return $table_data; + } + + /** + * Categorize the plugins which have open actions into views for the TGMPA page. + * + * @since 2.5.0 + */ + protected function categorize_plugins_to_views() { + $plugins = array( + 'all' => array(), // Meaning: all plugins which still have open actions. + 'install' => array(), + 'update' => array(), + 'activate' => array(), + ); + + foreach ( $this->tgmpa->plugins as $slug => $plugin ) { + if ( $this->tgmpa->is_plugin_active( $slug ) && false === $this->tgmpa->does_plugin_have_update( $slug ) ) { + // No need to display plugins if they are installed, up-to-date and active. + continue; + } else { + $plugins['all'][ $slug ] = $plugin; + + if ( ! $this->tgmpa->is_plugin_installed( $slug ) ) { + $plugins['install'][ $slug ] = $plugin; + } else { + if ( false !== $this->tgmpa->does_plugin_have_update( $slug ) ) { + $plugins['update'][ $slug ] = $plugin; + } + + if ( $this->tgmpa->can_plugin_activate( $slug ) ) { + $plugins['activate'][ $slug ] = $plugin; + } + } + } + } + + return $plugins; + } + + /** + * Set the counts for the view links. + * + * @since 2.5.0 + * + * @param array $plugins Plugins order by view. + */ + protected function set_view_totals( $plugins ) { + foreach ( $plugins as $type => $list ) { + $this->view_totals[ $type ] = count( $list ); + } + } + + /** + * Get the plugin required/recommended text string. + * + * @since 2.5.0 + * + * @param string $required Plugin required setting. + * @return string + */ + protected function get_plugin_advise_type_text( $required ) { + if ( true === $required ) { + return __( 'Required', 'cryout' ); + } + + return __( 'Recommended', 'cryout' ); + } + + /** + * Get the plugin source type text string. + * + * @since 2.5.0 + * + * @param string $type Plugin type. + * @return string + */ + protected function get_plugin_source_type_text( $type ) { + $string = ''; + + switch ( $type ) { + case 'repo': + $string = __( 'WordPress Repository', 'cryout' ); + break; + case 'external': + $string = __( 'External Source', 'cryout' ); + break; + case 'bundled': + $string = __( 'Pre-Packaged', 'cryout' ); + break; + } + + return $string; + } + + /** + * Determine the plugin status message. + * + * @since 2.5.0 + * + * @param string $slug Plugin slug. + * @return string + */ + protected function get_plugin_status_text( $slug ) { + if ( ! $this->tgmpa->is_plugin_installed( $slug ) ) { + return __( 'Not Installed', 'cryout' ); + } + + if ( ! $this->tgmpa->is_plugin_active( $slug ) ) { + $install_status = __( 'Installed But Not Activated', 'cryout' ); + } else { + $install_status = __( 'Active', 'cryout' ); + } + + $update_status = ''; + + if ( $this->tgmpa->does_plugin_require_update( $slug ) && false === $this->tgmpa->does_plugin_have_update( $slug ) ) { + $update_status = __( 'Required Update not Available', 'cryout' ); + + } elseif ( $this->tgmpa->does_plugin_require_update( $slug ) ) { + $update_status = __( 'Requires Update', 'cryout' ); + + } elseif ( false !== $this->tgmpa->does_plugin_have_update( $slug ) ) { + $update_status = __( 'Update recommended', 'cryout' ); + } + + if ( '' === $update_status ) { + return $install_status; + } + + return sprintf( + _x( '%1$s, %2$s', '%1$s = install status, %2$s = update status', 'cryout' ), + $install_status, + $update_status + ); + } + + /** + * Sort plugins by Required/Recommended type and by alphabetical plugin name within each type. + * + * @since 2.5.0 + * + * @param array $items Prepared table items. + * @return array Sorted table items. + */ + public function sort_table_items( $items ) { + $type = array(); + $name = array(); + + foreach ( $items as $i => $plugin ) { + $type[ $i ] = $plugin['type']; // Required / recommended. + $name[ $i ] = $plugin['sanitized_plugin']; + } + + array_multisort( $type, SORT_DESC, $name, SORT_ASC, $items ); + + return $items; + } + + /** + * Get an associative array ( id => link ) of the views available on this table. + * + * @since 2.5.0 + * + * @return array + */ + public function get_views() { + $status_links = array(); + + foreach ( $this->view_totals as $type => $count ) { + if ( $count < 1 ) { + continue; + } + + switch ( $type ) { + case 'all': + $text = _nx( 'All (%s)', 'All (%s)', $count, 'plugins', 'cryout' ); + break; + case 'install': + $text = _n( 'To Install (%s)', 'To Install (%s)', $count, 'cryout' ); + break; + case 'update': + $text = _n( 'Update Available (%s)', 'Update Available (%s)', $count, 'cryout' ); + break; + case 'activate': + $text = _n( 'To Activate (%s)', 'To Activate (%s)', $count, 'cryout' ); + break; + default: + $text = ''; + break; + } + + if ( ! empty( $text ) ) { + + $status_links[ $type ] = sprintf( + '%s', + esc_url( $this->tgmpa->get_tgmpa_status_url( $type ) ), + ( $type === $this->view_context ) ? ' class="current"' : '', + sprintf( $text, number_format_i18n( $count ) ) + ); + } + } + + return $status_links; + } + + /** + * Create default columns to display important plugin information + * like type, action and status. + * + * @since 2.2.0 + * + * @param array $item Array of item data. + * @param string $column_name The name of the column. + * @return string + */ + public function column_default( $item, $column_name ) { + return $item[ $column_name ]; + } + + /** + * Required for bulk installing. + * + * Adds a checkbox for each plugin. + * + * @since 2.2.0 + * + * @param array $item Array of item data. + * @return string The input checkbox with all necessary info. + */ + public function column_cb( $item ) { + return sprintf( + '', + esc_attr( $this->_args['singular'] ), + esc_attr( $item['slug'] ), + esc_attr( $item['sanitized_plugin'] ) + ); + } + + /** + * Create default title column along with the action links. + * + * @since 2.2.0 + * + * @param array $item Array of item data. + * @return string The plugin name and action links. + */ + public function column_plugin( $item ) { + return sprintf( + '%1$s %2$s', + $item['plugin'], + $this->row_actions( $this->get_row_actions( $item ), true ) + ); + } + + /** + * Create version information column. + * + * @since 2.5.0 + * + * @param array $item Array of item data. + * @return string HTML-formatted version information. + */ + public function column_version( $item ) { + $output = array(); + + if ( $this->tgmpa->is_plugin_installed( $item['slug'] ) ) { + $installed = ! empty( $item['installed_version'] ) ? $item['installed_version'] : _x( 'unknown', 'as in: "version nr unknown"', 'cryout' ); + + $color = ''; + if ( ! empty( $item['minimum_version'] ) && $this->tgmpa->does_plugin_require_update( $item['slug'] ) ) { + $color = ' color: #ff0000; font-weight: bold;'; + } + + $output[] = sprintf( + '

%2$s' . __( 'Installed version:', 'cryout' ) . '

', + $color, + $installed + ); + } + + if ( ! empty( $item['minimum_version'] ) ) { + $output[] = sprintf( + '

%1$s' . __( 'Minimum required version:', 'cryout' ) . '

', + $item['minimum_version'] + ); + } + + if ( ! empty( $item['available_version'] ) ) { + $color = ''; + if ( ! empty( $item['minimum_version'] ) && version_compare( $item['available_version'], $item['minimum_version'], '>=' ) ) { + $color = ' color: #71C671; font-weight: bold;'; + } + + $output[] = sprintf( + '

%2$s' . __( 'Available version:', 'cryout' ) . '

', + $color, + $item['available_version'] + ); + } + + if ( empty( $output ) ) { + return ' '; // Let's not break the table layout. + } else { + return implode( "\n", $output ); + } + } + + /** + * Sets default message within the plugins table if no plugins + * are left for interaction. + * + * Hides the menu item to prevent the user from clicking and + * getting a permissions error. + * + * @since 2.2.0 + */ + public function no_items() { + printf( wp_kses_post( __( 'No plugins to install, update or activate. Return to the Dashboard', 'cryout' ) ), esc_url( self_admin_url() ) ); + echo ''; + } + + /** + * Output all the column information within the table. + * + * @since 2.2.0 + * + * @return array $columns The column names. + */ + public function get_columns() { + $columns = array( + 'cb' => '', + 'plugin' => __( 'Plugin', 'cryout' ), + 'source' => __( 'Source', 'cryout' ), + 'type' => __( 'Type', 'cryout' ), + ); + + if ( 'all' === $this->view_context || 'update' === $this->view_context ) { + $columns['version'] = __( 'Version', 'cryout' ); + $columns['status'] = __( 'Status', 'cryout' ); + } + + return apply_filters( 'tgmpa_table_columns', $columns ); + } + + /** + * Get name of default primary column + * + * @since 2.5.0 / WP 4.3+ compatibility + * @access protected + * + * @return string + */ + protected function get_default_primary_column_name() { + return 'plugin'; + } + + /** + * Get the name of the primary column. + * + * @since 2.5.0 / WP 4.3+ compatibility + * @access protected + * + * @return string The name of the primary column. + */ + protected function get_primary_column_name() { + if ( method_exists( 'WP_List_Table', 'get_primary_column_name' ) ) { + return parent::get_primary_column_name(); + } else { + return $this->get_default_primary_column_name(); + } + } + + /** + * Get the actions which are relevant for a specific plugin row. + * + * @since 2.5.0 + * + * @param array $item Array of item data. + * @return array Array with relevant action links. + */ + protected function get_row_actions( $item ) { + $actions = array(); + $action_links = array(); + + // Display the 'Install' action link if the plugin is not yet available. + if ( ! $this->tgmpa->is_plugin_installed( $item['slug'] ) ) { + $actions['install'] = _x( 'Install %2$s', '%2$s = plugin name in screen reader markup', 'cryout' ); + } else { + // Display the 'Update' action link if an update is available and WP complies with plugin minimum. + if ( false !== $this->tgmpa->does_plugin_have_update( $item['slug'] ) && $this->tgmpa->can_plugin_update( $item['slug'] ) ) { + $actions['update'] = _x( 'Update %2$s', '%2$s = plugin name in screen reader markup', 'cryout' ); + } + + // Display the 'Activate' action link, but only if the plugin meets the minimum version. + if ( $this->tgmpa->can_plugin_activate( $item['slug'] ) ) { + $actions['activate'] = _x( 'Activate %2$s', '%2$s = plugin name in screen reader markup', 'cryout' ); + } + } + + // Create the actual links. + foreach ( $actions as $action => $text ) { + $nonce_url = wp_nonce_url( + add_query_arg( + array( + 'plugin' => urlencode( $item['slug'] ), + 'tgmpa-' . $action => $action . '-plugin', + ), + $this->tgmpa->get_tgmpa_url() + ), + 'tgmpa-' . $action, + 'tgmpa-nonce' + ); + + $action_links[ $action ] = sprintf( + '' . esc_html( $text ) . '', + esc_url( $nonce_url ), + '' . esc_html( $item['sanitized_plugin'] ) . '' + ); + } + + $prefix = ( defined( 'WP_NETWORK_ADMIN' ) && WP_NETWORK_ADMIN ) ? 'network_admin_' : ''; + return apply_filters( "tgmpa_{$prefix}plugin_action_links", array_filter( $action_links ), $item['slug'], $item, $this->view_context ); + } + + /** + * Generates content for a single row of the table. + * + * @since 2.5.0 + * + * @param object $item The current item. + */ + public function single_row( $item ) { + parent::single_row( $item ); + + /** + * Fires after each specific row in the TGMPA Plugins list table. + * + * The dynamic portion of the hook name, `$item['slug']`, refers to the slug + * for the plugin. + * + * @since 2.5.0 + */ + do_action( "tgmpa_after_plugin_row_{$item['slug']}", $item['slug'], $item, $this->view_context ); + } + + /** + * Show the upgrade notice below a plugin row if there is one. + * + * @since 2.5.0 + * + * @see /wp-admin/includes/update.php + * + * @param string $slug Plugin slug. + * @param array $item The information available in this table row. + * @return null Return early if upgrade notice is empty. + */ + public function wp_plugin_update_row( $slug, $item ) { + if ( empty( $item['upgrade_notice'] ) ) { + return; + } + + echo ' + + + '; + } + + /** + * Extra controls to be displayed between bulk actions and pagination. + * + * @since 2.5.0 + * + * @param string $which 'top' or 'bottom' table navigation. + */ + public function extra_tablenav( $which ) { + if ( 'bottom' === $which ) { + $this->tgmpa->show_tgmpa_version(); + } + } + + /** + * Defines the bulk actions for handling registered plugins. + * + * @since 2.2.0 + * + * @return array $actions The bulk actions for the plugin install table. + */ + public function get_bulk_actions() { + + $actions = array(); + + if ( 'update' !== $this->view_context && 'activate' !== $this->view_context ) { + if ( current_user_can( 'install_plugins' ) ) { + $actions['tgmpa-bulk-install'] = __( 'Install', 'cryout' ); + } + } + + if ( 'install' !== $this->view_context ) { + if ( current_user_can( 'update_plugins' ) ) { + $actions['tgmpa-bulk-update'] = __( 'Update', 'cryout' ); + } + if ( current_user_can( 'activate_plugins' ) ) { + $actions['tgmpa-bulk-activate'] = __( 'Activate', 'cryout' ); + } + } + + return $actions; + } + + /** + * Processes bulk installation and activation actions. + * + * The bulk installation process looks for the $_POST information and passes that + * through if a user has to use WP_Filesystem to enter their credentials. + * + * @since 2.2.0 + */ + public function process_bulk_actions() { + // Bulk installation process. + if ( 'tgmpa-bulk-install' === $this->current_action() || 'tgmpa-bulk-update' === $this->current_action() ) { + + check_admin_referer( 'bulk-' . $this->_args['plural'] ); + + $install_type = 'install'; + if ( 'tgmpa-bulk-update' === $this->current_action() ) { + $install_type = 'update'; + } + + $plugins_to_install = array(); + + // Did user actually select any plugins to install/update ? + if ( empty( $_POST['plugin'] ) ) { + if ( 'install' === $install_type ) { + $message = __( 'No plugins were selected to be installed. No action taken.', 'cryout' ); + } else { + $message = __( 'No plugins were selected to be updated. No action taken.', 'cryout' ); + } + + echo '

', esc_html( $message ), '

'; + + return false; + } + + if ( is_array( $_POST['plugin'] ) ) { + $plugins_to_install = (array) $_POST['plugin']; + } elseif ( is_string( $_POST['plugin'] ) ) { + // Received via Filesystem page - un-flatten array (WP bug #19643). + $plugins_to_install = explode( ',', $_POST['plugin'] ); + } + + // Sanitize the received input. + $plugins_to_install = array_map( 'urldecode', $plugins_to_install ); + $plugins_to_install = array_map( array( $this->tgmpa, 'sanitize_key' ), $plugins_to_install ); + + // Validate the received input. + foreach ( $plugins_to_install as $key => $slug ) { + // Check if the plugin was registered with TGMPA and remove if not. + if ( ! isset( $this->tgmpa->plugins[ $slug ] ) ) { + unset( $plugins_to_install[ $key ] ); + continue; + } + + // For updates: make sure this is a plugin we *can* update (update available and WP version ok). + if ( 'update' === $install_type && ( $this->tgmpa->is_plugin_installed( $slug ) && ( false === $this->tgmpa->does_plugin_have_update( $slug ) || ! $this->tgmpa->can_plugin_update( $slug ) ) ) ) { + unset( $plugins_to_install[ $key ] ); + } + } + + // No need to proceed further if we have no plugins to handle. + if ( empty( $plugins_to_install ) ) { + if ( 'install' === $install_type ) { + $message = __( 'No plugins are available to be installed at this time.', 'cryout' ); + } else { + $message = __( 'No plugins are available to be updated at this time.', 'cryout' ); + } + + echo '

', esc_html( $message ), '

'; + + return false; + } + + // Pass all necessary information if WP_Filesystem is needed. + $url = wp_nonce_url( + $this->tgmpa->get_tgmpa_url(), + 'bulk-' . $this->_args['plural'] + ); + + // Give validated data back to $_POST which is the only place the filesystem looks for extra fields. + $_POST['plugin'] = implode( ',', $plugins_to_install ); // Work around for WP bug #19643. + + $method = ''; // Leave blank so WP_Filesystem can populate it as necessary. + $fields = array_keys( $_POST ); // Extra fields to pass to WP_Filesystem. + + if ( false === ( $creds = request_filesystem_credentials( esc_url_raw( $url ), $method, false, false, $fields ) ) ) { + return true; // Stop the normal page form from displaying, credential request form will be shown. + } + + // Now we have some credentials, setup WP_Filesystem. + if ( ! WP_Filesystem( $creds ) ) { + // Our credentials were no good, ask the user for them again. + request_filesystem_credentials( esc_url_raw( $url ), $method, true, false, $fields ); + + return true; + } + + /* If we arrive here, we have the filesystem */ + + // Store all information in arrays since we are processing a bulk installation. + $names = array(); + $sources = array(); // Needed for installs. + $file_paths = array(); // Needed for upgrades. + $to_inject = array(); // Information to inject into the update_plugins transient. + + // Prepare the data for validated plugins for the install/upgrade. + foreach ( $plugins_to_install as $slug ) { + $name = $this->tgmpa->plugins[ $slug ]['name']; + $source = $this->tgmpa->get_download_url( $slug ); + + if ( ! empty( $name ) && ! empty( $source ) ) { + $names[] = $name; + + switch ( $install_type ) { + + case 'install': + $sources[] = $source; + break; + + case 'update': + $file_paths[] = $this->tgmpa->plugins[ $slug ]['file_path']; + $to_inject[ $slug ] = $this->tgmpa->plugins[ $slug ]; + $to_inject[ $slug ]['source'] = $source; + break; + } + } + } + unset( $slug, $name, $source ); + + // Create a new instance of TGMPA_Bulk_Installer. + $installer = new TGMPA_Bulk_Installer( + new TGMPA_Bulk_Installer_Skin( + array( + 'url' => esc_url_raw( $this->tgmpa->get_tgmpa_url() ), + 'nonce' => 'bulk-' . $this->_args['plural'], + 'names' => $names, + 'install_type' => $install_type, + ) + ) + ); + + // Wrap the install process with the appropriate HTML. + echo '
', + '

', esc_html( get_admin_page_title() ), '

'; + + // Process the bulk installation submissions. + add_filter( 'upgrader_source_selection', array( $this->tgmpa, 'maybe_adjust_source_dir' ), 1, 3 ); + + if ( 'tgmpa-bulk-update' === $this->current_action() ) { + // Inject our info into the update transient. + $this->tgmpa->inject_update_info( $to_inject ); + + $installer->bulk_upgrade( $file_paths ); + } else { + $installer->bulk_install( $sources ); + } + + remove_filter( 'upgrader_source_selection', array( $this->tgmpa, 'maybe_adjust_source_dir' ), 1, 3 ); + + echo '
'; + + return true; + } + + // Bulk activation process. + if ( 'tgmpa-bulk-activate' === $this->current_action() ) { + check_admin_referer( 'bulk-' . $this->_args['plural'] ); + + // Did user actually select any plugins to activate ? + if ( empty( $_POST['plugin'] ) ) { + echo '

', esc_html__( 'No plugins were selected to be activated. No action taken.', 'cryout' ), '

'; + + return false; + } + + // Grab plugin data from $_POST. + $plugins = array(); + if ( isset( $_POST['plugin'] ) ) { + $plugins = array_map( 'urldecode', (array) $_POST['plugin'] ); + $plugins = array_map( array( $this->tgmpa, 'sanitize_key' ), $plugins ); + } + + $plugins_to_activate = array(); + $plugin_names = array(); + + // Grab the file paths for the selected & inactive plugins from the registration array. + foreach ( $plugins as $slug ) { + if ( $this->tgmpa->can_plugin_activate( $slug ) ) { + $plugins_to_activate[] = $this->tgmpa->plugins[ $slug ]['file_path']; + $plugin_names[] = $this->tgmpa->plugins[ $slug ]['name']; + } + } + unset( $slug ); + + // Return early if there are no plugins to activate. + if ( empty( $plugins_to_activate ) ) { + echo '

', esc_html__( 'No plugins are available to be activated at this time.', 'cryout' ), '

'; + + return false; + } + + // Now we are good to go - let's start activating plugins. + $activate = activate_plugins( $plugins_to_activate ); + + if ( is_wp_error( $activate ) ) { + echo '

', wp_kses_post( $activate->get_error_message() ), '

'; + } else { + $count = count( $plugin_names ); // Count so we can use _n function. + $plugin_names = array_map( array( 'TGMPA_Utils', 'wrap_in_strong' ), $plugin_names ); + $last_plugin = array_pop( $plugin_names ); // Pop off last name to prep for readability. + $imploded = empty( $plugin_names ) ? $last_plugin : ( implode( ', ', $plugin_names ) . ' ' . esc_html_x( 'and', 'plugin A *and* plugin B', 'cryout' ) . ' ' . $last_plugin ); + + printf( // WPCS: xss ok. + '

%1$s %2$s.

', + esc_html( _n( 'The following plugin was activated successfully:', 'The following plugins were activated successfully:', $count, 'cryout' ) ), + $imploded + ); + + // Update recently activated plugins option. + $recent = (array) get_option( 'recently_activated' ); + foreach ( $plugins_to_activate as $plugin => $time ) { + if ( isset( $recent[ $plugin ] ) ) { + unset( $recent[ $plugin ] ); + } + } + update_option( 'recently_activated', $recent ); + } + + unset( $_POST ); // Reset the $_POST variable in case user wants to perform one action after another. + + return true; + } + + return false; + } + + /** + * Prepares all of our information to be outputted into a usable table. + * + * @since 2.2.0 + */ + public function prepare_items() { + $columns = $this->get_columns(); // Get all necessary column information. + $hidden = array(); // No columns to hide, but we must set as an array. + $sortable = array(); // No reason to make sortable columns. + $primary = $this->get_primary_column_name(); // Column which has the row actions. + $this->_column_headers = array( $columns, $hidden, $sortable, $primary ); // Get all necessary column headers. + + // Process our bulk activations here. + if ( 'tgmpa-bulk-activate' === $this->current_action() ) { + $this->process_bulk_actions(); + } + + // Store all of our plugin data into $items array so WP_List_Table can use it. + $this->items = apply_filters( 'tgmpa_table_data_items', $this->_gather_plugin_data() ); + } + + /* *********** DEPRECATED METHODS *********** */ + + /** + * Retrieve plugin data, given the plugin name. + * + * @since 2.2.0 + * @deprecated 2.5.0 use {@see TGM_Plugin_Activation::_get_plugin_data_from_name()} instead. + * @see TGM_Plugin_Activation::_get_plugin_data_from_name() + * + * @param string $name Name of the plugin, as it was registered. + * @param string $data Optional. Array key of plugin data to return. Default is slug. + * @return string|boolean Plugin slug if found, false otherwise. + */ + protected function _get_plugin_data_from_name( $name, $data = 'slug' ) { + _deprecated_function( __FUNCTION__, 'TGMPA 2.5.0', 'TGM_Plugin_Activation::_get_plugin_data_from_name()' ); + + return $this->tgmpa->_get_plugin_data_from_name( $name, $data ); + } + } +} + + +if ( ! class_exists( 'TGM_Bulk_Installer' ) ) { + + /** + * Hack: Prevent TGMPA v2.4.1- bulk installer class from being loaded if 2.4.1- is loaded after 2.5+. + */ + class TGM_Bulk_Installer { + } +} +if ( ! class_exists( 'TGM_Bulk_Installer_Skin' ) ) { + + /** + * Hack: Prevent TGMPA v2.4.1- bulk installer skin class from being loaded if 2.4.1- is loaded after 2.5+. + */ + class TGM_Bulk_Installer_Skin { + } +} + +/** + * The WP_Upgrader file isn't always available. If it isn't available, + * we load it here. + * + * We check to make sure no action or activation keys are set so that WordPress + * does not try to re-include the class when processing upgrades or installs outside + * of the class. + * + * @since 2.2.0 + */ +add_action( 'admin_init', 'tgmpa_load_bulk_installer' ); +if ( ! function_exists( 'tgmpa_load_bulk_installer' ) ) { + /** + * Load bulk installer + */ + function tgmpa_load_bulk_installer() { + // Silently fail if 2.5+ is loaded *after* an older version. + if ( ! isset( $GLOBALS['tgmpa'] ) ) { + return; + } + + // Get TGMPA class instance. + $tgmpa_instance = call_user_func( array( get_class( $GLOBALS['tgmpa'] ), 'get_instance' ) ); + + if ( isset( $_GET['page'] ) && $tgmpa_instance->menu === $_GET['page'] ) { + if ( ! class_exists( 'Plugin_Upgrader', false ) ) { + require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php'; + } + + if ( ! class_exists( 'TGMPA_Bulk_Installer' ) ) { + + /** + * Installer class to handle bulk plugin installations. + * + * Extends WP_Upgrader and customizes to suit the installation of multiple + * plugins. + * + * @since 2.2.0 + * + * @internal Since 2.5.0 the class is an extension of Plugin_Upgrader rather than WP_Upgrader + * @internal Since 2.5.2 the class has been renamed from TGM_Bulk_Installer to TGMPA_Bulk_Installer. + * This was done to prevent backward compatibility issues with v2.3.6. + * + * @package TGM-Plugin-Activation + * @author Thomas Griffin + * @author Gary Jones + */ + class TGMPA_Bulk_Installer extends Plugin_Upgrader { + /** + * Holds result of bulk plugin installation. + * + * @since 2.2.0 + * + * @var string + */ + public $result; + + /** + * Flag to check if bulk installation is occurring or not. + * + * @since 2.2.0 + * + * @var boolean + */ + public $bulk = false; + + /** + * TGMPA instance + * + * @since 2.5.0 + * + * @var object + */ + protected $tgmpa; + + /** + * Whether or not the destination directory needs to be cleared ( = on update). + * + * @since 2.5.0 + * + * @var bool + */ + protected $clear_destination = false; + + /** + * References parent constructor and sets defaults for class. + * + * @since 2.2.0 + * + * @param \Bulk_Upgrader_Skin|null $skin Installer skin. + */ + public function __construct( $skin = null ) { + // Get TGMPA class instance. + $this->tgmpa = call_user_func( array( get_class( $GLOBALS['tgmpa'] ), 'get_instance' ) ); + + parent::__construct( $skin ); + + if ( isset( $this->skin->options['install_type'] ) && 'update' === $this->skin->options['install_type'] ) { + $this->clear_destination = true; + } + + if ( $this->tgmpa->is_automatic ) { + $this->activate_strings(); + } + + add_action( 'upgrader_process_complete', array( $this->tgmpa, 'populate_file_path' ) ); + } + + /** + * Sets the correct activation strings for the installer skin to use. + * + * @since 2.2.0 + */ + public function activate_strings() { + $this->strings['activation_failed'] = __( 'Plugin activation failed.', 'cryout' ); + $this->strings['activation_success'] = __( 'Plugin activated successfully.', 'cryout' ); + } + + /** + * Performs the actual installation of each plugin. + * + * @since 2.2.0 + * + * @see WP_Upgrader::run() + * + * @param array $options The installation config options. + * @return null|array Return early if error, array of installation data on success. + */ + public function run( $options ) { + $result = parent::run( $options ); + + // Reset the strings in case we changed one during automatic activation. + if ( $this->tgmpa->is_automatic ) { + if ( 'update' === $this->skin->options['install_type'] ) { + $this->upgrade_strings(); + } else { + $this->install_strings(); + } + } + + return $result; + } + + /** + * Processes the bulk installation of plugins. + * + * @since 2.2.0 + * + * @internal This is basically a near identical copy of the WP Core Plugin_Upgrader::bulk_upgrade() + * method, with minor adjustments to deal with new installs instead of upgrades. + * For ease of future synchronizations, the adjustments are clearly commented, but no other + * comments are added. Code style has been made to comply. + * + * @see Plugin_Upgrader::bulk_upgrade() + * @see https://core.trac.wordpress.org/browser/tags/4.2.1/src/wp-admin/includes/class-wp-upgrader.php#L838 + * + * @param array $plugins The plugin sources needed for installation. + * @param array $args Arbitrary passed extra arguments. + * @return string|bool Install confirmation messages on success, false on failure. + */ + public function bulk_install( $plugins, $args = array() ) { + // [TGMPA + ] Hook auto-activation in. + add_filter( 'upgrader_post_install', array( $this, 'auto_activate' ), 10 ); + + $defaults = array( + 'clear_update_cache' => true, + ); + $parsed_args = wp_parse_args( $args, $defaults ); + + $this->init(); + $this->bulk = true; + + $this->install_strings(); // [TGMPA + ] adjusted. + + /* [TGMPA - ] $current = get_site_transient( 'update_plugins' ); */ + + /* [TGMPA - ] add_filter('upgrader_clear_destination', array($this, 'delete_old_plugin'), 10, 4); */ + + $this->skin->header(); + + // Connect to the Filesystem first. + $res = $this->fs_connect( array( WP_CONTENT_DIR, WP_PLUGIN_DIR ) ); + if ( ! $res ) { + $this->skin->footer(); + + return false; + } + + $this->skin->bulk_header(); + + // Only start maintenance mode if: + // - running Multisite and there are one or more plugins specified, OR + // - a plugin with an update available is currently active. + // @TODO: For multisite, maintenance mode should only kick in for individual sites if at all possible. + $maintenance = ( is_multisite() && ! empty( $plugins ) ); + + /* + [TGMPA - ] + foreach ( $plugins as $plugin ) + $maintenance = $maintenance || ( is_plugin_active( $plugin ) && isset( $current->response[ $plugin] ) ); + */ + if ( $maintenance ) { + $this->maintenance_mode( true ); + } + + $results = array(); + + $this->update_count = count( $plugins ); + $this->update_current = 0; + foreach ( $plugins as $plugin ) { + $this->update_current++; + + /* + [TGMPA - ] + $this->skin->plugin_info = get_plugin_data( WP_PLUGIN_DIR . '/' . $plugin, false, true); + + if ( !isset( $current->response[ $plugin ] ) ) { + $this->skin->set_result('up_to_date'); + $this->skin->before(); + $this->skin->feedback('up_to_date'); + $this->skin->after(); + $results[$plugin] = true; + continue; + } + + // Get the URL to the zip file + $r = $current->response[ $plugin ]; + + $this->skin->plugin_active = is_plugin_active($plugin); + */ + + $result = $this->run( array( + 'package' => $plugin, // [TGMPA + ] adjusted. + 'destination' => WP_PLUGIN_DIR, + 'clear_destination' => false, // [TGMPA + ] adjusted. + 'clear_working' => true, + 'is_multi' => true, + 'hook_extra' => array( + 'plugin' => $plugin, + ), + ) ); + + $results[ $plugin ] = $this->result; + + // Prevent credentials auth screen from displaying multiple times. + if ( false === $result ) { + break; + } + } //end foreach $plugins + + $this->maintenance_mode( false ); + + /** + * Fires when the bulk upgrader process is complete. + * + * @since WP 3.6.0 / TGMPA 2.5.0 + * + * @param Plugin_Upgrader $this Plugin_Upgrader instance. In other contexts, $this, might + * be a Theme_Upgrader or Core_Upgrade instance. + * @param array $data { + * Array of bulk item update data. + * + * @type string $action Type of action. Default 'update'. + * @type string $type Type of update process. Accepts 'plugin', 'theme', or 'core'. + * @type bool $bulk Whether the update process is a bulk update. Default true. + * @type array $packages Array of plugin, theme, or core packages to update. + * } + */ + do_action( 'upgrader_process_complete', $this, array( + 'action' => 'install', // [TGMPA + ] adjusted. + 'type' => 'plugin', + 'bulk' => true, + 'plugins' => $plugins, + ) ); + + $this->skin->bulk_footer(); + + $this->skin->footer(); + + // Cleanup our hooks, in case something else does a upgrade on this connection. + /* [TGMPA - ] remove_filter('upgrader_clear_destination', array($this, 'delete_old_plugin')); */ + + // [TGMPA + ] Remove our auto-activation hook. + remove_filter( 'upgrader_post_install', array( $this, 'auto_activate' ), 10 ); + + // Force refresh of plugin update information. + wp_clean_plugins_cache( $parsed_args['clear_update_cache'] ); + + return $results; + } + + /** + * Handle a bulk upgrade request. + * + * @since 2.5.0 + * + * @see Plugin_Upgrader::bulk_upgrade() + * + * @param array $plugins The local WP file_path's of the plugins which should be upgraded. + * @param array $args Arbitrary passed extra arguments. + * @return string|bool Install confirmation messages on success, false on failure. + */ + public function bulk_upgrade( $plugins, $args = array() ) { + + add_filter( 'upgrader_post_install', array( $this, 'auto_activate' ), 10 ); + + $result = parent::bulk_upgrade( $plugins, $args ); + + remove_filter( 'upgrader_post_install', array( $this, 'auto_activate' ), 10 ); + + return $result; + } + + /** + * Abuse a filter to auto-activate plugins after installation. + * + * Hooked into the 'upgrader_post_install' filter hook. + * + * @since 2.5.0 + * + * @param bool $bool The value we need to give back (true). + * @return bool + */ + public function auto_activate( $bool ) { + // Only process the activation of installed plugins if the automatic flag is set to true. + if ( $this->tgmpa->is_automatic ) { + // Flush plugins cache so the headers of the newly installed plugins will be read correctly. + wp_clean_plugins_cache(); + + // Get the installed plugin file. + $plugin_info = $this->plugin_info(); + + // Don't try to activate on upgrade of active plugin as WP will do this already. + if ( ! is_plugin_active( $plugin_info ) ) { + $activate = activate_plugin( $plugin_info ); + + // Adjust the success string based on the activation result. + $this->strings['process_success'] = $this->strings['process_success'] . "
\n"; + + if ( is_wp_error( $activate ) ) { + $this->skin->error( $activate ); + $this->strings['process_success'] .= $this->strings['activation_failed']; + } else { + $this->strings['process_success'] .= $this->strings['activation_success']; + } + } + } + + return $bool; + } + } + } + + if ( ! class_exists( 'TGMPA_Bulk_Installer_Skin' ) ) { + + /** + * Installer skin to set strings for the bulk plugin installations.. + * + * Extends Bulk_Upgrader_Skin and customizes to suit the installation of multiple + * plugins. + * + * @since 2.2.0 + * + * @internal Since 2.5.2 the class has been renamed from TGM_Bulk_Installer_Skin to + * TGMPA_Bulk_Installer_Skin. + * This was done to prevent backward compatibility issues with v2.3.6. + * + * @see https://core.trac.wordpress.org/browser/trunk/src/wp-admin/includes/class-wp-upgrader-skins.php + * + * @package TGM-Plugin-Activation + * @author Thomas Griffin + * @author Gary Jones + */ + class TGMPA_Bulk_Installer_Skin extends Bulk_Upgrader_Skin { + /** + * Holds plugin info for each individual plugin installation. + * + * @since 2.2.0 + * + * @var array + */ + public $plugin_info = array(); + + /** + * Holds names of plugins that are undergoing bulk installations. + * + * @since 2.2.0 + * + * @var array + */ + public $plugin_names = array(); + + /** + * Integer to use for iteration through each plugin installation. + * + * @since 2.2.0 + * + * @var integer + */ + public $i = 0; + + /** + * TGMPA instance + * + * @since 2.5.0 + * + * @var object + */ + protected $tgmpa; + + /** + * Constructor. Parses default args with new ones and extracts them for use. + * + * @since 2.2.0 + * + * @param array $args Arguments to pass for use within the class. + */ + public function __construct( $args = array() ) { + // Get TGMPA class instance. + $this->tgmpa = call_user_func( array( get_class( $GLOBALS['tgmpa'] ), 'get_instance' ) ); + + // Parse default and new args. + $defaults = array( + 'url' => '', + 'nonce' => '', + 'names' => array(), + 'install_type' => 'install', + ); + $args = wp_parse_args( $args, $defaults ); + + // Set plugin names to $this->plugin_names property. + $this->plugin_names = $args['names']; + + // Extract the new args. + parent::__construct( $args ); + } + + /** + * Sets install skin strings for each individual plugin. + * + * Checks to see if the automatic activation flag is set and uses the + * the proper strings accordingly. + * + * @since 2.2.0 + */ + public function add_strings() { + if ( 'update' === $this->options['install_type'] ) { + parent::add_strings(); + $this->upgrader->strings['skin_before_update_header'] = __( 'Updating Plugin %1$s (%2$d/%3$d)', 'cryout' ); + } else { + $this->upgrader->strings['skin_update_failed_error'] = __( 'An error occurred while installing %1$s: %2$s.', 'cryout' ); + $this->upgrader->strings['skin_update_failed'] = __( 'The installation of %1$s failed.', 'cryout' ); + + if ( $this->tgmpa->is_automatic ) { + // Automatic activation strings. + $this->upgrader->strings['skin_upgrade_start'] = __( 'The installation and activation process is starting. This process may take a while on some hosts, so please be patient.', 'cryout' ); + $this->upgrader->strings['skin_update_successful'] = __( '%1$s installed and activated successfully.', 'cryout' ) . ' ' . esc_html__( 'Show Details', 'cryout' ) . '.'; + $this->upgrader->strings['skin_upgrade_end'] = __( 'All installations and activations have been completed.', 'cryout' ); + $this->upgrader->strings['skin_before_update_header'] = __( 'Installing and Activating Plugin %1$s (%2$d/%3$d)', 'cryout' ); + } else { + // Default installation strings. + $this->upgrader->strings['skin_upgrade_start'] = __( 'The installation process is starting. This process may take a while on some hosts, so please be patient.', 'cryout' ); + $this->upgrader->strings['skin_update_successful'] = esc_html__( '%1$s installed successfully.', 'cryout' ) . ' ' . esc_html__( 'Show Details', 'cryout' ) . '.'; + $this->upgrader->strings['skin_upgrade_end'] = __( 'All installations have been completed.', 'cryout' ); + $this->upgrader->strings['skin_before_update_header'] = __( 'Installing Plugin %1$s (%2$d/%3$d)', 'cryout' ); + } + } + } + + /** + * Outputs the header strings and necessary JS before each plugin installation. + * + * @since 2.2.0 + * + * @param string $title Unused in this implementation. + */ + public function before( $title = '' ) { + if ( empty( $title ) ) { + $title = esc_html( $this->plugin_names[ $this->i ] ); + } + parent::before( $title ); + } + + /** + * Outputs the footer strings and necessary JS after each plugin installation. + * + * Checks for any errors and outputs them if they exist, else output + * success strings. + * + * @since 2.2.0 + * + * @param string $title Unused in this implementation. + */ + public function after( $title = '' ) { + if ( empty( $title ) ) { + $title = esc_html( $this->plugin_names[ $this->i ] ); + } + parent::after( $title ); + + $this->i++; + } + + /** + * Outputs links after bulk plugin installation is complete. + * + * @since 2.2.0 + */ + public function bulk_footer() { + // Serve up the string to say installations (and possibly activations) are complete. + parent::bulk_footer(); + + // Flush plugins cache so we can make sure that the installed plugins list is always up to date. + wp_clean_plugins_cache(); + + $this->tgmpa->show_tgmpa_version(); + + // Display message based on if all plugins are now active or not. + $update_actions = array(); + + if ( $this->tgmpa->is_tgmpa_complete() ) { + // All plugins are active, so we display the complete string and hide the menu to protect users. + echo ''; + $update_actions['dashboard'] = sprintf( + esc_html( $this->tgmpa->strings['complete'] ), + '' . esc_html__( 'Return to the Dashboard', 'cryout' ) . '' + ); + } else { + $update_actions['tgmpa_page'] = '' . esc_html( $this->tgmpa->strings['return'] ) . ''; + } + + /** + * Filter the list of action links available following bulk plugin installs/updates. + * + * @since 2.5.0 + * + * @param array $update_actions Array of plugin action links. + * @param array $plugin_info Array of information for the last-handled plugin. + */ + $update_actions = apply_filters( 'tgmpa_update_bulk_plugins_complete_actions', $update_actions, $this->plugin_info ); + + if ( ! empty( $update_actions ) ) { + $this->feedback( implode( ' | ', (array) $update_actions ) ); + } + } + + /* *********** DEPRECATED METHODS *********** */ + + /** + * Flush header output buffer. + * + * @since 2.2.0 + * @deprecated 2.5.0 use {@see Bulk_Upgrader_Skin::flush_output()} instead + * @see Bulk_Upgrader_Skin::flush_output() + */ + public function before_flush_output() { + _deprecated_function( __FUNCTION__, 'TGMPA 2.5.0', 'Bulk_Upgrader_Skin::flush_output()' ); + $this->flush_output(); + } + + /** + * Flush footer output buffer and iterate $this->i to make sure the + * installation strings reference the correct plugin. + * + * @since 2.2.0 + * @deprecated 2.5.0 use {@see Bulk_Upgrader_Skin::flush_output()} instead + * @see Bulk_Upgrader_Skin::flush_output() + */ + public function after_flush_output() { + _deprecated_function( __FUNCTION__, 'TGMPA 2.5.0', 'Bulk_Upgrader_Skin::flush_output()' ); + $this->flush_output(); + $this->i++; + } + } + } + } + } +} + +if ( ! class_exists( 'TGMPA_Utils' ) ) { + + /** + * Generic utilities for TGMPA. + * + * All methods are static, poor-dev name-spacing class wrapper. + * + * Class was called TGM_Utils in 2.5.0 but renamed TGMPA_Utils in 2.5.1 as this was conflicting with Soliloquy. + * + * @since 2.5.0 + * + * @package TGM-Plugin-Activation + * @author Juliette Reinders Folmer + */ + class TGMPA_Utils { + /** + * Whether the PHP filter extension is enabled. + * + * @see http://php.net/book.filter + * + * @since 2.5.0 + * + * @static + * + * @var bool $has_filters True is the extension is enabled. + */ + public static $has_filters; + + /** + * Wrap an arbitrary string in tags. Meant to be used in combination with array_map(). + * + * @since 2.5.0 + * + * @static + * + * @param string $string Text to be wrapped. + * @return string + */ + public static function wrap_in_em( $string ) { + return '' . wp_kses_post( $string ) . ''; + } + + /** + * Wrap an arbitrary string in tags. Meant to be used in combination with array_map(). + * + * @since 2.5.0 + * + * @static + * + * @param string $string Text to be wrapped. + * @return string + */ + public static function wrap_in_strong( $string ) { + return '' . wp_kses_post( $string ) . ''; + } + + /** + * Helper function: Validate a value as boolean + * + * @since 2.5.0 + * + * @static + * + * @param mixed $value Arbitrary value. + * @return bool + */ + public static function validate_bool( $value ) { + if ( ! isset( self::$has_filters ) ) { + self::$has_filters = extension_loaded( 'filter' ); + } + + if ( self::$has_filters ) { + return filter_var( $value, FILTER_VALIDATE_BOOLEAN ); + } else { + return self::emulate_filter_bool( $value ); + } + } + + /** + * Helper function: Cast a value to bool + * + * @since 2.5.0 + * + * @static + * + * @param mixed $value Value to cast. + * @return bool + */ + protected static function emulate_filter_bool( $value ) { + // @codingStandardsIgnoreStart + static $true = array( + '1', + 'true', 'True', 'TRUE', + 'y', 'Y', + 'yes', 'Yes', 'YES', + 'on', 'On', 'ON', + ); + static $false = array( + '0', + 'false', 'False', 'FALSE', + 'n', 'N', + 'no', 'No', 'NO', + 'off', 'Off', 'OFF', + ); + // @codingStandardsIgnoreEnd + + if ( is_bool( $value ) ) { + return $value; + } else if ( is_int( $value ) && ( 0 === $value || 1 === $value ) ) { + return (bool) $value; + } else if ( ( is_float( $value ) && ! is_nan( $value ) ) && ( (float) 0 === $value || (float) 1 === $value ) ) { + return (bool) $value; + } else if ( is_string( $value ) ) { + $value = trim( $value ); + if ( in_array( $value, $true, true ) ) { + return true; + } else if ( in_array( $value, $false, true ) ) { + return false; + } else { + return false; + } + } + + return false; + } + } // End of class TGMPA_Utils +} // End of class_exists wrapper + diff --git a/themes/mantra/includes/theme-functions.php b/themes/mantra/includes/theme-functions.php index e19b5c56..be80229e 100644 --- a/themes/mantra/includes/theme-functions.php +++ b/themes/mantra/includes/theme-functions.php @@ -98,7 +98,7 @@ function mantra_title_and_description() { case 'Site Title and Description': echo '
'; - $heading_tag = ( is_home() || is_front_page() ) ? 'h1' : 'div'; + $heading_tag = ( ( is_home() || is_front_page() ) && !is_page() ) ? 'h1' : 'div'; echo '<'.$heading_tag.' id="site-title">'; echo ' '.get_bloginfo( 'name' ).' '; echo ''; diff --git a/themes/mantra/includes/theme-seo.php b/themes/mantra/includes/theme-seo.php deleted file mode 100644 index 09b3540a..00000000 --- a/themes/mantra/includes/theme-seo.php +++ /dev/null @@ -1,194 +0,0 @@ -0)&&(strlen($title)>0))?$title.' - '.$site_name:$title.$site_name); - // Get the Site Description - $site_description = get_bloginfo( 'description' ); - // If site front page, append description - if ( (is_home() || is_front_page()) && $site_description ) { - // Append Site Description to title - $filtered_title = ((strlen($site_name)>0)&&(strlen($site_description)>0))?$site_name. " | ".$site_description:$site_name.$site_description; - } - // Add pagination if that's the case - global $page, $paged; - if ( $paged >= 2 || $page >= 2 ) - $filtered_title .= ' | ' . sprintf( __( 'Page %s', 'mantra' ), max( $paged, $page ) ); - - // Return the modified title - return $filtered_title; -} - -function mantra_filter_wp_title_rss($title) { -return ' '; -} -add_filter( 'wp_title', 'mantra_filter_wp_title' ); -add_filter('wp_title_rss','mantra_filter_wp_title_rss'); - - /** - * Meta description - */ -function mantra_seo_description() { - global $mantra_options; - foreach ($mantra_options as $key => $value) { - ${"$key"} = $value ;} - - if ( (is_home() && $mantra_seo_home_desc) || (is_page_template('template-blog.php') && $mantra_seo_home_desc) ) { - echo PHP_EOL.''; } - else if ((is_single() || is_page()) && !is_404()) { - if ($mantra_seo_gen_desc =="Auto") { - global $post; - $content_post = get_post($post->ID); - $content = strip_shortcodes($content_post->post_content); - $content = preg_replace(array('/\s{2,}/', '/[\t\n]/'), ' ', $content); - $content = strip_tags($content); - $content = str_replace('"','',$content); - $content = preg_replace('/((\w+\W+\'*){'.(33).'}(\w+))(.*)/', '${1}', $content); - } - else if ($mantra_seo_gen_desc=="Manual") { - global $post,$mantra_meta_box_description; - $content = get_post_meta($post->ID,'SEOdescription_value',true); - } - - echo PHP_EOL.''; } - else if (is_category() && category_description() != "") { - echo PHP_EOL.''; } - -} - - /** - * Meta author - */ -function mantra_seo_name() { - global $mantra_options; - foreach ($mantra_options as $key => $value) { - ${"$key"} = $value ;} -echo ''; -} - -/** - * Meta Title - */ -function mantra_seo_title() { -echo ''; -} - - -// Mantra main seo function -function mantra_seo_generator() { -global $mantra_options; -foreach ($mantra_options as $key => $value) { -${"$key"} = $value ;} -add_action ('cryout_seo_hook','mantra_seo_title'); -add_action ('cryout_seo_hook','mantra_seo_description'); - -if($mantra_seo_author && $mantra_seo_author!="Do not use") - add_action ('cryout_seo_hook','mantra_seo_name'); -} - -if($mantra_seo=="Enable") mantra_seo_generator() ; - else add_action ('cryout_seo_hook','mantra_seo_title',0); - -// Mantra favicon -function mantra_fav_icon() { -global $mantra_options; -foreach ($mantra_options as $key => $value) { -${"$key"} = $value ;} - echo ''; - echo ''; - } - -if ($mantra_options['mantra_favicon']) add_action ('cryout_header_hook','mantra_fav_icon'); - - -/* -Plugin Name: Custom Write Panel -Plugin URI: http://wefunction.com/2008/10/tutorial-create-custom-write-panels-in-wordpress -Description: Allows custom fields to be added to the WordPress Post Page -Version: 1.0 -Author: Spencer -Author URI: http://wefunction.com -/* ----------------------------------------------*/ - -$mantra_meta_box_description = -array( -"image" => array( -"name" => "SEOdescription", -"std" => "", -"title" => "Input the SEO description for this post/page here (about 160 characters): ", -"description" => "This description is for SEO purposes only. It will be used as a meta in your HTML header. It won't be vislbe anywhere else.
More SEO options in the Mantra Settings Page >> Misc Options >> SEO.") -); - -function mantra_meta_box_description() { -global $post, $mantra_meta_box_description; - -foreach($mantra_meta_box_description as $meta_box) { -$meta_box_value = get_post_meta($post->ID, $meta_box['name'].'_value', true); - -if($meta_box_value == "") -$meta_box_value = $meta_box['std']; - -echo ''; - -echo '

'.$meta_box['title'].'

'; - -echo '
'; - -echo '

'; -} -} - -function mantra_create_meta_box() { -global $theme_name; -add_meta_box( 'new-meta-boxes', 'Mantra SEO - Description', 'mantra_meta_box_description', 'post', 'normal', 'high' ); -add_meta_box( 'new-meta-boxes', 'Mantra SEO - Description', 'mantra_meta_box_description', 'page', 'normal', 'high' ); -} - -function mantra_save_postdata( $post_id ) { -global $post, $mantra_meta_box_description; - -foreach($mantra_meta_box_description as $meta_box) { -// Verify -if ( !wp_verify_nonce( $_POST[$meta_box['name'].'_noncename'], plugin_basename(__FILE__) )) { -return $post_id; -} - -if ( 'page' == $_POST['post_type'] ) { -if ( !current_user_can( 'edit_page', $post_id )) -return $post_id; -} else { -if ( !current_user_can( 'edit_post', $post_id )) -return $post_id; -} - -$data = $_POST[$meta_box['name'].'_value']; - -if(get_post_meta($post_id, $meta_box['name'].'_value') == "") -add_post_meta($post_id, $meta_box['name'].'_value', $data, true); -elseif($data != get_post_meta($post_id, $meta_box['name'].'_value', true)) -update_post_meta($post_id, $meta_box['name'].'_value', $data); -elseif($data == "") -delete_post_meta($post_id, $meta_box['name'].'_value', get_post_meta($post_id, $meta_box['name'].'_value', true)); -} -} -if ($mantra_seo_gen_desc=="Manual") { - add_action('admin_menu', 'mantra_create_meta_box'); - add_action('save_post', 'mantra_save_postdata'); -} -?> \ No newline at end of file diff --git a/themes/mantra/includes/theme-styles.php b/themes/mantra/includes/theme-styles.php index 430c5a06..1d0a7ef1 100644 --- a/themes/mantra/includes/theme-styles.php +++ b/themes/mantra/includes/theme-styles.php @@ -20,9 +20,9 @@ function mantra_register_styles() { global $mantra_options; foreach ($mantra_options as $key => $value) { ${"$key"} = $value ;} - wp_register_style( 'mantras', get_stylesheet_uri() ); + wp_register_style( 'mantras', get_stylesheet_uri(), NULL, _CRYOUT_THEME_VERSION ); - if($mantra_mobile=="Enable") { wp_register_style( 'mantra-mobile', get_template_directory_uri() . '/style-mobile.css' );} + if($mantra_mobile=="Enable") { wp_register_style( 'mantra-mobile', get_template_directory_uri() . '/style-mobile.css', NULL, _CRYOUT_THEME_VERSION );} wp_register_style( 'mantra_googlefont', esc_attr($mantra_googlefont2 )); wp_register_style( 'mantra_googlefonttitle', esc_attr($mantra_googlefonttitle2 )); @@ -81,11 +81,11 @@ foreach ($mantra_options as $key => $value) { // If frontend - load the js for the menu and the social icons animations if ( !is_admin() ) { - wp_register_script('cryout-frontend',get_template_directory_uri() . '/js/frontend.js', array('jquery') ); + wp_register_script('cryout-frontend',get_template_directory_uri() . '/js/frontend.js', array('jquery'), _CRYOUT_THEME_VERSION ); wp_enqueue_script('cryout-frontend'); // If mantra from page is enabled and the current page is home page - load the nivo slider js if($mantra_frontpage == "Enable" && is_front_page()) { - wp_register_script('cryout-nivoSlider',get_template_directory_uri() . '/js/nivo-slider.js', array('jquery')); + wp_register_script('cryout-nivoSlider',get_template_directory_uri() . '/js/nivo-slider.js', array('jquery'), _CRYOUT_THEME_VERSION ); wp_enqueue_script('cryout-nivoSlider'); } } diff --git a/themes/mantra/languages/_mantra.mo b/themes/mantra/languages/_mantra.mo index 0e726753..5be602e3 100644 Binary files a/themes/mantra/languages/_mantra.mo and b/themes/mantra/languages/_mantra.mo differ diff --git a/themes/mantra/languages/_mantra.po b/themes/mantra/languages/_mantra.po index 6520f970..2545fd22 100644 --- a/themes/mantra/languages/_mantra.po +++ b/themes/mantra/languages/_mantra.po @@ -2,14 +2,14 @@ msgid "" msgstr "" "Project-Id-Version: Mantra 2.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2013-11-15 12:18+0200\n" -"PO-Revision-Date: 2013-11-15 12:18+0200\n" +"POT-Creation-Date: 2016-03-02 15:48+0200\n" +"PO-Revision-Date: 2016-03-02 15:50+0200\n" "Last-Translator: Kay \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 1.5.5\n" +"X-Generator: Poedit 1.6.10\n" "X-Poedit-KeywordsList: __;_e;_x\n" "X-Poedit-Basepath: ../\n" "X-Poedit-SearchPath-0: .\n" @@ -19,781 +19,565 @@ msgid "Not Found" msgstr "" #: 404.php:19 -msgid "Apologies, but the page you requested could not be found. Perhaps searching will help." -msgstr "" - -#: archive.php:27 -#, php-format -msgid "Daily Archives: %s" -msgstr "" - -#: archive.php:29 -#, php-format -msgid "Monthly Archives: %s" -msgstr "" - -#: archive.php:29 -msgid "F Y" -msgstr "" - -#: archive.php:31 -#, php-format -msgid "Yearly Archives: %s" -msgstr "" - -#: archive.php:31 -msgid "Y" -msgstr "" - -#: archive.php:33 -msgid "Blog Archives" -msgstr "" - -#: archive.php:59 -#: author.php:75 -#: category.php:51 -#: content-frontpage.php:26 -msgid "Nothing Found" -msgstr "" - -#: archive.php:63 -#: author.php:79 -#: category.php:55 -#: content-frontpage.php:30 -msgid "Apologies, but no results were found for the requested archive. Perhaps searching will help find a related post." -msgstr "" - -#: attachment.php:18 -#, php-format -msgid "Return to %s" -msgstr "" - -#: attachment.php:29 -msgid "By" -msgstr "" - -#: attachment.php:40 -msgid "Published" -msgstr "" - -#: attachment.php:50 -#, php-format -msgid "Full size is %s pixels" -msgstr "" - -#: attachment.php:53 -msgid "Link to full-size image" -msgstr "" - -#: attachment.php:60 -#: attachment.php:107 -#: content-aside.php:48 -#: content-chat.php:49 -#: content-gallery.php:75 -#: content-image.php:42 -#: content-link.php:49 -#: content-page.php:22 -#: content-quote.php:46 -#: content-status.php:48 -#: content.php:76 -msgid "Edit" -msgstr "" - -#: attachment.php:100 -msgid "Continue reading" -msgstr "" - -#: attachment.php:101 -#: content-aside.php:39 -#: content-chat.php:38 -#: content-gallery.php:65 -#: content-image.php:33 -#: content-link.php:38 -#: content-page.php:21 -#: content-quote.php:36 -#: content-status.php:39 -#: content.php:49 -#: content.php:65 -msgid "Pages:" -msgstr "" - -#: author.php:29 -#, php-format -msgid "Author Archives: %s" -msgstr "" - -#: author.php:50 -#, php-format -msgid "About %s" -msgstr "" - -#: category.php:20 -#, php-format -msgid "Category Archives: %s" -msgstr "" - -#: comments.php:18 -msgid "This post is password protected. Enter the password to view any comments." -msgstr "" - -#: content-aside.php:20 -msgid "Aside" -msgstr "" - -#: content-aside.php:38 -#: content-chat.php:37 -#: content-image.php:32 -#: content-link.php:37 -#: content-quote.php:35 -#: content-status.php:38 -msgid "Continue reading " -msgstr "" - -#: content-aside.php:46 -#: content-chat.php:45 -#: content-gallery.php:72 -#: content-image.php:39 -#: content-link.php:45 -#: content-quote.php:43 -#: content-status.php:46 -#: content.php:74 -msgid "Tagged" -msgstr "" - -#: content-chat.php:20 -msgid "Chat" -msgstr "" - -#: content-gallery.php:23 -msgid "Gallery" -msgstr "" - -#: content-image.php:19 -msgid "Image" -msgstr "" - -#: content-link.php:20 -msgid "Link" -msgstr "" - -#: content-page.php:27 -msgid "Comments are closed." -msgstr "" - -#: content-quote.php:18 -msgid "Quote" -msgstr "" - -#: content-status.php:30 -msgid "Status" -msgstr "" - -#: search.php:20 -#, php-format -msgid "Search Results for: %s" -msgstr "" - -#: search.php:39 -#, php-format -msgid "No search results for: %s" -msgstr "" - -#: searchform.php:1 -msgid "Search" -msgstr "" - -#: sidebar.php:26 -#: sidebar.php:92 -msgid "Sidebar 1" -msgstr "" - -#: sidebar.php:28 -#: sidebar.php:94 -#, php-format -msgid "You currently have no widgets set in the primary sidebar. You can add widgets via the Dashboard." -msgstr "" - -#: sidebar.php:29 -#: sidebar.php:61 -#: sidebar.php:95 -#: sidebar.php:128 -#, php-format -msgid "To hide this sidebar, switch to a different Layout via the Theme Settings." -msgstr "" - -#: sidebar.php:58 -#: sidebar.php:125 -msgid "Sidebar 2" -msgstr "" - -#: sidebar.php:60 -#: sidebar.php:127 -#, php-format -msgid "You currently have no widgets set in the secondary sidebar. You can add widgets via the Dashboard." -msgstr "" - -#: single.php:46 -msgid "View all posts by " -msgstr "" - -#: tag.php:21 -#, php-format -msgid "Tag Archives: %s" +msgid "" +"Apologies, but the page you requested could not be found. Perhaps searching " +"will help." msgstr "" -#: admin/admin-functions.php:62 -msgid "Before you can upload your import file, you will need to fix the following error:" +#: admin/admin-functions.php:82 +msgid "" +"Before you can upload your import file, you will need to fix the following " +"error:" msgstr "" -#: admin/admin-functions.php:70 +#: admin/admin-functions.php:90 msgid "Import Mantra Theme Options" msgstr "" -#: admin/admin-functions.php:72 -msgid "Hi! This is where you import the Mantra settings. Please remember that this is still an experimental feature." +#: admin/admin-functions.php:92 +msgid "" +"Hi! This is where you import the Mantra settings. Please remember that " +"this is still an experimental feature." msgstr "" -#: admin/admin-functions.php:74 +#: admin/admin-functions.php:94 msgid "Just choose a file from your computer:" msgstr "" -#: admin/admin-functions.php:76 +#: admin/admin-functions.php:96 #, php-format msgid "Maximum size: %s" msgstr "" -#: admin/admin-functions.php:82 +#: admin/admin-functions.php:102 msgid "And import!" msgstr "" -#: admin/admin-functions.php:148 +#: admin/admin-functions.php:168 msgid "Import Mantra Theme Options " msgstr "" -#: admin/admin-functions.php:151 +#: admin/admin-functions.php:171 msgid "Great! The options have been imported!" msgstr "" -#: admin/admin-functions.php:152 +#: admin/admin-functions.php:172 msgid "Go back to the Mantra options page and check them out!" msgstr "" -#: admin/admin-functions.php:155 -#: admin/admin-functions.php:161 -#: admin/admin-functions.php:167 +#: admin/admin-functions.php:175 admin/admin-functions.php:181 +#: admin/admin-functions.php:187 msgid "Oops, there's a small problem." msgstr "" -#: admin/admin-functions.php:156 -msgid "The uploaded file does not contain valid Mantra options. Make sure the file is exported from the Mantra Options page." +#: admin/admin-functions.php:176 +msgid "" +"The uploaded file does not contain valid Mantra options. Make sure the file " +"is exported from the Mantra Options page." msgstr "" -#: admin/admin-functions.php:162 +#: admin/admin-functions.php:182 msgid "The uploaded file could not be read." msgstr "" -#: admin/admin-functions.php:168 -msgid "The uploaded file is not supported. Make sure the file was exported from the Mantra page and that it is a text file." +#: admin/admin-functions.php:188 +msgid "" +"The uploaded file is not supported. Make sure the file was exported from the " +"Mantra page and that it is a text file." msgstr "" -#: admin/admin-functions.php:177 -msgid "Oops! The file is empty or there was no file. This error could also be caused by uploads being disabled in your php.ini or by post_max_size being defined as smaller than upload_max_filesize in php.ini." +#: admin/admin-functions.php:197 +msgid "" +"Oops! The file is empty or there was no file. This error could also be " +"caused by uploads being disabled in your php.ini or by post_max_size being " +"defined as smaller than upload_max_filesize in php.ini." msgstr "" -#: admin/admin-functions.php:183 +#: admin/admin-functions.php:203 msgid "ERROR: You are not authorised to perform that operation" msgstr "" -#: admin/main.php:105 +#: admin/main.php:98 msgid "Layout Settings" msgstr "" -#: admin/main.php:106 +#: admin/main.php:99 msgid "Header Settings" msgstr "" -#: admin/main.php:107 +#: admin/main.php:100 msgid "Presentation Page" msgstr "" -#: admin/main.php:108 +#: admin/main.php:101 msgid "Text Settings" msgstr "" -#: admin/main.php:109 +#: admin/main.php:102 msgid "Color Settings" msgstr "" -#: admin/main.php:110 +#: admin/main.php:103 msgid "Graphics Settings" msgstr "" -#: admin/main.php:111 +#: admin/main.php:104 msgid "Post Information Settings" msgstr "" -#: admin/main.php:112 +#: admin/main.php:105 msgid "Post Excerpt Settings" msgstr "" -#: admin/main.php:113 +#: admin/main.php:106 msgid "Featured Image Settings" msgstr "" -#: admin/main.php:114 +#: admin/main.php:107 msgid "Social Media Settings" msgstr "" -#: admin/main.php:115 +#: admin/main.php:108 msgid "Miscellaneous Settings" msgstr "" -#: admin/main.php:118 +#: admin/main.php:111 msgid "Main Layout" msgstr "" -#: admin/main.php:119 +#: admin/main.php:112 msgid "Content / Sidebar Width" msgstr "" -#: admin/main.php:120 +#: admin/main.php:113 msgid "Responsiveness" msgstr "" -#: admin/main.php:123 +#: admin/main.php:116 msgid "Enable Presentation Page" msgstr "" -#: admin/main.php:124 +#: admin/main.php:117 msgid "Show Posts on Presentation Page" msgstr "" -#: admin/main.php:125 +#: admin/main.php:118 msgid "Slider Settings" msgstr "" -#: admin/main.php:126 +#: admin/main.php:119 msgid "Slides" msgstr "" -#: admin/main.php:127 +#: admin/main.php:120 msgid "Presentation Page Columns" msgstr "" -#: admin/main.php:128 +#: admin/main.php:121 msgid "Extras" msgstr "" -#: admin/main.php:131 +#: admin/main.php:124 msgid "Header Height" msgstr "" -#: admin/main.php:132 +#: admin/main.php:125 msgid "Header Image" msgstr "" -#: admin/main.php:133 +#: admin/main.php:126 msgid "Site Header" msgstr "" -#: admin/main.php:134 +#: admin/main.php:127 msgid "Custom Logo Upload" msgstr "" -#: admin/main.php:135 +#: admin/main.php:128 msgid "Header Spacing" msgstr "" -#: admin/main.php:136 +#: admin/main.php:129 msgid "Rounded Menu Corners" msgstr "" -#: admin/main.php:137 +#: admin/main.php:130 msgid "FavIcon Upload" msgstr "" -#: admin/main.php:139 +#: admin/main.php:132 msgid "General Font" msgstr "" -#: admin/main.php:140 +#: admin/main.php:133 msgid "General Font Size" msgstr "" -#: admin/main.php:141 +#: admin/main.php:134 msgid "Post Title Font " msgstr "" -#: admin/main.php:142 +#: admin/main.php:135 msgid "Post Title Font Size" msgstr "" -#: admin/main.php:143 +#: admin/main.php:136 msgid "Sidebar Font" msgstr "" -#: admin/main.php:144 +#: admin/main.php:137 msgid "SideBar Font Size" msgstr "" -#: admin/main.php:145 +#: admin/main.php:138 msgid "Headings Font" msgstr "" -#: admin/main.php:146 +#: admin/main.php:139 msgid "Force Text Align" msgstr "" -#: admin/main.php:147 +#: admin/main.php:140 msgid "Paragraph spacing" msgstr "" -#: admin/main.php:148 +#: admin/main.php:141 msgid "Paragraph indent" msgstr "" -#: admin/main.php:149 +#: admin/main.php:142 msgid "Header indent" msgstr "" -#: admin/main.php:150 +#: admin/main.php:143 msgid "Line Height" msgstr "" -#: admin/main.php:151 +#: admin/main.php:144 msgid "Word spacing" msgstr "" -#: admin/main.php:152 +#: admin/main.php:145 msgid "Letter spacing" msgstr "" -#: admin/main.php:153 +#: admin/main.php:146 msgid "Text shadow" msgstr "" -#: admin/main.php:155 +#: admin/main.php:148 msgid "Background Image" msgstr "" -#: admin/main.php:156 +#: admin/main.php:149 msgid "Background Color" msgstr "" -#: admin/main.php:157 +#: admin/main.php:150 msgid "Header (Banner and Menu) Background Color" msgstr "" -#: admin/main.php:158 +#: admin/main.php:151 msgid "Content Background Color" msgstr "" -#: admin/main.php:159 +#: admin/main.php:152 msgid "Menu Items Background Color" msgstr "" -#: admin/main.php:160 +#: admin/main.php:153 msgid "First Sidebar Background Color" msgstr "" -#: admin/main.php:161 +#: admin/main.php:154 msgid "Second Sidebar Background Color" msgstr "" -#: admin/main.php:163 +#: admin/main.php:156 msgid "Site Title Color" msgstr "" -#: admin/main.php:164 +#: admin/main.php:157 msgid "Site Description Color" msgstr "" -#: admin/main.php:166 +#: admin/main.php:159 msgid "Content Text Color" msgstr "" -#: admin/main.php:167 +#: admin/main.php:160 msgid "Links Color" msgstr "" -#: admin/main.php:168 +#: admin/main.php:161 msgid "Links Hover Color" msgstr "" -#: admin/main.php:169 +#: admin/main.php:162 msgid "Post Title Color" msgstr "" -#: admin/main.php:170 +#: admin/main.php:163 msgid "Post Title Hover Color" msgstr "" -#: admin/main.php:171 +#: admin/main.php:164 msgid "Sidebar Header Background Color" msgstr "" -#: admin/main.php:172 +#: admin/main.php:165 msgid "Sidebar Header Text Color" msgstr "" -#: admin/main.php:173 +#: admin/main.php:166 msgid "Footer Widget Background Color" msgstr "" -#: admin/main.php:174 +#: admin/main.php:167 msgid "Footer Background Color" msgstr "" -#: admin/main.php:175 +#: admin/main.php:168 msgid "Footer Widget Header Text Color" msgstr "" -#: admin/main.php:176 +#: admin/main.php:169 msgid "Footer Widget Link Color" msgstr "" -#: admin/main.php:177 +#: admin/main.php:170 msgid "Footer Widget Hover Color" msgstr "" -#: admin/main.php:179 +#: admin/main.php:172 msgid "Breadcrumbs" msgstr "" -#: admin/main.php:180 +#: admin/main.php:173 msgid "Pagination" msgstr "" -#: admin/main.php:181 +#: admin/main.php:174 msgid "Main Menu Alignment" msgstr "" -#: admin/main.php:182 +#: admin/main.php:175 msgid "Post Images Border" msgstr "" -#: admin/main.php:183 +#: admin/main.php:176 msgid "Caption Border" msgstr "" -#: admin/main.php:184 +#: admin/main.php:177 msgid "Caption Pin" msgstr "" -#: admin/main.php:185 +#: admin/main.php:178 msgid "Sidebar Menu Bullets" msgstr "" -#: admin/main.php:186 +#: admin/main.php:179 msgid "Meta Area Background" msgstr "" -#: admin/main.php:187 +#: admin/main.php:180 msgid "Post Separator" msgstr "" -#: admin/main.php:188 +#: admin/main.php:181 msgid "Content List Bullets" msgstr "" -#: admin/main.php:189 +#: admin/main.php:182 msgid "Page Titles" msgstr "" -#: admin/main.php:190 +#: admin/main.php:183 msgid "Category Page Titles" msgstr "" -#: admin/main.php:191 +#: admin/main.php:184 msgid "Hide Tables" msgstr "" -#: admin/main.php:192 +#: admin/main.php:185 msgid "Back to Top button" msgstr "" -#: admin/main.php:193 +#: admin/main.php:186 msgid "Text Under Comments" msgstr "" -#: admin/main.php:194 +#: admin/main.php:187 msgid "Comments are closed text" msgstr "" -#: admin/main.php:195 +#: admin/main.php:188 msgid "Comments off" msgstr "" -#: admin/main.php:197 +#: admin/main.php:190 msgid "Post Comments Link" msgstr "" -#: admin/main.php:198 +#: admin/main.php:191 msgid "Post Date" msgstr "" -#: admin/main.php:199 +#: admin/main.php:192 msgid "Post Time" msgstr "" -#: admin/main.php:200 -#: admin/settings.php:2087 +#: admin/main.php:193 msgid "Post Author" msgstr "" -#: admin/main.php:201 +#: admin/main.php:194 msgid "Post Category" msgstr "" -#: admin/main.php:202 +#: admin/main.php:195 msgid "Meta Bar" msgstr "" -#: admin/main.php:203 +#: admin/main.php:196 msgid "Post Tags" msgstr "" -#: admin/main.php:204 +#: admin/main.php:197 msgid "Post Permalink" msgstr "" -#: admin/main.php:206 +#: admin/main.php:199 msgid "Post Excerpts on Home Page" msgstr "" -#: admin/main.php:207 +#: admin/main.php:200 msgid "Affect Sticky Posts" msgstr "" -#: admin/main.php:208 +#: admin/main.php:201 msgid "Post Excerpts on Archive and Category Pages" msgstr "" -#: admin/main.php:209 +#: admin/main.php:202 msgid "Number of Words for Post Excerpts " msgstr "" -#: admin/main.php:210 +#: admin/main.php:203 msgid "Magazine Layout" msgstr "" -#: admin/main.php:211 +#: admin/main.php:204 msgid "Excerpt suffix" msgstr "" -#: admin/main.php:212 +#: admin/main.php:205 msgid "Continue reading link text " msgstr "" -#: admin/main.php:213 +#: admin/main.php:206 msgid "HTML tags in Excerpts" msgstr "" -#: admin/main.php:215 +#: admin/main.php:208 msgid "Featured Images as POST Thumbnails " msgstr "" -#: admin/main.php:216 +#: admin/main.php:209 msgid "Auto Select Images From Posts " msgstr "" -#: admin/main.php:217 +#: admin/main.php:210 msgid "Thumbnails Alignment " msgstr "" -#: admin/main.php:218 +#: admin/main.php:211 msgid "Thumbnails Size " msgstr "" -#: admin/main.php:219 +#: admin/main.php:212 msgid "Featured Images as HEADER Images " msgstr "" -#: admin/main.php:221 +#: admin/main.php:214 msgid "Link nr. 1" msgstr "" -#: admin/main.php:222 +#: admin/main.php:215 msgid "Link nr. 2" msgstr "" -#: admin/main.php:223 +#: admin/main.php:216 msgid "Link nr. 3" msgstr "" -#: admin/main.php:224 +#: admin/main.php:217 msgid "Link nr. 4" msgstr "" -#: admin/main.php:225 +#: admin/main.php:218 msgid "Link nr. 5" msgstr "" -#: admin/main.php:226 +#: admin/main.php:219 msgid "Socials display" msgstr "" -#: admin/main.php:228 -msgid "SEO Settings" -msgstr "" - -#: admin/main.php:229 +#: admin/main.php:221 msgid "Custom Footer Text" msgstr "" -#: admin/main.php:230 +#: admin/main.php:222 msgid "Custom CSS" msgstr "" -#: admin/main.php:231 +#: admin/main.php:223 msgid "Custom JavaScript" msgstr "" -#: admin/main.php:248 +#: admin/main.php:240 msgid "Sorry, but you do not have sufficient permissions to access this page." msgstr "" -#: admin/main.php:268 +#: admin/main.php:261 msgid "Mantra settings updated successfully." msgstr "" -#: admin/main.php:280 -msgid "Save Changes" -msgstr "" - -#: admin/main.php:281 -msgid "Reset to Defaults" -msgstr "" - -#: admin/main.php:313 +#: admin/main.php:309 msgid "Import/Export Settings" msgstr "" -#: admin/main.php:319 +#: admin/main.php:315 msgid "Export Theme options" msgstr "" -#: admin/main.php:320 -msgid "It's that easy: a mouse click away - the ability to export your Mantra settings and save them on your computer. Feeling safer? You should!" +#: admin/main.php:316 +msgid "" +"It's that easy: a mouse click away - the ability to export your Mantra " +"settings and save them on your computer. Feeling safer? You should!" msgstr "" -#: admin/main.php:325 +#: admin/main.php:321 msgid "Import Theme options" msgstr "" -#: admin/main.php:326 -msgid " Without the import, the export would just be a fool's exercise. Make sure you have the exported file ready and see you after the mouse click." +#: admin/main.php:322 +msgid "" +" Without the import, the export would just be a fool's exercise. Make sure " +"you have the exported file ready and see you after the mouse click." msgstr "" -#: admin/main.php:334 +#: admin/main.php:330 msgid "Mantra Latest News" msgstr "" -#: admin/main.php:345 +#: admin/main.php:342 msgid "No news items." msgstr "" -#: admin/main.php:349 +#: admin/main.php:346 msgid "Posted on" msgstr "" @@ -823,7 +607,8 @@ msgstr "" #: admin/settings.php:86 msgid "" -"Choose your layout. Possible options are:
No sidebar, a single sidebar on either left of right, two sidebars on either left or\n" +"Choose your layout. Possible options are:
No sidebar, a single sidebar " +"on either left of right, two sidebars on either left or\n" "\t\tright and two sidebars on each side." msgstr "" @@ -839,1030 +624,1466 @@ msgstr "" msgid "Dimensions to use: " msgstr "" -#: admin/settings.php:178 -#: admin/settings.php:198 +#: admin/settings.php:178 admin/settings.php:198 msgid "Content =" msgstr "" -#: admin/settings.php:179 -#: admin/settings.php:199 +#: admin/settings.php:179 admin/settings.php:199 msgid "Sidebar(s) =" msgstr "" -#: admin/settings.php:180 -#: admin/settings.php:200 +#: admin/settings.php:180 admin/settings.php:200 msgid "Total width =" msgstr "" #: admin/settings.php:189 msgid "" "Select the width of your content and sidebar(s).\n" -" \t\tWhile the content cannot be less than 500px wide, the sidebar area is at least 220px and no more than 800px.
\n" -"\tIf you went for a 3 column area ( with 2 sidebars) they will each have half the selected width." +" \t\tWhile the content cannot be less than 500px wide, the sidebar area is " +"at least 220px and no more than 800px.
\n" +"\tIf you went for a 3 column area ( with 2 sidebars) they will each have " +"half the selected width." msgstr "" #: admin/settings.php:209 msgid "" "Select the width of your content and sidebar(s).\n" -" \t\tThese are realtive dimmensions - relative to the user's browser. The total width is a percentage of the browser's width.
\n" -"\t While the content cannot be less than 40% wide, the sidebar area is at least 20% and no more than 50%.
\n" -"\tIf you went for a 3 column area ( with 2 sidebars) they will each have half the selected width." -msgstr "" - -#: admin/settings.php:223 -#: admin/settings.php:246 -#: admin/settings.php:262 -#: admin/settings.php:731 -#: admin/settings.php:1094 -#: admin/settings.php:1156 -#: admin/settings.php:1344 -#: admin/settings.php:1359 -#: admin/settings.php:1530 -#: admin/settings.php:1592 -#: admin/settings.php:1793 -#: admin/settings.php:1822 -#: admin/settings.php:1845 -#: admin/settings.php:1868 -#: admin/settings.php:1917 -#: admin/settings.php:2053 +" \t\tThese are realtive dimmensions - relative to the user's browser. The " +"total width is a percentage of the browser's width.
\n" +"\t While the content cannot be less than 40% wide, the sidebar area is at " +"least 20% and no more than 50%.
\n" +"\tIf you went for a 3 column area ( with 2 sidebars) they will each have " +"half the selected width." +msgstr "" + +#: admin/settings.php:223 admin/settings.php:250 admin/settings.php:269 +#: admin/settings.php:738 admin/settings.php:1101 admin/settings.php:1163 +#: admin/settings.php:1351 admin/settings.php:1366 admin/settings.php:1537 +#: admin/settings.php:1599 admin/settings.php:1800 admin/settings.php:1829 +#: admin/settings.php:1852 admin/settings.php:1875 admin/settings.php:1924 msgid "Enable" msgstr "" -#: admin/settings.php:223 -#: admin/settings.php:246 -#: admin/settings.php:262 -#: admin/settings.php:731 -#: admin/settings.php:1094 -#: admin/settings.php:1156 -#: admin/settings.php:1344 -#: admin/settings.php:1359 -#: admin/settings.php:1530 -#: admin/settings.php:1592 -#: admin/settings.php:1793 -#: admin/settings.php:1822 -#: admin/settings.php:1845 -#: admin/settings.php:1868 -#: admin/settings.php:1917 -#: admin/settings.php:2053 +#: admin/settings.php:223 admin/settings.php:250 admin/settings.php:269 +#: admin/settings.php:738 admin/settings.php:1101 admin/settings.php:1163 +#: admin/settings.php:1351 admin/settings.php:1366 admin/settings.php:1537 +#: admin/settings.php:1599 admin/settings.php:1800 admin/settings.php:1829 +#: admin/settings.php:1852 admin/settings.php:1875 admin/settings.php:1924 msgid "Disable" msgstr "" -#: admin/settings.php:232 -msgid "Enable to make Mantra fully responsive. The layout and general sizes of your blog will adjust depending on what device and what resolution it is viewed in.
Do not disable unless you have a good reason to." +#: admin/settings.php:236 +msgid "" +"Enable to make Mantra fully responsive. The layout and general sizes of your " +"blog will adjust depending on what device and what resolution it is viewed " +"in.
Do not disable unless you have a good reason to." msgstr "" -#: admin/settings.php:254 +#: admin/settings.php:258 msgid "" -"Enable the presentation front-page. This will become your new home page. It has a slider and columns for presentation\n" -"\t\ttext and images.
If you have this enabled but don't see a Presentation page then go to Settings » Reading and make sure you have selected Front Page Displays as Your Latest Posts." +"Enable the presentation front-page. This will become your new home page. It " +"has a slider and columns for presentation\n" +"\t\ttext and images.
If you have this enabled but don't see a " +"Presentation page then go to Settings » " +"Reading and make sure you have selected Front Page Displays as Your Latest Posts." msgstr "" -#: admin/settings.php:271 +#: admin/settings.php:261 +#, php-format +msgid "" +"You have enabled the Presentation Page but your WordPress' Front page " +"displays option is set to use a static page. WordPress guidelines " +"require that the static page option have priority over theme options.
Go " +"to %1$s and set the Front page displays option to Your " +"latest posts to display the presentation page." +msgstr "" + +#: admin/settings.php:278 msgid "posts" msgstr "" -#: admin/settings.php:272 -msgid "Enable to display latest posts on the presentation page, below the columns. Sticky posts are always displayed and not counted." +#: admin/settings.php:279 +msgid "" +"Enable to display latest posts on the presentation page, below the columns. " +"Sticky posts are always displayed and not counted." msgstr "" -#: admin/settings.php:280 +#: admin/settings.php:287 msgid "Slider Dimensions:" msgstr "" -#: admin/settings.php:281 +#: admin/settings.php:288 msgid "width" msgstr "" -#: admin/settings.php:282 +#: admin/settings.php:289 msgid "height" msgstr "" -#: admin/settings.php:283 -msgid "The dimensions of your slider. Make sure your images are of the same size." +#: admin/settings.php:290 +msgid "" +"The dimensions of your slider. Make sure your images are of the same size." msgstr "" -#: admin/settings.php:285 +#: admin/settings.php:292 msgid "Animation:" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "Random" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "Fold" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "Fade" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SlideInRight" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SlideInLeft" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SliceDown" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SliceDownLeft" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SliceUp" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SliceUpLeft" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SliceUpDown" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "SliceUpDownLeft" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "BoxRandom" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "BoxRain" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "BoxRainReverse" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "BoxRainGrow" msgstr "" -#: admin/settings.php:287 +#: admin/settings.php:294 msgid "BoxRainGrowReverse" msgstr "" -#: admin/settings.php:295 +#: admin/settings.php:302 msgid "The transition effect your slider will have." msgstr "" -#: admin/settings.php:297 +#: admin/settings.php:304 msgid "Border Settings:" msgstr "" -#: admin/settings.php:298 +#: admin/settings.php:305 msgid "Width" msgstr "" -#: admin/settings.php:299 +#: admin/settings.php:306 msgid "Color" msgstr "" -#: admin/settings.php:301 +#: admin/settings.php:308 msgid "The width and color of the slider's border." msgstr "" -#: admin/settings.php:303 +#: admin/settings.php:310 msgid "Animation Time:" msgstr "" -#: admin/settings.php:304 -#: admin/settings.php:308 +#: admin/settings.php:311 admin/settings.php:315 msgid "milliseconds" msgstr "" -#: admin/settings.php:305 +#: admin/settings.php:312 msgid "The time in which the transition animation will take place." msgstr "" -#: admin/settings.php:307 +#: admin/settings.php:314 msgid "Pause Time:" msgstr "" -#: admin/settings.php:309 +#: admin/settings.php:316 msgid "The time in which a slide will be still and visible." msgstr "" -#: admin/settings.php:312 +#: admin/settings.php:319 msgid "Slider navigation:" msgstr "" -#: admin/settings.php:314 +#: admin/settings.php:321 msgid "Numbers" msgstr "" -#: admin/settings.php:314 +#: admin/settings.php:321 msgid "Bullets" msgstr "" -#: admin/settings.php:314 -#: admin/settings.php:1451 +#: admin/settings.php:321 admin/settings.php:1458 msgid "None" msgstr "" -#: admin/settings.php:322 +#: admin/settings.php:329 msgid "Your slider navigation type. Shown under the slider." msgstr "" -#: admin/settings.php:324 +#: admin/settings.php:331 msgid "Slider arrows:" msgstr "" -#: admin/settings.php:326 +#: admin/settings.php:333 msgid "Always Visible" msgstr "" -#: admin/settings.php:326 +#: admin/settings.php:333 msgid "Visible on Hover" msgstr "" -#: admin/settings.php:326 +#: admin/settings.php:333 msgid "Hidden" msgstr "" -#: admin/settings.php:334 +#: admin/settings.php:341 msgid "The Left and Right arrows on your slider" msgstr "" -#: admin/settings.php:375 -#: admin/settings.php:444 +#: admin/settings.php:382 admin/settings.php:451 msgid "Select Category" msgstr "" -#: admin/settings.php:402 +#: admin/settings.php:409 msgid "Custom Slides" msgstr "" -#: admin/settings.php:402 +#: admin/settings.php:409 msgid "Latest Posts" msgstr "" -#: admin/settings.php:402 +#: admin/settings.php:409 msgid "Random Posts" msgstr "" -#: admin/settings.php:402 +#: admin/settings.php:409 msgid "Sticky Posts" msgstr "" -#: admin/settings.php:402 +#: admin/settings.php:409 msgid "Latest Posts from Category" msgstr "" -#: admin/settings.php:402 +#: admin/settings.php:409 msgid "Random Posts from Category" msgstr "" -#: admin/settings.php:402 +#: admin/settings.php:409 msgid "Specific Posts" msgstr "" -#: admin/settings.php:403 +#: admin/settings.php:410 msgid "Select the content you want to load in your slides:" msgstr "" -#: admin/settings.php:411 -msgid "Your slides' content. Only the image is required, all other fields are optional. Only the slides with an image selected will become acitve and visible in the live slider." +#: admin/settings.php:418 +msgid "" +"Your slides' content. Only the image is required, all other fields are " +"optional. Only the slides with an image selected will become acitve and " +"visible in the live slider." msgstr "" -#: admin/settings.php:416 +#: admin/settings.php:423 msgid "Latest posts will be loaded into the slider." msgstr "" -#: admin/settings.php:420 +#: admin/settings.php:427 msgid "Random posts will be loaded into the slider." msgstr "" -#: admin/settings.php:424 +#: admin/settings.php:431 msgid "Latest posts from the category you choose will be loaded in the slider." msgstr "" -#: admin/settings.php:429 -msgid "Random posts from the category you choose will be loaded into the slider." +#: admin/settings.php:436 +msgid "" +"Random posts from the category you choose will be loaded into the slider." msgstr "" -#: admin/settings.php:433 +#: admin/settings.php:440 msgid "Only sticky posts will be loaded into the slider." msgstr "" -#: admin/settings.php:437 +#: admin/settings.php:444 msgid "List the post IDs you want to display (separated by a comma): " msgstr "" -#: admin/settings.php:442 +#: admin/settings.php:449 msgid "
Choose the cateogry: " msgstr "" -#: admin/settings.php:459 +#: admin/settings.php:466 msgid "Number of posts to show:" msgstr "" -#: admin/settings.php:466 +#: admin/settings.php:473 msgid "Slide 1" msgstr "" -#: admin/settings.php:470 -#: admin/settings.php:485 -#: admin/settings.php:500 -#: admin/settings.php:515 -#: admin/settings.php:530 -#: admin/settings.php:572 -#: admin/settings.php:587 -#: admin/settings.php:602 -#: admin/settings.php:617 -#: admin/settings.php:766 -#: admin/settings.php:789 +#: admin/settings.php:475 admin/settings.php:490 admin/settings.php:505 +#: admin/settings.php:520 admin/settings.php:535 admin/settings.php:577 +#: admin/settings.php:592 admin/settings.php:607 admin/settings.php:622 +#: content-image.php:19 +msgid "Image" +msgstr "" + +#: admin/settings.php:477 admin/settings.php:492 admin/settings.php:507 +#: admin/settings.php:522 admin/settings.php:537 admin/settings.php:579 +#: admin/settings.php:594 admin/settings.php:609 admin/settings.php:624 +#: admin/settings.php:773 admin/settings.php:796 msgid "Select / Upload Image" msgstr "" -#: admin/settings.php:471 -#: admin/settings.php:486 -#: admin/settings.php:501 -#: admin/settings.php:516 -#: admin/settings.php:531 -#: admin/settings.php:573 -#: admin/settings.php:588 -#: admin/settings.php:618 +#: admin/settings.php:478 admin/settings.php:493 admin/settings.php:508 +#: admin/settings.php:523 admin/settings.php:538 admin/settings.php:580 +#: admin/settings.php:595 admin/settings.php:625 msgid "Title" msgstr "" -#: admin/settings.php:473 -#: admin/settings.php:488 -#: admin/settings.php:503 -#: admin/settings.php:518 -#: admin/settings.php:533 -#: admin/settings.php:575 -#: admin/settings.php:590 -#: admin/settings.php:605 -#: admin/settings.php:620 +#: admin/settings.php:480 admin/settings.php:495 admin/settings.php:510 +#: admin/settings.php:525 admin/settings.php:540 admin/settings.php:582 +#: admin/settings.php:597 admin/settings.php:612 admin/settings.php:627 msgid "Text" msgstr "" -#: admin/settings.php:481 +#: admin/settings.php:482 admin/settings.php:497 admin/settings.php:512 +#: admin/settings.php:527 admin/settings.php:542 admin/settings.php:584 +#: admin/settings.php:599 admin/settings.php:614 admin/settings.php:629 +#: content-link.php:20 +msgid "Link" +msgstr "" + +#: admin/settings.php:488 msgid "Slide 2" msgstr "" -#: admin/settings.php:496 +#: admin/settings.php:503 msgid "Slide 3" msgstr "" -#: admin/settings.php:511 +#: admin/settings.php:518 msgid "Slide 4" msgstr "" -#: admin/settings.php:526 +#: admin/settings.php:533 msgid "Slide 5" msgstr "" -#: admin/settings.php:548 +#: admin/settings.php:555 msgid "Number of columns:" msgstr "" -#: admin/settings.php:558 +#: admin/settings.php:565 msgid "Image Height:" msgstr "" -#: admin/settings.php:561 +#: admin/settings.php:568 msgid "Read more text:" msgstr "" -#: admin/settings.php:564 -msgid "The linked text that appears at the bottom of all the columns. You can delete all text inside if you don't want it." +#: admin/settings.php:571 +msgid "" +"The linked text that appears at the bottom of all the columns. You can " +"delete all text inside if you don't want it." msgstr "" -#: admin/settings.php:568 +#: admin/settings.php:575 msgid "1st Column" msgstr "" -#: admin/settings.php:583 +#: admin/settings.php:590 msgid "2nd Column" msgstr "" -#: admin/settings.php:598 +#: admin/settings.php:605 msgid "3rd Column" msgstr "" -#: admin/settings.php:613 +#: admin/settings.php:620 msgid "4th Column" msgstr "" -#: admin/settings.php:635 +#: admin/settings.php:642 msgid "Extra Text" msgstr "" -#: admin/settings.php:637 +#: admin/settings.php:644 msgid "" -"More text for your front page. The top title is above the slider, the second title between the slider and the columns and 2 more rows of text under the columns.\n" +"More text for your front page. The top title is above the slider, the second " +"title between the slider and the columns and 2 more rows of text under the " +"columns.\n" "\t\t It's all optional so leave any input field empty if it's not required. " msgstr "" -#: admin/settings.php:640 +#: admin/settings.php:647 msgid "Top Title" msgstr "" -#: admin/settings.php:641 +#: admin/settings.php:648 msgid "Second Title" msgstr "" -#: admin/settings.php:644 +#: admin/settings.php:651 msgid "Title color" msgstr "" -#: admin/settings.php:648 +#: admin/settings.php:655 msgid "Bottom Text 1" msgstr "" -#: admin/settings.php:650 +#: admin/settings.php:657 msgid "Bottom Text 2" msgstr "" -#: admin/settings.php:658 +#: admin/settings.php:665 msgid "Hide areas" msgstr "" -#: admin/settings.php:660 +#: admin/settings.php:667 msgid "Choose the areas to hide on the first page." msgstr "" -#: admin/settings.php:672 +#: admin/settings.php:679 msgid "Hide the header area (image or background color)." msgstr "" -#: admin/settings.php:676 +#: admin/settings.php:683 msgid "Hide the main menu (the top navigation tabs)." msgstr "" -#: admin/settings.php:680 +#: admin/settings.php:687 msgid "Hide the footer widgets. " msgstr "" -#: admin/settings.php:684 +#: admin/settings.php:691 msgid "Hide the footer (copyright area)." msgstr "" -#: admin/settings.php:688 +#: admin/settings.php:695 msgid "Hide the white color. Only the background color remains." msgstr "" -#: admin/settings.php:708 -msgid "Select the header's height. After saving the settings make sure you reupload a new header image (if you're using one). The header's width will be = " +#: admin/settings.php:715 +msgid "" +"Select the header's height. After saving the settings make sure you reupload " +"a new header image (if you're using one). The header's width will be = " msgstr "" -#: admin/settings.php:715 +#: admin/settings.php:722 msgid "Define header image" msgstr "" -#: admin/settings.php:716 -msgid "The header image should not be used to display logos.
Enable ratio preservation to force the header image aspect ratio. Keep in mind that short images will become very small on mobile devices." +#: admin/settings.php:723 +msgid "" +"The header image should not be used to display logos.
Enable ratio " +"preservation to force the header image aspect ratio. Keep in mind that short " +"images will become very small on mobile devices." msgstr "" -#: admin/settings.php:739 +#: admin/settings.php:746 msgid "Enable or disable the round corners for the main menu items." msgstr "" -#: admin/settings.php:747 +#: admin/settings.php:754 msgid "Site Title and Description" msgstr "" -#: admin/settings.php:747 +#: admin/settings.php:754 msgid "Custom Logo" msgstr "" -#: admin/settings.php:747 +#: admin/settings.php:754 msgid "Clickable header image" msgstr "" -#: admin/settings.php:747 +#: admin/settings.php:754 msgid "Empty" msgstr "" -#: admin/settings.php:755 +#: admin/settings.php:762 msgid "Choose what to display inside your header area." msgstr "" -#: admin/settings.php:765 -msgid "Custom Logo upload. The logo will appear over the heder image if you have used one." +#: admin/settings.php:772 +msgid "" +"Custom Logo upload. The logo will appear over the heder image if you have " +"used one." msgstr "" -#: admin/settings.php:774 +#: admin/settings.php:781 msgid "top" msgstr "" -#: admin/settings.php:775 +#: admin/settings.php:782 msgid "left" msgstr "" -#: admin/settings.php:778 -msgid "Select the top spacing for the header. Use it to better position your site title and description or custom logo inside the header. " +#: admin/settings.php:785 +msgid "" +"Select the top spacing for the header. Use it to better position your site " +"title and description or custom logo inside the header. " +msgstr "" + +#: admin/settings.php:795 +msgid "" +"Limitations: It has to be an image. It should be max 64x64 pixels in " +"dimensions. Recommended file extensions .ico and .png.
Note that " +"some browsers do not display the changed favicon instantly." msgstr "" -#: admin/settings.php:788 -msgid "Limitations: It has to be an image. It should be max 64x64 pixels in dimensions. Recommended file extensions .ico and .png.
Note that some browsers do not display the changed favicon instantly." +#: admin/settings.php:818 +msgid "" +"Select the font size you'll use in your blog. Pages, posts and comments will " +"be affected. Buttons, Headers and Side menus will remain the same." msgstr "" -#: admin/settings.php:811 -msgid "Select the font size you'll use in your blog. Pages, posts and comments will be affected. Buttons, Headers and Side menus will remain the same." +#: admin/settings.php:862 +msgid "" +"Select the font family you'll use in your blog. All content text will be " +"affected (including menu buttons). " msgstr "" -#: admin/settings.php:855 -msgid "Select the font family you'll use in your blog. All content text will be affected (including menu buttons). " +#: admin/settings.php:864 admin/settings.php:914 admin/settings.php:965 +#: admin/settings.php:1017 +msgid "" +"Or insert your Google Font below. Please only isert the name of the font.
Ex: Marko One. Go to google fonts for some font inspiration." msgstr "" -#: admin/settings.php:857 -#: admin/settings.php:907 -#: admin/settings.php:958 -#: admin/settings.php:1010 -msgid "Or insert your Google Font below. Please only isert the name of the font.
Ex: Marko One. Go to google fonts for some font inspiration." +#: admin/settings.php:911 +msgid "" +"Select the font family you want for your titles. It will affect post titles " +"and page titles. Leave 'Default' and the general font you selected will be " +"used." msgstr "" -#: admin/settings.php:904 -msgid "Select the font family you want for your titles. It will affect post titles and page titles. Leave 'Default' and the general font you selected will be used." +#: admin/settings.php:963 +msgid "" +"Select the font family you want your sidebar(s) to have. Text in sidebars " +"will be affected, including any widgets. Leave 'Default' and the general " +"font you selected will be used." msgstr "" -#: admin/settings.php:956 -msgid "Select the font family you want your sidebar(s) to have. Text in sidebars will be affected, including any widgets. Leave 'Default' and the general font you selected will be used." +#: admin/settings.php:1014 +msgid "" +"Select the font family you want your headings to have (h1 - h6 tags will be " +"affected). Leave 'Default' and the general font you selected will be used." msgstr "" -#: admin/settings.php:1007 -msgid "Select the font family you want your headings to have (h1 - h6 tags will be affected). Leave 'Default' and the general font you selected will be used." +#: admin/settings.php:1026 admin/settings.php:1041 admin/settings.php:1056 +#: admin/settings.php:1116 admin/settings.php:1131 admin/settings.php:1146 +msgid "Default" msgstr "" -#: admin/settings.php:1019 #: admin/settings.php:1034 +msgid "" +"Post Header Font size. Leave 'Default' for normal settings (size value will " +"be as set in the CSS)." +msgstr "" + #: admin/settings.php:1049 +msgid "" +"Sidebar Font size. Leave 'Default' for normal settings (size value will be " +"as set in the CSS)." +msgstr "" + +#: admin/settings.php:1056 admin/settings.php:1380 admin/settings.php:1891 +msgid "Left" +msgstr "" + +#: admin/settings.php:1056 admin/settings.php:1380 admin/settings.php:1891 +msgid "Right" +msgstr "" + +#: admin/settings.php:1056 +msgid "Justify" +msgstr "" + +#: admin/settings.php:1056 admin/settings.php:1380 admin/settings.php:1891 +msgid "Center" +msgstr "" + +#: admin/settings.php:1064 +msgid "" +"This overwrites the text alignment in posts and pages. Leave 'Default' for " +"normal settings (alignment will remain as declared in posts, comments etc.)." +msgstr "" + +#: admin/settings.php:1078 +msgid "Choose the spacing between paragraphs." +msgstr "" + +#: admin/settings.php:1093 +msgid "Choose the indent for your paragraphs." +msgstr "" + #: admin/settings.php:1109 +msgid "Disable the default header and title indent (left margin)." +msgstr "" + #: admin/settings.php:1124 +msgid "" +"Text line height. The height between 2 rows of text. Leave 'Default' for " +"normal settings (size value will be as set in the CSS)." +msgstr "" + #: admin/settings.php:1139 -msgid "Default" +msgid "" +"The space between words. Leave 'Default' for normal settings (size " +"value will be as set in the CSS)." +msgstr "" + +#: admin/settings.php:1154 +msgid "" +"The space between letters. Leave 'Default' for normal settings (size " +"value will be as set in the CSS)." +msgstr "" + +#: admin/settings.php:1171 +msgid "Disable the default text shadow on headers and titles." +msgstr "" + +#: admin/settings.php:1179 +msgid "Define background image" +msgstr "" + +#: admin/settings.php:1188 +msgid "Background color (Default value is 444444)." +msgstr "" + +#: admin/settings.php:1196 +msgid "" +"Header background color (Default value is 333333). You can delete all inside " +"text for no background color." +msgstr "" + +#: admin/settings.php:1203 +msgid "" +"Content background color (Default value is FFFFFF). Works best with really " +"light colors." +msgstr "" + +#: admin/settings.php:1210 +msgid "" +"Main menu background color (Default value is FAFAFA). Should be the same " +"color as the content bg or something just as light." +msgstr "" + +#: admin/settings.php:1217 +msgid "" +"First sidebar background color (Default is no color for a transparent " +"sidebar)." +msgstr "" + +#: admin/settings.php:1224 +msgid "" +"Second sidebar background color (Default is no color for a transparent " +"sidebar)." +msgstr "" + +#: admin/settings.php:1232 +msgid "Footer widget-area background color. (Default value is 171717)." +msgstr "" + +#: admin/settings.php:1240 +msgid "Footer background color (Default value is 222222)." +msgstr "" + +#: admin/settings.php:1248 +msgid "Your blog's title color (Default value is 0D85CC)." +msgstr "" + +#: admin/settings.php:1256 +msgid "Your blog's description color(Default value is 222222)." +msgstr "" + +#: admin/settings.php:1264 +msgid "Content Text Color (Default value is 333333)." +msgstr "" + +#: admin/settings.php:1272 +msgid "Links color (Default value is 0D85CC)." +msgstr "" + +#: admin/settings.php:1280 +msgid "Links color on mouse over (Default value is 333333)." +msgstr "" + +#: admin/settings.php:1288 +msgid "Post Header Text Color (Default value is 333333)." +msgstr "" + +#: admin/settings.php:1296 +msgid "Post Header Text Color on Mouse over (Default value is 000000)." +msgstr "" + +#: admin/settings.php:1304 +msgid "Sidebar Header Background color (Default value is 444444)." +msgstr "" + +#: admin/settings.php:1313 +msgid "Sidebar Header Text Color(Default value is 2EA5FD)." +msgstr "" + +#: admin/settings.php:1321 +msgid "Footer Widget Text Color (Default value is 0D85CC)." +msgstr "" + +#: admin/settings.php:1329 +msgid "Footer Widget Link Color (Default value is 666666)." +msgstr "" + +#: admin/settings.php:1337 +msgid "Footer Widget Link Color on Mouse Over (Default value is 888888)." +msgstr "" + +#: admin/settings.php:1359 +msgid "" +"Show breadcrumbs at the top of the content area. Breadcrumbs are a form of " +"navigation that keeps track of your location withtin the site." +msgstr "" + +#: admin/settings.php:1374 +msgid "" +"Show numbered pagination. Where there is more than one page, instead of the " +"bottom Older Posts and Newer posts links you have a numbered " +"pagination. " +msgstr "" + +#: admin/settings.php:1388 +msgid "" +"Select the desired main menu items alignment. Center option is only valid " +"for single line menus." +msgstr "" + +#: admin/settings.php:1395 admin/settings.php:1458 +msgid "White" +msgstr "" + +#: admin/settings.php:1395 +msgid "Light" +msgstr "" + +#: admin/settings.php:1395 +msgid "Light Gray" +msgstr "" + +#: admin/settings.php:1395 admin/settings.php:1458 +msgid "Gray" +msgstr "" + +#: admin/settings.php:1395 +msgid "Dark Gray" +msgstr "" + +#: admin/settings.php:1395 +msgid "Black" +msgstr "" + +#: admin/settings.php:1403 +msgid "" +"This setting changes the look of your captions. Images that are not inserted " +"through captions will not be affected." +msgstr "" + +#: admin/settings.php:1419 +msgid "The border around your inserted images. " +msgstr "" + +#: admin/settings.php:1434 +msgid "The image on top of your captions. " +msgstr "" + +#: admin/settings.php:1449 +msgid "The sidebar list bullets. " +msgstr "" + +#: admin/settings.php:1466 +msgid "" +"The background for your post-metas area (under your post tiltes). Gray by " +"default." +msgstr "" + +#: admin/settings.php:1474 admin/settings.php:1490 admin/settings.php:1507 +#: admin/settings.php:1522 admin/settings.php:1552 admin/settings.php:1567 +#: admin/settings.php:1583 admin/settings.php:1619 admin/settings.php:1634 +#: admin/settings.php:1649 admin/settings.php:1664 admin/settings.php:1679 +#: admin/settings.php:1694 admin/settings.php:1709 admin/settings.php:1724 +msgid "Show" +msgstr "" + +#: admin/settings.php:1474 admin/settings.php:1490 admin/settings.php:1507 +#: admin/settings.php:1522 admin/settings.php:1552 admin/settings.php:1583 +#: admin/settings.php:1619 admin/settings.php:1634 admin/settings.php:1649 +#: admin/settings.php:1664 admin/settings.php:1679 admin/settings.php:1694 +#: admin/settings.php:1709 admin/settings.php:1724 +msgid "Hide" +msgstr "" + +#: admin/settings.php:1482 +msgid "Hide or show a horizontal rule to separate posts." +msgstr "" + +#: admin/settings.php:1498 +msgid "" +"Hide or show bullets next to lists that are in your content area (posts, " +"pages etc.)." +msgstr "" + +#: admin/settings.php:1515 +msgid "Hide or show Page titles on any created pages. " +msgstr "" + +#: admin/settings.php:1530 +msgid "Hide or show Page titles on Category Pages. " +msgstr "" + +#: admin/settings.php:1545 +msgid "Hide table borders and background color." +msgstr "" + +#: admin/settings.php:1560 +msgid "" +"Hide the explanatory text under the comments form. (starts with You may " +"use these HTML tags and attributes:...)." +msgstr "" + +#: admin/settings.php:1567 +msgid "Hide in posts" +msgstr "" + +#: admin/settings.php:1567 +msgid "Hide in pages" +msgstr "" + +#: admin/settings.php:1567 +msgid "Hide everywhere" +msgstr "" + +#: admin/settings.php:1575 +msgid "" +"Hide the Comments are closed text that by default shows up on pages " +"or posts with the comments disabled." +msgstr "" + +#: admin/settings.php:1591 +msgid "" +"Hide the Comments off text next to posts that have comments disabled." +msgstr "" + +#: admin/settings.php:1607 +msgid "" +"Enable the Back to Top button. The button appears after scrolling the page " +"down." +msgstr "" + +#: admin/settings.php:1627 +msgid "" +"Hide or show the Leave a comment or x Comments next to posts or post excerpts." +msgstr "" + +#: admin/settings.php:1642 +msgid "Hide or show the post date." +msgstr "" + +#: admin/settings.php:1657 +msgid "" +"Show the post time with the date. Time will not be visible if the Post Date " +"is hidden." +msgstr "" + +#: admin/settings.php:1672 +msgid "Hide or show the post author." +msgstr "" + +#: admin/settings.php:1687 +msgid "Hide the post category." +msgstr "" + +#: admin/settings.php:1702 +msgid "Hide the 'Bookmark permalink'." +msgstr "" + +#: admin/settings.php:1717 +msgid "Hide the meta bar. All meta info in it will be hidden." +msgstr "" + +#: admin/settings.php:1732 +msgid "Hide the post tags." +msgstr "" + +#: admin/settings.php:1745 admin/settings.php:1760 admin/settings.php:1776 +msgid "Excerpt" +msgstr "" + +#: admin/settings.php:1745 admin/settings.php:1760 admin/settings.php:1776 +msgid "Full Post" +msgstr "" + +#: admin/settings.php:1753 +msgid "" +"Excerpts on the main page. Only standard posts will be affected. All other " +"post formats (aside, image, chat, quote etc.) have their specific formating." +msgstr "" + +#: admin/settings.php:1768 +msgid "" +"Choose if you want the sticky posts on your home page to be visible in full " +"or just the excerpts. " +msgstr "" + +#: admin/settings.php:1784 +msgid "" +"Excerpts on archive, categroy and search pages. Same as above, only standard " +"posts will be affected." +msgstr "" + +#: admin/settings.php:1792 +msgid "" +"The number of words an excerpt will have. When that number is reached the " +"post will be interrupted by a Continue reading link that\n" +"\t\t\t\t\t\t\twill take the reader to the full post page." +msgstr "" + +#: admin/settings.php:1808 +msgid "" +"Enable the Magazine Layout. This layout applies to pages with posts and " +"shows 2 posts per row." msgstr "" -#: admin/settings.php:1027 -msgid "Post Header Font size. Leave 'Default' for normal settings (size value will be as set in the CSS)." +#: admin/settings.php:1815 +msgid "" +"Replaces the three dots ('[...])' that are appended automatically to " +"excerpts." msgstr "" -#: admin/settings.php:1042 -msgid "Sidebar Font size. Leave 'Default' for normal settings (size value will be as set in the CSS)." +#: admin/settings.php:1822 +msgid "Edit the 'Continue Reading' link added to your post excerpts." msgstr "" -#: admin/settings.php:1049 -#: admin/settings.php:1373 -#: admin/settings.php:1884 -msgid "Left" +#: admin/settings.php:1837 +#, php-format +msgid "" +"By default WordPress excerpts remove all HTML tags (%s and all others) and " +"only clean text is left in the excerpt.\n" +"Enabling this option allows HTML tags to remain in excerpts so all your " +"default formating will be kept.
Just a warning: If HTML tags " +"are enabled, you have to make sure\n" +"they are not left open. So if within your post you have an opened HTML tag " +"but the except ends before that tag closes, the rest of the site will be " +"contained in that HTML tag. -- Leave 'Disable' if unsure --
" msgstr "" -#: admin/settings.php:1049 -#: admin/settings.php:1373 -#: admin/settings.php:1884 -msgid "Right" +#: admin/settings.php:1868 +msgid "" +"Show featured images as thumbnails on posts. The images must be selected for " +"each post in the Featured Image section." msgstr "" -#: admin/settings.php:1049 -msgid "Justify" +#: admin/settings.php:1883 +msgid "" +"Show the first image that you inserted in a post as a thumbnail. If you " +"enable this option, the first image in your post will be used even if you " +"selected a Featured Image in you post." msgstr "" -#: admin/settings.php:1049 -#: admin/settings.php:1373 -#: admin/settings.php:1884 -msgid "Center" +#: admin/settings.php:1899 +msgid "Thumbnail alignment." msgstr "" -#: admin/settings.php:1057 -msgid "This overwrites the text alignment in posts and pages. Leave 'Default' for normal settings (alignment will remain as declared in posts, comments etc.)." +#: admin/settings.php:1916 +msgid "" +"The size you want the thumbnails to have (in pixels). By default imges will " +"be scaled with aspect ratio kept. Choose to crop the images if you want the " +"exact size." msgstr "" -#: admin/settings.php:1071 -msgid "Choose the spacing between paragraphs." +#: admin/settings.php:1932 +msgid "" +"Show featured images on headers. The header will be replaced with a featured " +"image if you selected it as a Featured Image in the post and\n" +"\t\t\t\t\t\t\tand if it is bigger or at least equal to the current header " +"size." msgstr "" -#: admin/settings.php:1086 -msgid "Choose the indent for your paragraphs." +#: admin/settings.php:1948 +msgid "" +"Select your desired Social network from the left dropdown menu and insert " +"your corresponding address in the right input field. (ex: http://www." +"facebook.com/yourname )" msgstr "" -#: admin/settings.php:1102 -msgid "Disable the default header and title indent (left margin)." +#: admin/settings.php:1949 +msgid "You can insert up to 5 different social sites and addresses." msgstr "" -#: admin/settings.php:1117 -msgid "Text line height. The height between 2 rows of text. Leave 'Default' for normal settings (size value will be as set in the CSS)." +#: admin/settings.php:1950 +msgid "There are a total of 27 social networks to choose from. " msgstr "" -#: admin/settings.php:1132 -msgid "The space between words. Leave 'Default' for normal settings (size value will be as set in the CSS)." +#: admin/settings.php:1951 +msgid "You can leave any number of inputs empty. " msgstr "" -#: admin/settings.php:1147 -msgid "The space between letters. Leave 'Default' for normal settings (size value will be as set in the CSS)." +#: admin/settings.php:1952 +msgid "You can choose the same social media any number of times. " msgstr "" -#: admin/settings.php:1164 -msgid "Disable the default text shadow on headers and titles." +#: admin/settings.php:2027 +msgid "Choose the areas where to display the social icons." msgstr "" -#: admin/settings.php:1172 -msgid "Define background image" +#: admin/settings.php:2040 +msgid "" +"Insert custom text or HTML code that will appear last in you footer.
" +"You can use HTML to insert links, images and special characters like © ." msgstr "" -#: admin/settings.php:1181 -msgid "Background color (Default value is 444444)." +#: admin/settings.php:2048 +msgid "" +"Insert your custom CSS here. Any CSS declarations made here will overwrite " +"Mantra's (even the custom options specified right here in the Mantra " +"Settings page).
Your custom CSS will be preserved when updating the " +"theme.
The <style> tags are not needed." msgstr "" -#: admin/settings.php:1189 -msgid "Header background color (Default value is 333333). You can delete all inside text for no background color." +#: admin/settings.php:2055 +msgid "" +"Insert your custom Javascript code here. (Google Analytics and any other " +"forms of Analytic software).
The <script> tags are not needed." msgstr "" -#: admin/settings.php:1196 -msgid "Content background color (Default value is FFFFFF). Works best with really light colors." +#: archive.php:27 +#, php-format +msgid "Daily Archives: %s" msgstr "" -#: admin/settings.php:1203 -msgid "Main menu background color (Default value is FAFAFA). Should be the same color as the content bg or something just as light." +#: archive.php:29 +#, php-format +msgid "Monthly Archives: %s" msgstr "" -#: admin/settings.php:1210 -msgid "First sidebar background color (Default is no color for a transparent sidebar)." +#: archive.php:29 +msgid "F Y" msgstr "" -#: admin/settings.php:1217 -msgid "Second sidebar background color (Default is no color for a transparent sidebar)." +#: archive.php:31 +#, php-format +msgid "Yearly Archives: %s" msgstr "" -#: admin/settings.php:1225 -msgid "Footer widget-area background color. (Default value is 171717)." +#: archive.php:31 +msgid "Y" msgstr "" -#: admin/settings.php:1233 -msgid "Footer background color (Default value is 222222)." +#: archive.php:33 +msgid "Blog Archives" msgstr "" -#: admin/settings.php:1241 -msgid "Your blog's title color (Default value is 0D85CC)." +#: archive.php:59 author.php:75 category.php:51 content-frontpage.php:26 +#: index.php:41 search.php:41 tag.php:52 template-blog.php:36 +msgid "Nothing Found" msgstr "" -#: admin/settings.php:1249 -msgid "Your blog's description color(Default value is 222222)." +#: archive.php:63 author.php:79 category.php:55 content-frontpage.php:30 +#: index.php:45 tag.php:56 template-blog.php:40 +msgid "" +"Apologies, but no results were found for the requested archive. Perhaps " +"searching will help find a related post." msgstr "" -#: admin/settings.php:1257 -msgid "Content Text Color (Default value is 333333)." +#: attachment.php:18 +#, php-format +msgid "Return to %s" msgstr "" -#: admin/settings.php:1265 -msgid "Links color (Default value is 0D85CC)." +#: attachment.php:29 +msgid "By" msgstr "" -#: admin/settings.php:1273 -msgid "Links color on mouse over (Default value is 333333)." +#: attachment.php:40 +msgid "Published" msgstr "" -#: admin/settings.php:1281 -msgid "Post Header Text Color (Default value is 333333)." +#: attachment.php:50 +#, php-format +msgid "Full size is %s pixels" msgstr "" -#: admin/settings.php:1289 -msgid "Post Header Text Color on Mouse over (Default value is 000000)." +#: attachment.php:53 +msgid "Link to full-size image" msgstr "" -#: admin/settings.php:1297 -msgid "Sidebar Header Background color (Default value is 444444)." +#: attachment.php:60 attachment.php:107 content-aside.php:48 +#: content-chat.php:49 content-gallery.php:75 content-image.php:42 +#: content-link.php:49 content-page.php:22 content-quote.php:46 +#: content-status.php:48 content.php:76 single.php:55 +#: template-onecolumn.php:28 template-page-with-intro.php:18 +msgid "Edit" msgstr "" -#: admin/settings.php:1306 -msgid "Sidebar Header Text Color(Default value is 2EA5FD)." +#: attachment.php:100 +msgid "Continue reading" msgstr "" -#: admin/settings.php:1314 -msgid "Footer Widget Text Color (Default value is 0D85CC)." +#: attachment.php:101 content-aside.php:39 content-chat.php:38 +#: content-gallery.php:65 content-image.php:33 content-link.php:38 +#: content-page.php:21 content-quote.php:36 content-status.php:39 +#: content.php:49 content.php:65 single.php:33 template-onecolumn.php:27 +#: template-page-with-intro.php:17 +msgid "Pages:" msgstr "" -#: admin/settings.php:1322 -msgid "Footer Widget Link Color (Default value is 666666)." +#: author.php:29 +#, php-format +msgid "Author Archives: %s" msgstr "" -#: admin/settings.php:1330 -msgid "Footer Widget Link Color on Mouse Over (Default value is 888888)." +#: author.php:50 +#, php-format +msgid "About %s" msgstr "" -#: admin/settings.php:1352 -msgid "Show breadcrumbs at the top of the content area. Breadcrumbs are a form of navigation that keeps track of your location withtin the site." +#: category.php:20 +#, php-format +msgid "Category Archives: %s" msgstr "" -#: admin/settings.php:1367 -msgid "Show numbered pagination. Where there is more than one page, instead of the bottom Older Posts and Newer posts links you have a numbered pagination. " +#: comments.php:18 +msgid "" +"This post is password protected. Enter the password to view any comments." msgstr "" -#: admin/settings.php:1381 -msgid "Select the desired main menu items alignment. Center option is only valid for single line menus." +#: content-aside.php:20 +msgid "Aside" msgstr "" -#: admin/settings.php:1388 -#: admin/settings.php:1451 -msgid "White" +#: content-aside.php:38 content-chat.php:37 content-image.php:32 +#: content-link.php:37 content-quote.php:35 content-status.php:38 +msgid "Continue reading " msgstr "" -#: admin/settings.php:1388 -msgid "Light" +#: content-aside.php:46 content-chat.php:45 content-gallery.php:72 +#: content-image.php:39 content-link.php:45 content-quote.php:43 +#: content-status.php:46 content.php:74 includes/theme-loop.php:206 +msgid "Tagged" msgstr "" -#: admin/settings.php:1388 -msgid "Light Gray" +#: content-chat.php:20 +msgid "Chat" msgstr "" -#: admin/settings.php:1388 -#: admin/settings.php:1451 -msgid "Gray" +#: content-gallery.php:23 +msgid "Gallery" msgstr "" -#: admin/settings.php:1388 -msgid "Dark Gray" +#: content-page.php:27 includes/theme-comments.php:136 +msgid "Comments are closed." msgstr "" -#: admin/settings.php:1388 -msgid "Black" +#: content-quote.php:18 +msgid "Quote" msgstr "" -#: admin/settings.php:1396 -msgid "This setting changes the look of your captions. Images that are not inserted through captions will not be affected." +#: content-status.php:30 includes/tgm.php:2495 +msgid "Status" msgstr "" -#: admin/settings.php:1412 -msgid "The border around your inserted images. " +#: includes/tgm.php:29 +msgid "Recommended Plugins" msgstr "" -#: admin/settings.php:1427 -msgid "The image on top of your captions. " +#: includes/tgm.php:30 +msgid " Plugins" msgstr "" -#: admin/settings.php:1442 -msgid "The sidebar list bullets. " +#: includes/tgm.php:31 includes/tgm.php:390 +#, php-format +msgid "Installing Plugin: %s" msgstr "" -#: admin/settings.php:1459 -msgid "The background for your post-metas area (under your post tiltes). Gray by default." +#: includes/tgm.php:32 includes/tgm.php:391 +msgid "Something went wrong with the plugin API." msgstr "" -#: admin/settings.php:1467 -#: admin/settings.php:1483 -#: admin/settings.php:1500 -#: admin/settings.php:1515 -#: admin/settings.php:1545 -#: admin/settings.php:1560 -#: admin/settings.php:1576 -#: admin/settings.php:1612 -#: admin/settings.php:1627 -#: admin/settings.php:1642 -#: admin/settings.php:1657 -#: admin/settings.php:1672 -#: admin/settings.php:1687 -#: admin/settings.php:1702 -#: admin/settings.php:1717 -msgid "Show" +#: includes/tgm.php:43 includes/tgm.php:452 +msgid "Return to Required Plugins Installer" msgstr "" -#: admin/settings.php:1467 -#: admin/settings.php:1483 -#: admin/settings.php:1500 -#: admin/settings.php:1515 -#: admin/settings.php:1545 -#: admin/settings.php:1576 -#: admin/settings.php:1612 -#: admin/settings.php:1627 -#: admin/settings.php:1642 -#: admin/settings.php:1657 -#: admin/settings.php:1672 -#: admin/settings.php:1687 -#: admin/settings.php:1702 -#: admin/settings.php:1717 -msgid "Hide" +#: includes/tgm.php:44 includes/tgm.php:454 includes/tgm.php:3081 +msgid "Plugin activated successfully." msgstr "" -#: admin/settings.php:1475 -msgid "Hide or show a horizontal rule to separate posts." +#: includes/tgm.php:45 +#, php-format +msgid "All plugins installed and activated successfully. %s" msgstr "" -#: admin/settings.php:1491 -msgid "Hide or show bullets next to lists that are in your content area (posts, pages etc.)." +#: includes/tgm.php:388 +msgid "Install Required Plugins" msgstr "" -#: admin/settings.php:1508 -msgid "Hide or show Page titles on any created pages. " +#: includes/tgm.php:389 +msgid "Install Plugins" msgstr "" -#: admin/settings.php:1523 -msgid "Hide or show Page titles on Category Pages. " +#: includes/tgm.php:453 +msgid "Return to the dashboard" msgstr "" -#: admin/settings.php:1538 -msgid "Hide table borders and background color." +#: includes/tgm.php:455 +msgid "The following plugin was activated successfully:" msgstr "" -#: admin/settings.php:1553 -msgid "Hide the explanatory text under the comments form. (starts with You may use these HTML tags and attributes:...)." +#: includes/tgm.php:456 +#, php-format +msgid "No action taken. Plugin %1$s was already active." msgstr "" -#: admin/settings.php:1560 -msgid "Hide in posts" +#: includes/tgm.php:457 +#, php-format +msgid "" +"Plugin not activated. A higher version of %s is needed for this theme. " +"Please update the plugin." msgstr "" -#: admin/settings.php:1560 -msgid "Hide in pages" +#: includes/tgm.php:458 +#, php-format +msgid "All plugins installed and activated successfully. %1$s" msgstr "" -#: admin/settings.php:1560 -msgid "Hide everywhere" +#: includes/tgm.php:459 +msgid "Dismiss this notice" msgstr "" -#: admin/settings.php:1568 -msgid "Hide the Comments are closed text that by default shows up on pages or posts with the comments disabled." +#: includes/tgm.php:460 +msgid "Please contact the administrator of this site for help." msgstr "" -#: admin/settings.php:1584 -msgid "Hide the Comments off text next to posts that have comments disabled." +#: includes/tgm.php:1933 +#, php-format +msgid "TGMPA v%s" msgstr "" -#: admin/settings.php:1600 -msgid "Enable the Back to Top button. The button appears after scrolling the page down." +#: includes/tgm.php:2219 +msgid "Required" msgstr "" -#: admin/settings.php:1620 -msgid "Hide or show the Leave a comment or x Comments next to posts or post excerpts." +#: includes/tgm.php:2222 +msgid "Recommended" msgstr "" -#: admin/settings.php:1635 -msgid "Hide or show the post date." +#: includes/tgm.php:2238 +msgid "WordPress Repository" msgstr "" -#: admin/settings.php:1650 -msgid "Show the post time with the date. Time will not be visible if the Post Date is hidden." +#: includes/tgm.php:2241 +msgid "External Source" msgstr "" -#: admin/settings.php:1665 -msgid "Hide or show the post author." +#: includes/tgm.php:2244 +msgid "Pre-Packaged" msgstr "" -#: admin/settings.php:1680 -msgid "Hide the post category." +#: includes/tgm.php:2261 +msgid "Not Installed" msgstr "" -#: admin/settings.php:1695 -msgid "Hide the 'Bookmark permalink'." +#: includes/tgm.php:2265 +msgid "Installed But Not Activated" msgstr "" -#: admin/settings.php:1710 -msgid "Hide the meta bar. All meta info in it will be hidden." +#: includes/tgm.php:2267 +msgid "Active" msgstr "" -#: admin/settings.php:1725 -msgid "Hide the post tags." +#: includes/tgm.php:2273 +msgid "Required Update not Available" msgstr "" -#: admin/settings.php:1738 -#: admin/settings.php:1753 -#: admin/settings.php:1769 -msgid "Excerpt" +#: includes/tgm.php:2276 +msgid "Requires Update" msgstr "" -#: admin/settings.php:1738 -#: admin/settings.php:1753 -#: admin/settings.php:1769 -msgid "Full Post" +#: includes/tgm.php:2279 +msgid "Update recommended" msgstr "" -#: admin/settings.php:1746 -msgid "Excerpts on the main page. Only standard posts will be affected. All other post formats (aside, image, chat, quote etc.) have their specific formating." +#: includes/tgm.php:2287 +#, php-format +msgid "%1$s, %2$s" msgstr "" -#: admin/settings.php:1761 -msgid "Choose if you want the sticky posts on your home page to be visible in full or just the excerpts. " +#: includes/tgm.php:2423 +msgid "unknown" msgstr "" -#: admin/settings.php:1777 -msgid "Excerpts on archive, categroy and search pages. Same as above, only standard posts will be affected." +#: includes/tgm.php:2431 +msgid "Installed version:" msgstr "" -#: admin/settings.php:1785 -msgid "" -"The number of words an excerpt will have. When that number is reached the post will be interrupted by a Continue reading link that\n" -"\t\t\t\t\t\t\twill take the reader to the full post page." +#: includes/tgm.php:2439 +msgid "Minimum required version:" msgstr "" -#: admin/settings.php:1801 -msgid "Enable the Magazine Layout. This layout applies to pages with posts and shows 2 posts per row." +#: includes/tgm.php:2451 +msgid "Available version:" msgstr "" -#: admin/settings.php:1808 -msgid "Replaces the three dots ('[...])' that are appended automatically to excerpts." +#: includes/tgm.php:2474 +#, php-format +msgid "" +"No plugins to install, update or activate. Return to the " +"Dashboard" msgstr "" -#: admin/settings.php:1815 -msgid "Edit the 'Continue Reading' link added to your post excerpts." +#: includes/tgm.php:2488 +msgid "Plugin" msgstr "" -#: admin/settings.php:1830 -msgid "By default WordPress excerpts remove all HTML tags (" +#: includes/tgm.php:2489 +msgid "Source" msgstr "" -#: admin/settings.php:1861 -msgid "Show featured images as thumbnails on posts. The images must be selected for each post in the Featured Image section." +#: includes/tgm.php:2490 +msgid "Type" msgstr "" -#: admin/settings.php:1876 -msgid "Show the first image that you inserted in a post as a thumbnail. If you enable this option, the first image in your post will be used even if you selected a Featured Image in you post." +#: includes/tgm.php:2494 +msgid "Version" msgstr "" -#: admin/settings.php:1892 -msgid "Thumbnail alignment." +#: includes/tgm.php:2543 +#, php-format +msgid "Install %2$s" msgstr "" -#: admin/settings.php:1909 -msgid "The size you want the thumbnails to have (in pixels). By default imges will be scaled with aspect ratio kept. Choose to crop the images if you want the exact size." +#: includes/tgm.php:2547 +#, php-format +msgid "Update %2$s" msgstr "" -#: admin/settings.php:1925 -msgid "" -"Show featured images on headers. The header will be replaced with a featured image if you selected it as a Featured Image in the post and\n" -"\t\t\t\t\t\t\tand if it is bigger or at least equal to the current header size." +#: includes/tgm.php:2552 +#, php-format +msgid "Activate %2$s" msgstr "" -#: admin/settings.php:1941 -msgid "Select your desired Social network from the left dropdown menu and insert your corresponding address in the right input field. (ex: http://www.facebook.com/yourname )" +#: includes/tgm.php:2655 +msgid "Install" msgstr "" -#: admin/settings.php:1942 -msgid "You can insert up to 5 different social sites and addresses." +#: includes/tgm.php:2661 +msgid "Update" msgstr "" -#: admin/settings.php:1943 -msgid "There are a total of 27 social networks to choose from. " +#: includes/tgm.php:2664 +msgid "Activate" msgstr "" -#: admin/settings.php:1944 -msgid "You can leave any number of inputs empty. " +#: includes/tgm.php:2695 +msgid "No plugins were selected to be installed. No action taken." msgstr "" -#: admin/settings.php:1945 -msgid "You can choose the same social media any number of times. " +#: includes/tgm.php:2697 +msgid "No plugins were selected to be updated. No action taken." msgstr "" -#: admin/settings.php:2020 -msgid "Choose the areas where to display the social icons." +#: includes/tgm.php:2733 +msgid "No plugins are available to be installed at this time." msgstr "" -#: admin/settings.php:2033 -msgid "Insert custom text or HTML code that will appear last in you footer.
You can use HTML to insert links, images and special characters like © ." +#: includes/tgm.php:2735 +msgid "No plugins are available to be updated at this time." msgstr "" -#: admin/settings.php:2041 -msgid "Insert your custom CSS here. Any CSS declarations made here will overwrite Mantra's (even the custom options specified right here in the Mantra Settings page).
Your custom CSS will be preserved when updating the theme.
The <style> tags are not needed." +#: includes/tgm.php:3080 +msgid "Plugin activation failed." msgstr "" -#: admin/settings.php:2048 -msgid "Insert your custom Javascript code here. (Google Analytics and any other forms of Analytic software).
The <script> tags are not needed." +#: includes/tgm.php:3414 +#, php-format +msgid "Updating Plugin %1$s (%2$d/%3$d)" msgstr "" -#: admin/settings.php:2061 -msgid "Enable Mantra's Search Engine Optimization. This is enabled by default and should only be disabled if you are using a SEO plugin." +#: includes/tgm.php:3416 +#, php-format +msgid "An error occurred while installing %1$s: %2$s." msgstr "" -#: admin/settings.php:2062 -msgid "All title tags are handled automatically by Mantra." +#: includes/tgm.php:3417 +#, php-format +msgid "The installation of %1$s failed." msgstr "" -#: admin/settings.php:2065 -msgid "Homepage Meta Description" +#: includes/tgm.php:3421 +msgid "" +"The installation and activation process is starting. This process may take a " +"while on some hosts, so please be patient." msgstr "" -#: admin/settings.php:2067 -msgid "This is unique and you should fill this in. Describe your site the best you can and try not to go over 160 characters." +#: includes/tgm.php:3422 +#, php-format +msgid "%1$s installed and activated successfully." msgstr "" -#: admin/settings.php:2073 -msgid "Auto" +#: includes/tgm.php:3423 +msgid "All installations and activations have been completed." msgstr "" -#: admin/settings.php:2073 -msgid "Manual" +#: includes/tgm.php:3424 +#, php-format +msgid "Installing and Activating Plugin %1$s (%2$d/%3$d)" msgstr "" -#: admin/settings.php:2081 +#: includes/tgm.php:3427 msgid "" -"Auto - Mantra will automatically add post expcerpts to 'page' and 'post'\tmeta descriptions.
\n" -"\t\t\t\t\t Manual - you will enable a new custom field in your post/page admin section where you can type the exact description you want for every post and page.
\n" -"\t\t\t\t\t For category pages, the actual category descriptions will be used. Go to Posts > Categories and you can fill in a description for every category you have." +"The installation process is starting. This process may take a while on some " +"hosts, so please be patient." msgstr "" -#: admin/settings.php:2090 -msgid "Do not use" +#: includes/tgm.php:3429 +msgid "All installations have been completed." msgstr "" -#: admin/settings.php:2100 -msgid "If you want to show an author in the meta tags." +#: includes/tgm.php:3430 +#, php-format +msgid "Installing Plugin %1$s (%2$d/%3$d)" msgstr "" #: includes/theme-comments.php:28 @@ -1877,8 +2098,7 @@ msgstr "" msgid "at" msgstr "" -#: includes/theme-comments.php:41 -#: includes/theme-comments.php:58 +#: includes/theme-comments.php:41 includes/theme-comments.php:58 msgid "(Edit)" msgstr "" @@ -1910,11 +2130,15 @@ msgstr "" msgid "Menu" msgstr "" -#: includes/theme-functions.php:269 +#: includes/theme-functions.php:259 +msgid "Tag" +msgstr "" + +#: includes/theme-functions.php:271 msgid "Home Page" msgstr "" -#: includes/theme-functions.php:332 +#: includes/theme-functions.php:344 msgid "Powered by" msgstr "" @@ -1926,20 +2150,17 @@ msgstr "" msgid " Bookmark the " msgstr "" -#: includes/theme-loop.php:206 -#: includes/theme-loop.php:208 +#: includes/theme-loop.php:206 includes/theme-loop.php:208 #: includes/theme-loop.php:210 msgid "Permalink to" msgstr "" -#: includes/theme-loop.php:206 -#: includes/theme-loop.php:208 +#: includes/theme-loop.php:206 includes/theme-loop.php:208 #: includes/theme-loop.php:210 msgid "permalink" msgstr "" -#: includes/theme-loop.php:208 -#: includes/theme-loop.php:210 +#: includes/theme-loop.php:208 includes/theme-loop.php:210 msgid "Bookmark the " msgstr "" @@ -1951,102 +2172,151 @@ msgstr "" msgid "Newer posts »" msgstr "" -#: includes/theme-seo.php:26 -#, php-format -msgid "Page %s" -msgstr "" - -#: includes/theme-setup.php:90 +#: includes/theme-setup.php:94 msgid "Primary Navigation" msgstr "" -#: includes/theme-setup.php:91 +#: includes/theme-setup.php:95 msgid "Top Navigation" msgstr "" -#: includes/theme-setup.php:92 +#: includes/theme-setup.php:96 msgid "Footer Navigation" msgstr "" -#: includes/theme-setup.php:128 +#: includes/theme-setup.php:132 msgid "mantra" msgstr "" -#: includes/theme-setup.php:187 +#: includes/theme-setup.php:173 +#, php-format +msgid "Page %s" +msgstr "" + +#: includes/theme-setup.php:236 msgid "Skip to content" msgstr "" -#: includes/theme-setup.php:214 +#: includes/theme-setup.php:263 msgid "Primary Widget Area - Sidebar 1" msgstr "" -#: includes/theme-setup.php:216 +#: includes/theme-setup.php:265 msgid "Primary widget area - Sidebar 1" msgstr "" -#: includes/theme-setup.php:225 +#: includes/theme-setup.php:274 msgid "Secondary Widget Area - Sidebar 1" msgstr "" -#: includes/theme-setup.php:227 +#: includes/theme-setup.php:276 msgid "Secondary widget area - Sidebar 1" msgstr "" -#: includes/theme-setup.php:236 +#: includes/theme-setup.php:285 msgid "Third Widget Area - Sidebar 2" msgstr "" -#: includes/theme-setup.php:238 +#: includes/theme-setup.php:287 msgid "Third widget area - Sidebar 2" msgstr "" -#: includes/theme-setup.php:247 +#: includes/theme-setup.php:296 msgid "Fourth Widget Area - Sidebar 2" msgstr "" -#: includes/theme-setup.php:249 +#: includes/theme-setup.php:298 msgid "Fourth widget area - Sidebar 2" msgstr "" -#: includes/theme-setup.php:258 +#: includes/theme-setup.php:307 msgid "First Footer Widget Area" msgstr "" -#: includes/theme-setup.php:260 +#: includes/theme-setup.php:309 msgid "First footer widget area" msgstr "" -#: includes/theme-setup.php:269 +#: includes/theme-setup.php:318 msgid "Second Footer Widget Area" msgstr "" -#: includes/theme-setup.php:271 +#: includes/theme-setup.php:320 msgid "Second footer widget area" msgstr "" -#: includes/theme-setup.php:280 +#: includes/theme-setup.php:329 msgid "Third Footer Widget Area" msgstr "" -#: includes/theme-setup.php:282 +#: includes/theme-setup.php:331 msgid "The third footer widget area" msgstr "" -#: includes/theme-setup.php:291 +#: includes/theme-setup.php:340 msgid "Fourth Footer Widget Area" msgstr "" -#: includes/theme-setup.php:293 +#: includes/theme-setup.php:342 msgid "The fourth footer widget area" msgstr "" -#: includes/theme-setup.php:302 -#: includes/theme-setup.php:304 +#: includes/theme-setup.php:351 includes/theme-setup.php:353 msgid "Above content Widget Area" msgstr "" -#: includes/theme-setup.php:313 -#: includes/theme-setup.php:315 +#: includes/theme-setup.php:362 includes/theme-setup.php:364 msgid "Below Content Widget Area" msgstr "" +#: search.php:20 +#, php-format +msgid "Search Results for: %s" +msgstr "" + +#: search.php:39 +#, php-format +msgid "No search results for: %s" +msgstr "" + +#: searchform.php:1 +msgid "Search" +msgstr "" + +#: sidebar.php:26 sidebar.php:92 +msgid "Sidebar 1" +msgstr "" + +#: sidebar.php:28 sidebar.php:94 +#, php-format +msgid "" +"You currently have no widgets set in the primary sidebar. You can add " +"widgets via the Dashboard." +msgstr "" + +#: sidebar.php:29 sidebar.php:61 sidebar.php:95 sidebar.php:128 +#, php-format +msgid "" +"To hide this sidebar, switch to a different Layout via the Theme Settings." +msgstr "" + +#: sidebar.php:58 sidebar.php:125 +msgid "Sidebar 2" +msgstr "" + +#: sidebar.php:60 sidebar.php:127 +#, php-format +msgid "" +"You currently have no widgets set in the secondary sidebar. You can add " +"widgets via the Dashboard." +msgstr "" + +#: single.php:46 +msgid "View all posts by " +msgstr "" + +#: tag.php:21 +#, php-format +msgid "Tag Archives: %s" +msgstr "" diff --git a/themes/mantra/readme.txt b/themes/mantra/readme.txt index 743c5724..6b8e50fe 100644 --- a/themes/mantra/readme.txt +++ b/themes/mantra/readme.txt @@ -1,22 +1,63 @@ -Mantra Theme for WordPress -by Cryout Creations +============= +Mantra WordPress Theme +Copyright 2011-16 Cryout Creations + +Author: Cryout Creations +Requires at least: 4.0 +Tested up to: 4.4.2 +Stable tag: 2.5.0 +License: GPLv3 +License URI: http://www.gnu.org/licenses/gpl.html +Donate link: http://www.cryoutcreations.eu/donate/ Mantra is a do-it-yourself WordPress theme, featuring a pack of over 100 customization options and easy to use tweaks capable of tuning WordPress to your very specific needs and likes. With the help of a simple and efficient user interface you can customize everything:the layout (1,2 or 3 columns), total and partial site widths, colors (all texts, links, backgrounds etc.), fonts (over 35 font-families plus all Google Fonts), text and header sizes, post metas, post excerpts, post formats, header and background images, custom menus, 27 social media links and icons, pins, bullets and much much more. With a fully responsive layout,a customizable showcase presentation page, animated slider, magazine and blog layouts, 8 widget areas, modern graphics and an easy and intuitive admin section, you can start creating your dream site right now. -Theme created by Cryout Creations - www.cryoutcreations.eu -Theme support: www.cryoutcreations.eu/mantra +== License == + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation, either version 3 of the License, or +(at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program. If not, see http://www.gnu.org/copyleft/gpl.html + + +== Third Party Resources == + +Mantra WordPress Theme bundles the following third-party resources: + +Nivo Slider, Copyright Gilbert Pellegrom +Nivo Slider is licensed under the terms of the MIT license +Source: http://dev7studios.com/nivo-slider + +FitVids, Copyright Chris Coyier - http://css-tricks.com + Dave Rupert - http://daverupert.com +FitVids is licensed under the terms of the WTFPLlicense +Source: http://fitvidsjs.com/ +TGM Plugin Activation, Copyright Thomas Griffin +Licensed under the terms of the GNU GPL v2-or-later license +Source: http://tgmpluginactivation.com/ -The theme and all included binaries (all images, patterns and icons) are released under the GPLv2 licence, which means that you are free to use, modify, and redistribute the theme and all included binaries however you like, as long as you keep the licence together with the theme. This also means that you are free to use it for commercial purposes without any charges. Please read the included license.txt for the full licence. +tinyNav, Copyright Viljami Salminen +Licensed under the MIT license +Source: http://tinynav.viljamis.com/ -The Mantra Theme uses: -- Nivo Slider by Gilbert Pellegrom / under the MIT license / http://nivo.dev7studios.com/ -- tinyNav by @viljamis / under the MIT license / http://tinynav.viljamis.com/ -- FitVids by Chris Coyier - http://css-tricks.com + Dave Rupert - http://daverupert.com -- CSS3 PIE / Dual-licensed Apache License 2.0 or GPLv2 / http://css3pie.com/ +CSS3 PIE, Copyright Sencha Inc. +Dual-licensed under Apache License 2.0 and GPLv2 +Source: http://css3pie.com/ + +All other images bundled with the theme (used in the demo presentation page and admin section, as well as the social icons) are created by Cryout Creations and released with the theme under GPLv3 as well. + + +== Translations == -Translations credits: Chinese (Simplified) - Lín Xuan Li Czech - Satapouch Danish - IT-Fidusen @@ -34,4 +75,233 @@ Polish - Pawe Portuguese (Brazil) - Ivar P. Junior, Joao Lacerda Russian - Dmitry Kiryanov Spanish (Spain) - Raúl Antón Cuadrado, Sonia -Turkish - Emre Dalkiliç \ No newline at end of file +Turkish - Emre Dalkiliç + + +== Changelog == + += 2.5.0 = +* REMOVED THE THEME SETTINGS AND ADDED SUPPORT FOR THE SEPARATE THEME SETTINGS PLUGIN +* Integrated TGM to recommend and auto-install the theme settings plugin +* Removed theme SEO options as they are considered plugin territory and no longer allowed by the themes guidelines +* Fixed settings page to handle changed H3 to H2 headings in WordPress 4.4 +* Added above and below content area widget areas to page templates (including custom page with intro) +* Fixed header site title to not use H1 tag when homepage is static +* Add warning in settings page when pp enabled and static page is set +* Fixed WordPress 4.4.1+ issue with plugin/theme notifications being moved in the Layout settings section +* Added version information to style/script enqueues on both frontend and dashboard (to fix caching issues between updates) +* Fixed PHP notice in settings page when theme news are not available +* Rewrote readme file and added changelog into readme + += 2.4.1.1 = +* Fixed a conflict in 2.4.1 with one of our provided child themes + += 2.4.1 = +* added our social links to the settings page +* added title-tag theme support (for WordPress 4.1) +* fixed a weird save issue affecting only some servers caused by an apostrophe in the sample in custom footer text +* fixed images issues in WooCommerce caused by a max-width styling +* reverted bullet list styling changes done in 2.4 +* fixed text inside footer widgets not covered by general text options (and using styling defaults) + += 2.4 = +* removed shortcodes functionality (per WordPress Theme Guidelines) +* fixed wp.media issue +* fixed a namespace typo added in 2.3.3 +* added option to enable/disable zoom for mobile devices +* added Dailymotion social icon (thanks to Jean-Louis Rosolen) +* fixed breadcrumbs not handling tag pages +* replaced get_bloginfo(‘url’) with home_url() per latest WordPress guidelines +* replaced wp_convert_bytes_to_hr() (deprecated) with size_format() +* fixed layout/image border option non-clickable on IE 11 +* fixed title tag issue +* removed obsolete meta template tag +* fixed slider next/previous arrows always visible +* fixed slides count limitation when using custom posts by ID +* fixed disappearing/too small images inside tables issue on Chrome + += 2.3.4 = +* fixed the social icons (unable to disable) bug introduced in 2.3.3 +* corrected the meta show/hide options not working for custom post types (pointed out by tkemmere) +* corrected content editor (html .mceContentBody) width to properly use the configured site width instead of an arbitrary number +* improved handling of empty site title and/or description (will no longer display a single dash in the browser title) +* updated French translation + += 2.3.3 = +* updated to the new WP 3.8 “fluid-layout” and “fixed-layout” tags +* 3 social icons are now enabled by default in two theme areas +* fixed import/export settings not working on some rare occasions +* hopefully fixed smileys getting huge in captions +* changed default table cell alignment to top (instead of bottom) +* fixed Google fonts to correctly handle SSL websites +* added Recaptcha, Math Captcha, Captcha compatibility styling (thanks to David B) +* corrected site title not resizing enough on the smallest mobile devices +* updated French translation +* added Czech translation + += 2.3.2 = +* re-redesigned captions (added left/right padding back) +* corrected (enlarged) social icons sizes in sidebars +* corrected presentation page columns responsiveness on larger mobile devices +* fixed incorrect pagination on custom category pages +* fixed custom css style output missing proper HTML tag +* fixed presentation page styling being displayed after the mobile style, breaking the layout +* fixed XSS vulnerability in frontend.js +* (almost) ready for WordPress 3.8 + += 2.3.1 = +* added Steam social icon +* disabled auto-redirect to theme’s settings page after install (requested by WordPress) +* some cosmetic changes (multi-page pages/posts pagination, stikcy posts, post metas and author info) +* restored comments boxed styling +* fixes search form broken in 2.3.0 + += 2.3.0 = +* added mobile browser detection and added a new step of responsiveness for mobile browsers +* updated the media uploader; hopefully this fixes all reported issues with the media selector for slide/column images (the new media uploader is the one introduced in WordPress 3.5 so if you’re using an older version of WordPress now would be a good time to update). +* resized social images to 26×26 pixels +* fixed an image with caption size too big issue (reported by Ferran) +* fixed image sizing issue on Chrome +* updated comments and form elements design +* updated admin interface design +* beautified jQuery warning to make it less scary and intrusive +* cleaned up some ghosts of the past + += 2.2.2 = +* fixed mobile menu items are reversed on right align menus (because the right align menu items needed to be arranged reversed); you’ll need to re-order your menu items if using right align after this update +* fixed new shortcodes still closed with the old shortcodes mantra tag +* fixed stray “1” in the secondary sidebar +* fixed presentation page column images wrong aspect ration on some Android devices (and hopefully did not break anything for iDevices) +* fixed notices related to empty Google fonts fields in sanitize.php under PHP 5.4 + += 2.2.1 = +* added multi-column shortcode responsiveness +* added empty sidebar(s) notice(s) +* added [cryout-...] shortcodes (and we are deprecating the [mantra-...] ones, which we'll eventually remove) to prepare the switch to the upcoming shortcodes plugin +* fixed category page with intro template ignores the tag +* fixed object/iframe enlarging issues +* fixed presentation page posts to use the correct excerpt length (reported by Edward & MrAwesome) +* fixed incorrect featured images size on presentation page posts (reported by Deby & Scott) +* theme auto featured images now adhere to the set featured image size + += 2.2.0 = +* added option to display latest posts on presentation page below the columns, with configurable post count +* added menu items alignment option +* added Amazon and Yelp social icons + += 2.1.1 = +* breadcrumbs text size increase from .8em to 1em and moved inside content +* fixed presentation page columns responsiveness +* added support for WordPress’ 3.6 new galleries +* updated jQuery warning message to be more clear on when and why it is visible +* fixed footer links to open in new windows +* fixed the (supposedly previously) fixed lists bullets positioning + += 2.1 = +* cosmetic update of the admin interface; sub-section settings should be easier to spot now +* updated NivoSlider (fixes a double-load of the frontpage which may increase site loading time) +* fixed the tag functionality on blog page template (reported by Olrik) +* added header image Keep aspect ratio option for responsiveness +* fixed Featured image as header image functionality to display the correctly sized image in the header (reported by Fulco) +* fixed mobile menu not working with automatically generated menus +* fixed mobile icon responsiveness on Safari for mobile +* fixed sticky posts padding on Magazine layout and mobile +* fixed unordered lists bullet image positioning +* top and bottom menus now only show the top level elements (sub-menus are not displayed) +* fixed small issue with the search-bar on Chrome +* improved dashboard jQuery functionality check + += 2.0.7.1 = +* fixed the issue with dropdown menus failing to work on automatically generated menus +* fixed the layout widths slider failing to work in WP 3.6 +* fixed/improved mobile menu where it used to select incorrect item when the viewed page was not in the menu + += 2.0.7 = +* reverted the #content / .entry-content plugin compatibility “improvement” implemented in 2.0.4 as it was causing more issues than it solved +* fixed a couple of code typos (reported by Gary) +* improved drop down sub(-sub-sub…)menus usability by adding hoverintent and hiding delay (reported by Joel) +* fixed back-to-top button movement glitch on Firefox 17+ +* fixed jQuery version checking on WP 3.6 (reported by Detlef) +* fixed admin accordion compatibility with WP 3.6 + += 2.0.6 = +* fixed right sidebar padding for mobile devices +* fixed meta area height +* fixed one column layout right side spacing +* fixed top menu items being displayed in the reverse order +* fixed footer social icons sometimes being becoming partially hidden on mobile devices +* renamed “sub-header” to “headings” (according to W3C standards) +* added IMDb social icon +* improved compatibility with WordPress 3.4 + += 2.0.5 = +* Fixed fonts loosing their styling in post excepts +* Added top margin for post headers and removed their text shadows +* Fixed header and footer social icons responsiveness +* Fixed right sidebar padding in responsive view +* The logo link in the header is now using home_url() + += 2.0.4.1 = +* Fixed optset(), echo_first_image() functions not being properly prefixed + += 2.0.4 = +* Added a new setting for the header: left margin to complement the existing top margin setting. You’ll find them both in the Header Settings. Now you should be able to position your logo or site tile just the way you want to. +* Fixed the content header sizes (h1-h6) +* Fixed the searchbar on 404 pages +* Added buttons linking to the Background and Header pages (under Appearance) from the Mantra settings page +* Fixed the presentation page columns animation quirk on FireFox +* Added 3 new social icons: Xing, VK and Twitch TV +* Added an edit button to the ‘category page with intro’ template +* Added custom fields catid/slug/key to ‘category page with intro’ template +* Changed ‘Mobile view’ setting name to ‘Responsiveness’ (this was such a radical change that we almost made this Mantra v3.0. Almost. ) + += 2.0.3.1 = +* Fixed font-related issue introduced in 2.0.3 +* Fixed special characters support in Custom JS/CSS fields + += 2.0.3 = +* fixed mailto:mailto:mailto bug for Mail social icon +* fixed favicon preview incorrectly displayed custom logo instead of icon in dashboard +* slider caption size now self adjusts in responsive mode on mobile devices +* added mobile devices touchscreen support for the main menu +* improved search box auto-resize to fit in the sidebar +* new .pot file (for translators) +* fixed blog page template had no meta description (now displays the description set in the theme for the homepage) +* separated post meta bar and meta tags control in Post Meta Settings +* implemented workaround for iSomething devices’ browser incomplete support for responsive images inside relative dimension containers +* fixed unequal content column spacing on the sidebar on each side layout +* updated shortcode buttons look and added target attribute for them (see demo page for examples) +* added support for google fonts custom styles (and broke standard fonts functionality) +* corrected paragraph alignment + += 2.0.2 = +* Added support for shortcodes inside the Presentation Page columns and extra text +* Fixed site width being 0 in some rare, x-files related occurrences +* Fixed multiple issues with the new header in IE +* Fixed caption opacity for IE +* Fixed issue where the ‘Custom logo’ option was selected for the header but no logo was uploaded and an empty image place-holder was displayed in some browsers +* Relative dimensions are now labelled as DEPRECATED. We recommend using absolute dimensions with mobile view enabled (full responsiveness) +* Fixed ‘column’ shortcode widths + += 2.0.1 = +* Fixed missing social icons in the header +* Improved woocommerce compatibility +* Further improved mobile view +* Fixed Settings page animation +* Some really minor fixes not worth listing individually + += 2.0 = +* New and improved Mantra Settings page +* Moved several settings around for better grouping +* The new Header options set: Header Height, Site Header selector (Site Title / Logo / Link / None), Custom Logo uploader, Header Top Spacing and Rounded Corners for Menu Items. +* (finally) Fixed header responsiveness +* Sanitize function is made pluggable +* Hopefully fixed some array merging which sometimes lost the Mantra options +* Improved jQuery plugins compatibility +* Improved mobile view +* Fixed social mail link +* Fixed columns shortcodes +* Fixed HTML layout on the ‘Category page with intro’ template +* Undefined amount of small bug fixes + +Earlier changelogs are available at http://www.cryoutcreations.eu/mantra diff --git a/themes/mantra/style.css b/themes/mantra/style.css index 50fa6423..f0e49315 100644 --- a/themes/mantra/style.css +++ b/themes/mantra/style.css @@ -4,7 +4,7 @@ * Description: Mantra is a do-it-yourself WordPress theme, featuring a pack of over 100 customization options and easy to use tweaks capable of tuning WordPress to your very specific needs and likes. With the help of a simple and efficient user interface you can customize everything:the layout (1,2 or 3 columns), total and partial site widths, colors (all texts, links, backgrounds etc.), fonts (over 35 font-families plus all Google Fonts), text and header sizes, post metas, post excerpts, post formats, header and background images, custom menus, 27 social media links and icons, pins, bullets and much much more. With a fully responsive layout,a customizable showcase presentation page, animated slider, magazine and blog layouts, 8 widget areas, modern graphics and an easy and intuitive admin section, you can start creating your dream site right now. * Author: Cryout Creations * Author URI: http://www.cryoutcreations.eu - * Version: 2.4.1.1 + * Version: 2.5.0 * License: GNU General Public License v2.0 * License URI: http://www.gnu.org/licenses/gpl-2.0.html * Tags: black, red, blue, white, silver, light, dark, one-column, two-columns, three-columns, right-sidebar, left-sidebar, fixed-layout, fluid-layout, responsive-layout, custom-background, custom-colors, custom-header, custom-menu, featured-image-header, featured-images, front-page-post-form, full-width-template, microformats, post-formats, rtl-language-support, sticky-post, theme-options, threaded-comments, translation-ready diff --git a/themes/mantra/template-onecolumn.php b/themes/mantra/template-onecolumn.php index 0318c328..1c593b78 100644 --- a/themes/mantra/template-onecolumn.php +++ b/themes/mantra/template-onecolumn.php @@ -16,6 +16,7 @@ get_header(); ?>
+ @@ -31,7 +32,7 @@ get_header(); ?> - +
diff --git a/themes/mantra/template-page-with-intro.php b/themes/mantra/template-page-with-intro.php index 1edf1a98..04a01e83 100644 --- a/themes/mantra/template-page-with-intro.php +++ b/themes/mantra/template-page-with-intro.php @@ -7,6 +7,7 @@ Template Name: Category page with intro
+
> @@ -42,7 +43,8 @@ Template Name: Category page with intro endwhile; if($mantra_pagination=="Enable") mantra_pagination($the_query->max_num_pages); else mantra_content_nav( 'nav-below' ); ?> - + +
diff --git a/themes/mantra/template-threecolumns-center.php b/themes/mantra/template-threecolumns-center.php index fdfd74ba..4ed412d2 100644 --- a/themes/mantra/template-threecolumns-center.php +++ b/themes/mantra/template-threecolumns-center.php @@ -10,10 +10,15 @@ get_header(); ?>
+ + - - + + + +
+
diff --git a/themes/mantra/template-threecolumns-left.php b/themes/mantra/template-threecolumns-left.php index 5aea212f..cac71bfe 100644 --- a/themes/mantra/template-threecolumns-left.php +++ b/themes/mantra/template-threecolumns-left.php @@ -9,11 +9,16 @@ get_header(); ?>
-
+
+ + - + + +
+
diff --git a/themes/mantra/template-threecolumns-right.php b/themes/mantra/template-threecolumns-right.php index 18e59819..0397ecdd 100644 --- a/themes/mantra/template-threecolumns-right.php +++ b/themes/mantra/template-threecolumns-right.php @@ -10,10 +10,15 @@ get_header(); ?>
+ + - - + + + +
+
diff --git a/themes/mantra/template-twocolumns-left.php b/themes/mantra/template-twocolumns-left.php index 8613af73..c391308b 100644 --- a/themes/mantra/template-twocolumns-left.php +++ b/themes/mantra/template-twocolumns-left.php @@ -11,9 +11,14 @@ get_header(); ?>
- + + + + +
+
diff --git a/themes/mantra/template-twocolumns-right.php b/themes/mantra/template-twocolumns-right.php index 50d6dbba..56c87439 100644 --- a/themes/mantra/template-twocolumns-right.php +++ b/themes/mantra/template-twocolumns-right.php @@ -11,9 +11,14 @@ get_header(); ?>
- + + + + +
+ -- cgit v1.2.3-18-g5258
+
', + esc_html__( 'Upgrade message from the plugin author:', 'cryout' ), + ' ', wp_kses_data( $item['upgrade_notice'] ), ' +
+