diff options
author | 2016-02-12 22:16:38 -0500 | |
---|---|---|
committer | 2016-02-12 22:16:38 -0500 | |
commit | 1a286359bad2d6499483fc3923edbd16be4ef343 (patch) | |
tree | 95a1c3fd103419a0ea060e82bc159f75b93f1397 /themes | |
parent | Update jetpack plugin to release 3.5.3 and table of contents plus plugin to r... (diff) | |
download | blogs-gentoo-1a286359bad2d6499483fc3923edbd16be4ef343.tar.gz blogs-gentoo-1a286359bad2d6499483fc3923edbd16be4ef343.tar.bz2 blogs-gentoo-1a286359bad2d6499483fc3923edbd16be4ef343.zip |
Adding New Mantra version 2.4.1.1 - Bug 574468
Diffstat (limited to 'themes')
26 files changed, 257 insertions, 450 deletions
diff --git a/themes/mantra/admin/admin-functions.php b/themes/mantra/admin/admin-functions.php index 890426d1..bc70fa17 100644 --- a/themes/mantra/admin/admin-functions.php +++ b/themes/mantra/admin/admin-functions.php @@ -56,7 +56,7 @@ if ( isset( $_POST['mantra_export'] ) ){ function mantra_import_form(){
$bytes = apply_filters( 'import_upload_size_limit', wp_max_upload_size() );
- $size = wp_convert_bytes_to_hr( $bytes );
+ $size = size_format( $bytes );
$upload_dir = wp_upload_dir();
if ( ! empty( $upload_dir['error'] ) ) :
?><div class="error"><p><?php _e('Before you can upload your import file, you will need to fix the following error:', 'mantra'); ?></p>
diff --git a/themes/mantra/admin/css/admin.css b/themes/mantra/admin/css/admin.css index e278867f..115334ca 100644 --- a/themes/mantra/admin/css/admin.css +++ b/themes/mantra/admin/css/admin.css @@ -312,6 +312,10 @@ border:2px solid #CCC; width:60px;
}
+.layouts img, .images img {
+pointer-events: none;
+}
+
.borderful {
border-color:#F6A828 ;
@@ -617,3 +621,12 @@ border-color: #BCE8F1; border-style: solid; border-radius: 0; border-width: 0 0 padding:5px 10px;
}
+/* FB button fix */
+
+.fb-like.fb_iframe_widget > span {
+ vertical-align: baseline !important;
+}
+.twitter-follow-button.twitter-follow-button {
+ margin:0 8px;
+}
+
diff --git a/themes/mantra/admin/custom-styles.php b/themes/mantra/admin/custom-styles.php index b54415f0..0e59bd8b 100644 --- a/themes/mantra/admin/custom-styles.php +++ b/themes/mantra/admin/custom-styles.php @@ -216,7 +216,7 @@ $mantra_googlefontsubheader = str_replace('+',' ',preg_replace('/:.*/i','',$mant ?><?php if ($mantra_tables == "Enable") { ?> #content table {border:none;} #content tr {background:none;} #content table {border:none;} #content tr th,
#content thead th {background:none;} #content tr td {border:none;}<?php }
?><?php if ($mantra_headfontsize != "Default") { ?> #content h1.entry-title, #content h2.entry-title { font-size:<?php echo $mantra_headfontsize; ?> ;}<?php }
-?><?php if ($mantra_sidefontsize != "Default") { ?> .widget-area a:link, .widget-area a:visited { font-size:<?php echo $mantra_sidefontsize; ?> ;}<?php }
+?><?php if ($mantra_sidefontsize != "Default") { ?> .widget-area, .widget-area a:link, .widget-area a:visited { font-size:<?php echo $mantra_sidefontsize; ?> ;}<?php }
?><?php if ($mantra_textshadow != "Enable") { ?> #content h1, #content h2, #content h3, #content h4, #content h5, #content h6, #content .entry-title, #site-title a , #site-description { text-shadow:none; moz-text-shadow:none; -webkit-text-shadow:none ;}<?php }
?><?php if ($mantra_headerindent == "Enable") { ?> #content h1, #content h2, #content h3, #content h4, #content h5, #content h6 { margin-left:20px;} .sticky hgroup { background: url(<?php echo get_template_directory_uri().'/images/icon-featured.png' ; ?>) no-repeat 12px 10px transparent; padding-left: 15px;}<?php } ?>
diff --git a/themes/mantra/admin/defaults.php b/themes/mantra/admin/defaults.php index 086189cd..00c15d9e 100644 --- a/themes/mantra/admin/defaults.php +++ b/themes/mantra/admin/defaults.php @@ -13,6 +13,7 @@ $mantra_defaults = array( "mantra_sidewidthRel" => 60,
"mantra_sidebarRel" => 20,
"mantra_mobile" => "Enable",
+"mantra_zoom" => 0,
"mantra_hcontain" => "",
@@ -36,12 +37,12 @@ $mantra_defaults = array( "mantra_slideSpecific" => "",
"mantra_sliderimg1" => get_template_directory_uri()."/images/slider/mantra-slide1.jpg",
-"mantra_slidertitle1" => "This is your caption's title",
+"mantra_slidertitle1" => "This is the caption title",
"mantra_slidertext1" => "And this is the text that could accompany it. It is all optional so if you delete it in the Mantra Settings there will be no more caption with the black background.",
"mantra_sliderlink1" => "",
"mantra_sliderimg2" => get_template_directory_uri()."/images/slider/mantra-slide2.jpg",
"mantra_slidertitle2" => "This is yet another caption title",
-"mantra_slidertext2" => "And some more text to give you as an example. You can use <a href='http://www.cryoutcreations.eu' >links</a> and other type of <b>HTML</b> <i>formats</i>.",
+"mantra_slidertext2" => 'And some more text to give you as an example. You can use <a href="http://www.cryoutcreations.eu" >links</a> and other type of <b>HTML</b> <i>formats</i>.',
"mantra_sliderlink2" => "",
"mantra_sliderimg3" => "",
"mantra_slidertitle3" => "",
@@ -62,11 +63,11 @@ $mantra_defaults = array( "mantra_columnimg1" => get_template_directory_uri()."/images/slider/mantra-column.jpg",
"mantra_columntitle1" => "Hi there!",
-"mantra_columntext1" => "You can also have some text here. Just like with the slider, it's all optional (including the title and the link inputs). All you need is an image, unless you want the Mantra image above to follow you everywhere.",
+"mantra_columntext1" => "You can also have some text here. Just like with the slider, it is all optional (including the title and the link inputs). All you need is an image, unless you want the Mantra image above to follow you everywhere.",
"mantra_columnlink1" => "",
"mantra_columnimg2" => get_template_directory_uri()."/images/slider/mantra-column.jpg",
"mantra_columntitle2" => " HTML tags",
-"mantra_columntext2" => "You can also have <a href='http://www.cryoutcreations.eu'>links</a> here as well as some <strong>HTML tags</strong>.",
+"mantra_columntext2" => 'You can also have <a href="http://www.cryoutcreations.eu">links</a> here as well as some <strong>HTML tags</strong>.',
"mantra_columnlink2" => "",
"mantra_columnimg3" => get_template_directory_uri()."/images/slider/mantra-column.jpg",
"mantra_columntitle3" => "",
@@ -80,7 +81,7 @@ $mantra_defaults = array( "mantra_fronttext1" => "This could be a title",
"mantra_fronttext2" => "And this is a second title",
"mantra_fronttitlecolor" => "#333333",
-"mantra_fronttext3" => "And here you could have a whole lot of text. Or not. It's all up to you. Deleting all text inside the appropriate input in the Mantra Settings will remove this whole text zone. It can also contain some HTML tags.<br /> Just try everything out and see what suits you. Have fun and good luck! ",
+"mantra_fronttext3" => "And here you could have a whole lot of text. Or not. It is all up to you. Deleting all text inside the appropriate input in the Mantra Settings will remove this whole text zone. It can also contain some HTML tags.<br /> Just try everything out and see what suits you. Have fun and good luck! ",
"mantra_fronttext4" => "",
"mantra_fronthideheader" => "",
diff --git a/themes/mantra/admin/js/admin.js b/themes/mantra/admin/js/admin.js index 3978f7da..4b554662 100644 --- a/themes/mantra/admin/js/admin.js +++ b/themes/mantra/admin/js/admin.js @@ -2,38 +2,39 @@ * Admin js
*/
-jQuery(document).ready(function() {
-
-var uploadparent = 0;
- function media_upload( button_class) {
+function media_upload( button_class) {
+ if (!window.wp || !window.wp.media || !window.wp.media.editor || !window.wp.media.editor.send || !window.wp.media.editor.send.attachment) return;
var _custom_media = true,
_orig_send_attachment = wp.media.editor.send.attachment;
jQuery('body').on('click',button_class, function(e) {
- uploadparent = jQuery(this).closest('div');
- var button_id ='#'+jQuery(this).attr('id');
- /* console.log(button_id); */
- var self = jQuery(button_id);
- var send_attachment_bkp = wp.media.editor.send.attachment;
- var button = jQuery(button_id);
- // var id = button.attr('id').replace('_button', '');
- _custom_media = true;
- wp.media.editor.send.attachment = function(props, attachment){
- if ( _custom_media ) {
- // jQuery('.custom_media_id').val(attachment.id);
- uploadparent.find('.slideimages').val(attachment.url);
- uploadparent.find('.imagebox').attr('src',attachment.url);
- // jQuery('.custom_media_image').attr('src',attachment.url).css('display','block');
- } else {
- return _orig_send_attachment.apply( button_id, [props, attachment] );
- }
- }
- wp.media.editor.open(button);
- return false;
+ uploadparent = jQuery(this).closest('div');
+ var button_id ='#'+jQuery(this).attr('id');
+ /* console.log(button_id); */
+ var self = jQuery(button_id);
+ var send_attachment_bkp = wp.media.editor.send.attachment;
+ var button = jQuery(button_id);
+ /* var id = button.attr('id').replace('_button', ''); */
+ _custom_media = true;
+ wp.media.editor.send.attachment = function(props, attachment){
+ if ( _custom_media ) {
+ /* jQuery('.custom_media_id').val(attachment.id); */
+ uploadparent.find('.slideimages').val(attachment.url);
+ uploadparent.find('.imagebox').attr('src',attachment.url);
+ /* jQuery('.custom_media_image').attr('src',attachment.url).css('display','block'); */
+ } else {
+ return _orig_send_attachment.apply( button_id, [props, attachment] );
+ }
+ }
+ wp.media.editor.open(button);
+ return false;
});
-}
-media_upload( '.upload_image_button');
-
+}
+jQuery(document).ready(function() {
+
+var uploadparent = 0;
+ media_upload( '.upload_image_button' );
+
// Show/hide slides
jQuery('.slidetitle').click(function() {
jQuery(this).next().toggle("fast");
@@ -182,4 +183,25 @@ function changeBorder (idName, className) { jQuery('#'+idName).addClass( 'borderful' );
return 0;
-}
\ No newline at end of file +}
+
+/* FB like button */
+(function(d, s, id) {
+ var js, fjs = d.getElementsByTagName(s)[0];
+ if (d.getElementById(id)) return;
+ js = d.createElement(s); js.id = id;
+ js.src = "//connect.facebook.net/en_US/sdk.js#xfbml=1&version=v2.0";
+ fjs.parentNode.insertBefore(js, fjs);
+}(document, 'script', 'facebook-jssdk'));
+
+/* Twitter follow button */
+window.twttr = (function (d, s, id) {
+ var t, js, fjs = d.getElementsByTagName(s)[0];
+ if (d.getElementById(id)) return;
+ js = d.createElement(s); js.id = id;
+ js.src= "https://platform.twitter.com/widgets.js";
+ fjs.parentNode.insertBefore(js, fjs);
+ return window.twttr || (t = { _e: [], ready: function (f) { t._e.push(f) } });
+}(document, "script", "twitter-wjs"));
+
+/* FIN */
\ No newline at end of file diff --git a/themes/mantra/admin/main.php b/themes/mantra/admin/main.php index ebc6fecb..96bb826e 100644 --- a/themes/mantra/admin/main.php +++ b/themes/mantra/admin/main.php @@ -298,14 +298,23 @@ The Parabola Settings page cannot function without jQuery. </em></div> <div class="inside"><?php echo "<p>Here at Cryout Creations (the developers of yours truly Mantra Theme), we spend night after night improving the Mantra Theme. We fix a lot of bugs (that we previously created); we add more and more customization options while also trying to keep things as simple as possible; then... we might play a game or two but rest assured that we return to read and (in most cases) reply to your late night emails and comments, take notes and draw dashboards of things to implement in future versions.</p>
<p>So you might ask yourselves: <i>How do they do it? How can they keep so fresh after all that hard labor for that darned theme? </i> Well folks, it's simple. We drink coffee. Industrial quantities of hot boiling coffee. We love it! So if you want to help with the further development of the Mantra Theme...</p>"; ?>
<div style="display:block;float:none;margin:0 auto;text-align:center;">
-<form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_top">
-<input type="hidden" name="cmd" value="_s-xclick">
-<input type="hidden" name="encrypted" value="-----BEGIN PKCS7-----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-----END PKCS7-----
-">
-<input type="image" src="<?php echo get_template_directory_uri() . '/admin/images/coffee.png' ?>" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
-<img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1">
-</form>
+ <form action="https://www.paypal.com/cgi-bin/webscr" method="post" target="_blank">
+ <input type="hidden" name="cmd" value="_donations">
+ <input type="hidden" name="business" value="KYL26KAN4PJC8">
+ <input type="hidden" name="item_name" value="Cryout Creations / Mantra Theme donation">
+ <input type="hidden" name="currency_code" value="EUR">
+ <input type="hidden" name="bn" value="PP-DonationsBF:btn_donate_SM.gif:NonHosted">
+ <input type="image" src="<?php echo get_template_directory_uri() . '/admin/images/coffee.png' ?>" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
+ <img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1">
+ </form>
+
+ </div>
+ <p>Or socially smother, caress and embrace us:</p>
+ <div style="display:table;float:none;margin:0 auto;">
+ <div id="fb-root"></div><div class="fb-like" data-href="https://www.facebook.com/CryoutCreations" data-layout="button" data-action="like" data-show-faces="false" data-share="false"></div>
+ <a href="https://twitter.com/cryoutcreations" class="twitter-follow-button" data-show-count="false" data-show-screen-name="false">Follow @cryoutcreations</a>
+ <script src="https://apis.google.com/js/platform.js" async defer></script> <div class="g-plusone" data-href="https://plus.google.com/+CryoutcreationsEuCR2" data-size="medium" data-annotation="none"></div>
</div>
</div><!-- inside -->
</div><!-- donate -->
@@ -349,9 +358,8 @@ The Parabola Settings page cannot function without jQuery. </em></div> foreach( $news_items as $news_item ) : ?>
<li>
<a class="news-header" href='<?php echo esc_url( $news_item->get_permalink() ); ?>'><?php echo esc_html( $news_item->get_title() ); ?></a><br />
- <span class="news-item-date"><?php _e('Posted on','mantra');echo $news_item->get_date(' j F Y, H:i'); ?></span><br />
- <?php echo mantra_truncate_words(strip_tags( $news_item->get_description() ),40,'...') ; ?>
- <br><a class="news-read" href='<?php echo esc_url( $news_item->get_permalink() ); ?>'>Read more »</a>
+ <span class="news-item-date"><?php _e('Posted on','mantra');echo $news_item->get_date(' j F Y'); ?></span><br />
+ <a class="news-read" href='<?php echo esc_url( $news_item->get_permalink() ); ?>'>Read more »</a>
</li>
<?php endforeach; endif; ?>
</ul>
diff --git a/themes/mantra/admin/sanitize.php b/themes/mantra/admin/sanitize.php index 709d10c7..bc25e3a8 100644 --- a/themes/mantra/admin/sanitize.php +++ b/themes/mantra/admin/sanitize.php @@ -49,10 +49,11 @@ /* Social media links */
- $socialNetworks = array ("Amazon", "Delicious", "DeviantArt", "Digg", "Etsy", "Facebook", "Flickr", "Google", "GoodReads", "GooglePlus",
- "IMDb", "Instagram", "LastFM", "LinkedIn", "Mail", "MySpace", "Picasa", "Pinterest", "Reddit", "RSS", "Skype",
- "Steam", "SoundCloud", "StumbleUpon", "Technorati", "Tumblr", "Twitch", "Twitter", "Vimeo", "VK", "WordPress",
- "Xing", "Yahoo", "Yelp", "YouTube" );
+ $socialNetworks = array ("Amazon", "Dailymotion", "Delicious", "DeviantArt", "Digg", "Etsy", "Facebook", "Flickr",
+ "Google", "GoodReads", "GooglePlus", "IMDb", "Instagram", "LastFM", "LinkedIn", "Mail",
+ "MySpace", "Picasa", "Pinterest", "Reddit", "RSS", "Skype", "Steam", "SoundCloud",
+ "StumbleUpon", "Technorati", "Tumblr", "Twitch", "Twitter", "Vimeo", "VK", "WordPress",
+ "Xing", "Yahoo", "Yelp", "YouTube" );
@@ -74,6 +75,7 @@ global $mantra_defaults; if(isset($input['mantra_sidewidthRel']) && is_numeric($input['mantra_sidewidthRel']) && $input['mantra_sidewidthRel']>=40 && $input['mantra_sidewidthRel'] <=80) {} else {$input['mantra_sidewidthRel']=$mantra_defaults['mantra_sidewidthRel']; }
if(isset($input['mantra_sidebarRel']) && is_numeric($input['mantra_sidebarRel']) && $input['mantra_sidebarRel']>=20 && $input['mantra_sidebarRel'] <=50) {} else {$input['mantra_sidebarRel']=$mantra_defaults['mantra_sidebarRel']; }
+ if (isset($input['mantra_zoom'])) $input['mantra_zoom'] = "1"; else $input['mantra_zoom'] = 0;
$input['mantra_hheight'] = intval(wp_kses_data($input['mantra_hheight']));
diff --git a/themes/mantra/admin/settings.php b/themes/mantra/admin/settings.php index 96230225..3f73a4d4 100644 --- a/themes/mantra/admin/settings.php +++ b/themes/mantra/admin/settings.php @@ -228,7 +228,11 @@ function cryout_setting_mobile_fn() { echo ">$itemsare[$id]</option>";
}
echo "</select>";
- $checkedClass = ($mantra_options['mantra_hcontain']=='1') ? ' checkedClass' : '';
+
+ echo " <label style='border:none;margin-left:10px;' for='mantra_zoom' class='socialsdisplay'><input ";
+ checked($mantra_options['mantra_zoom'],'1');
+ echo " value='". $mantra_options['mantra_zoom'] ."' id='mantra_zoom' name='ma_options[mantra_zoom]' type='checkbox' /> Allow zoom </label>";
+
echo "<div><small>".__("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.<br> Do not disable unless you have a good reason to.","mantra")."</small></div>";
}
@@ -712,7 +716,7 @@ function cryout_setting_himage_fn() { global $mantra_options;
$checkedClass = ($mantra_options['mantra_hcenter']=='1') ? ' checkedClass' : '';
$checkedClass2 = ($mantra_options['mantra_hratio']=='1') ? ' checkedClass' : '';
- echo "<a href=\"?page=custom-header\" class=\"button\" target=\"_blank\">".__('Define header image')."</a>";
+ echo "<a href=\"?page=custom-header\" class=\"button\" target=\"_blank\">".__('Define header image','mantra')."</a>";
echo "<div><small>".__("The header image should not be used to display logos.<br> Enable ratio preservation to force the header image aspect ratio. Keep in mind that short images will become very small on mobile devices.","mantra")."</small></div>";
echo "<br><label id='hcenter' for='mantra_hcenter' class='socialsdisplay $checkedClass'><input ";
checked($mantra_options['mantra_hcenter'],'1');
@@ -1169,7 +1173,7 @@ foreach($items as $id=>$item) { ////////////////////////////////
function cryout_setting_sitebackground_fn() {
- echo "<a href=\"?page=custom-background\" class=\"button\" target=\"_blank\">".__('Define background image')."</a>";
+ echo "<a href=\"?page=custom-background\" class=\"button\" target=\"_blank\">".__('Define background image','mantra')."</a>";
} // cryout_setting_sitebackground_fn()
@@ -1827,9 +1831,9 @@ foreach($items as $id=>$item) { echo ">$itemsare[$id]</option>";
}
echo "</select>";
- echo "<div><small>".__("By default WordPress excerpts remove all HTML tags (".htmlspecialchars('<pre>, <a>, <b>')." and all others) and only clean text is left in the excerpt.
+ echo "<div><small>".sprintf(__("By default WordPress excerpts remove all HTML tags (%s and all others) and only clean text is left in the excerpt.
Enabling this option allows HTML tags to remain in excerpts so all your default formating will be kept.<br /> <b>Just a warning: </b>If HTML tags are enabled, you have to make sure
-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 -- ","mantra")."</small></div>";
+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 -- </small></div>","mantra"),htmlspecialchars('<pre>, <a>, <b>') );
}
diff --git a/themes/mantra/functions.php b/themes/mantra/functions.php index 82d31783..19301e73 100644 --- a/themes/mantra/functions.php +++ b/themes/mantra/functions.php @@ -1,14 +1,14 @@ <?php
/*
* Functions file
- * Includes all necesary files
- * PLEASE DO NOT EDIT THIS FILE IN ANY WAY
+ * Includes all necessary files
+ * PLEASE DO NOT EDIT THIS FILE
*
* @package mantra
*/
// Variable for theme version
-define ("MANTRA_VERSION","2.3.4");
+define ("MANTRA_VERSION","2.4.1.1");
require_once(dirname(__FILE__) . "/admin/main.php"); // Load necessary admin files
@@ -19,7 +19,6 @@ require_once(dirname(__FILE__) . "/includes/theme-loop.php"); //Loop related fie require_once(dirname(__FILE__) . "/includes/theme-seo.php"); //SEO related fiels
require_once(dirname(__FILE__) . "/includes/theme-frontpage.php"); //Frontpage generation
require_once(dirname(__FILE__) . "/includes/theme-comments.php"); //Theme comment functions
-require_once(dirname(__FILE__) . "/includes/theme-shortcodes.php"); //Theme shortcodes
require_once(dirname(__FILE__) . "/includes/theme-functions.php"); //Theme misc functions
require_once(dirname(__FILE__) . "/includes/theme-hooks.php"); //Theme hooks
diff --git a/themes/mantra/images/socials/Dailymotion.png b/themes/mantra/images/socials/Dailymotion.png Binary files differnew file mode 100644 index 00000000..cb6a3026 --- /dev/null +++ b/themes/mantra/images/socials/Dailymotion.png diff --git a/themes/mantra/includes/theme-comments.php b/themes/mantra/includes/theme-comments.php index 11604462..d53532ae 100644 --- a/themes/mantra/includes/theme-comments.php +++ b/themes/mantra/includes/theme-comments.php @@ -82,7 +82,7 @@ if ( ! function_exists( 'mantra_comments_on' ) ) : * Number of comments on loop post if comments are enabled.
*/
function mantra_comments_on() {
-printf ( comments_popup_link( __( 'Leave a comment', 'mantra' ), __( '<b>1</b> Comment', 'mantra' ), __( '<b>%</b> Comments', 'mantra' ) ));
+ printf ( comments_popup_link( __( 'Leave a comment', 'mantra' ), __( '<b>1</b> Comment', 'mantra' ), __( '<b>%</b> Comments', 'mantra' ) ));
}
endif;
diff --git a/themes/mantra/includes/theme-frontpage.php b/themes/mantra/includes/theme-frontpage.php index 213545ec..1a093221 100644 --- a/themes/mantra/includes/theme-frontpage.php +++ b/themes/mantra/includes/theme-frontpage.php @@ -90,7 +90,7 @@ foreach ($mantra_options as $key => $value) { effect: '<?php echo $mantra_fpslideranim; ?>',
animSpeed: <?php echo $mantra_fpslidertime ?>,
<?php if($mantra_fpsliderarrows=="Hidden") { ?> directionNav: false, <?php }
- if($mantra_fpsliderarrows=="Always Visible") { ?> directionNavHide: false, <?php } ?>
+ if($mantra_fpsliderarrows=="Always Visible") { ?> directionNav: true, <?php } ?>
pauseTime: <?php echo $mantra_fpsliderpause ?>
});
@@ -145,7 +145,7 @@ break; case 'Specific Posts' :
// Transofm string separated by commas into array
$pieces_array = explode(",", $mantra_slideSpecific);
-$custom_query->query(array( 'post_type' => 'any', 'post__in' => $pieces_array, 'ignore_sticky_posts' => 1,'orderby' => 'post__in' ));
+$custom_query->query(array( 'post_type' => 'any', 'showposts' => -1, 'post__in' => $pieces_array, 'ignore_sticky_posts' => 1, 'orderby' => 'post__in' ));
break;
}
@@ -153,7 +153,7 @@ break; $i=0; $j=0;?>
<div class="slider-wrapper theme-default">
<div class="ribbon"></div>
- <div id="slider" class="nivoSlider">
+ <div id="slider" class="nivoSlider <?php if($mantra_fpsliderarrows=="Visible on Hover"): ?>slider-navhover<?php endif; ?>">
<?php
// Loop for creating the slides
@@ -185,7 +185,7 @@ $i=0; $j=0;?> ?>
<div class="slider-wrapper theme-default">
<div class="ribbon"></div>
- <div id="slider" class="nivoSlider">
+ <div id="slider" class="nivoSlider <?php if($mantra_fpsliderarrows=="Visible on Hover"): ?>slider-navhover<?php endif; ?>">
<?php for ($i=1;$i<=5;$i++)
if(${"mantra_sliderimg$i"}) {?> <a href='<?php echo esc_url(${"mantra_sliderlink$i"}) ?>'><img src='<?php echo esc_url(${"mantra_sliderimg$i"}) ?>' alt="" <?php if (${"mantra_slidertitle$i"} || ${"mantra_slidertext$i"} ) { ?>title="#caption<?php echo $i;?>" <?php }?> /></a><?php } ?>
</div>
diff --git a/themes/mantra/includes/theme-functions.php b/themes/mantra/includes/theme-functions.php index 6698de72..e19b5c56 100644 --- a/themes/mantra/includes/theme-functions.php +++ b/themes/mantra/includes/theme-functions.php @@ -230,7 +230,7 @@ foreach ($mantra_options as $key => $value) { ${"$key"} = $value; } global $post;
echo '<div class="breadcrumbs">';
if (is_page() && !is_front_page() || is_single() || is_category() || is_archive()) {
- echo '<a href="'.get_bloginfo('url').'">'.get_bloginfo('name').' » </a>';
+ echo '<a href="'.esc_url( home_url() ) .'">'.get_bloginfo('name').' » </a>';
if (is_page()) {
$ancestors = get_post_ancestors($post);
@@ -255,7 +255,9 @@ if (is_page() && !is_front_page() || is_single() || is_category() || is_archive( echo ''.$category[0]->cat_name.'';
}
-
+ if (is_tag()) {
+ echo ''.__('Tag','mantra').' » '.single_tag_title('', false);
+ }
// Current page
if (is_page() || is_single()) {
@@ -265,7 +267,7 @@ if (is_page() && !is_front_page() || is_single() || is_category() || is_archive( } elseif (is_home() && $mantra_frontpage!="Enable" ) {
// Front page
echo '';
- echo '<a href="'.get_bloginfo('url').'">'.get_bloginfo('name').'</a> '."» ";
+ echo '<a href="'.esc_url( home_url() ) .'">'.get_bloginfo('name').'</a> '."» ";
_e('Home Page','mantra');
echo '';
}
diff --git a/themes/mantra/includes/theme-loop.php b/themes/mantra/includes/theme-loop.php index 7d09d4c6..77debcee 100644 --- a/themes/mantra/includes/theme-loop.php +++ b/themes/mantra/includes/theme-loop.php @@ -29,7 +29,7 @@ add_filter( 'excerpt_length', 'mantra_excerpt_length' ); */
function mantra_continue_reading_link() {
global $mantra_excerptcont;
- return ' <a href="'. get_permalink() . '">' .$mantra_excerptcont.' <span class="meta-nav">→ </span>' . '</a>';
+ return ' <a class="continue-reading-link" href="'. get_permalink() . '">' .$mantra_excerptcont.' <span class="meta-nav">→ </span>' . '</a>';
}
/**
diff --git a/themes/mantra/includes/theme-seo.php b/themes/mantra/includes/theme-seo.php index 6589f40c..09b3540a 100644 --- a/themes/mantra/includes/theme-seo.php +++ b/themes/mantra/includes/theme-seo.php @@ -23,7 +23,7 @@ function mantra_filter_wp_title( $title ) { // Add pagination if that's the case
global $page, $paged;
if ( $paged >= 2 || $page >= 2 )
- $filtered_title .= ' | ' . sprintf( __( 'Page %s', 'parabola' ), max( $paged, $page ) );
+ $filtered_title .= ' | ' . sprintf( __( 'Page %s', 'mantra' ), max( $paged, $page ) );
// Return the modified title
return $filtered_title;
@@ -81,17 +81,11 @@ function mantra_seo_name() { ${"$key"} = $value ;}
echo '<meta name="author" content="'.$mantra_seo_author.'" />';
}
- /**
- * Meta Theme
- */
-function mantra_seo_template() {
-echo PHP_EOL.'<meta property="template" content="mantra" />'.PHP_EOL;
-}
+
/**
* Meta Title
*/
function mantra_seo_title() {
-echo "<title>".wp_title( '', false, 'right' )."</title>".PHP_EOL;
echo '<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />';
}
@@ -106,9 +100,8 @@ 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');
-
-add_action ('cryout_seo_hook','mantra_seo_template');
}
+
if($mantra_seo=="Enable") mantra_seo_generator() ;
else add_action ('cryout_seo_hook','mantra_seo_title',0);
diff --git a/themes/mantra/includes/theme-setup.php b/themes/mantra/includes/theme-setup.php index 20841606..3502621f 100644 --- a/themes/mantra/includes/theme-setup.php +++ b/themes/mantra/includes/theme-setup.php @@ -61,6 +61,9 @@ function mantra_setup() { // This theme styles the visual editor with editor-style.css to match the theme style.
add_editor_style();
+
+ // Support title tag since WP 4.1
+ add_theme_support( 'title-tag' );
// This theme uses post thumbnails
add_theme_support( 'post-thumbnails' );
@@ -132,6 +135,51 @@ $locale_file = get_template_directory() . "/languages/$locale.php"; }
endif;
+// remove obsolete mantra functions action hooks
+if ( ! function_exists( 'mantra_remove_obsolete_functions' ) ) :
+function mantra_remove_obsolete_functions() {
+ remove_filter( 'wp_title', 'mantra_filter_wp_title' );
+ remove_filter('wp_title_rss','mantra_filter_wp_title_rss');
+}
+add_action('init','mantra_remove_obsolete_functions');
+endif;
+
+// Backwards compatibility for the title-tag
+if ( ! function_exists( '_wp_render_title_tag' ) ) :
+ add_action( 'wp_head', 'mantra_render_title' );
+ add_filter( 'wp_title', 'mantra_filter_wp_title2' );
+ add_filter('wp_title_rss','mantra_filter_wp_title_rss2');
+endif;
+
+function mantra_render_title() { ?>
+ <title><?php wp_title( '', true, 'right' ); ?></title>
+<?php }
+
+function mantra_filter_wp_title2( $title ) {
+ // Get the Site Name
+ $site_name = get_bloginfo( 'name' );
+ // Prepend name
+ $filtered_title = (((strlen($site_name)>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 nirvana_filter_wp_title_rss2($title) {
+ return ' ';
+}
+
if ( ! function_exists( 'mantra_admin_header_style' ) ) :
/**
* Styles the header image displayed on the Appearance > Header admin panel.
diff --git a/themes/mantra/includes/theme-shortcodes.php b/themes/mantra/includes/theme-shortcodes.php deleted file mode 100644 index 5c238333..00000000 --- a/themes/mantra/includes/theme-shortcodes.php +++ /dev/null @@ -1,303 +0,0 @@ -<?php
-/**
- * The shortcodes and corresponding functions
- *
- * @package mantra
- * @subpackage Functions
- */
-
-add_shortcode('mantra-site', 'mantra_site_link_fn');
-add_shortcode('mantra-author', 'mantra_the_author_fn');
-add_shortcode('mantra-tag-cloud', 'mantra_tag_cloud_fn');
-add_shortcode('mantra-multi', 'mantra_multi_column_fn');
-add_shortcode('mantra-column', 'mantra_column_fn');
-add_shortcode( 'mantra-pullquote', 'mantra_pullquote_fn' );
-add_shortcode( 'mantra-button-light', 'mantra_button_light_fn' );
-add_shortcode( 'mantra-button-dark', 'mantra_button_dark_fn' );
-add_shortcode( 'mantra-button-color', 'mantra_button_color_fn' );
-
-add_shortcode('cryout-site', 'mantra_site_link_fn');
-add_shortcode('cryout-author', 'mantra_the_author_fn');
-add_shortcode('cryout-tag-cloud', 'mantra_tag_cloud_fn');
-add_shortcode('cryout-multi', 'mantra_multi_column_fn');
-add_shortcode('cryout-column', 'mantra_column_fn');
-add_shortcode( 'cryout-pullquote', 'mantra_pullquote_fn' );
-add_shortcode( 'cryout-button-light', 'mantra_button_light_fn' );
-add_shortcode( 'cryout-button-dark', 'mantra_button_dark_fn' );
-add_shortcode( 'cryout-button-color', 'mantra_button_color_fn' );
-
-/**
- * Returns a link to the current site
- * No attributes
- */
-
-function mantra_site_fn() {
- return '<a class="site-link" href="'.get_bloginfo('url').'" title="'.esc_attr(get_bloginfo('name')).'" rel="home">'.get_bloginfo('name').'</a>';
-}
-/**
- * Returns current user information
- * Example of use:
- * [mantra-author display='attr'] where attr can be author / description / login / first-name / last-name / nickname / id / url / link / aim / yim / posts / posts-url
- * Attributes:
- * "display" - optional
- */
-function mantra_the_author_fn($attr) {
- global $mantra_social_networks;
- $id = get_the_author_meta('ID');
- if ($id) {
- if (isset($attr['display'])) {
- $display = $attr['display'];
- switch ($display) {
- case 'author':
- return get_the_author();
- case 'description':
- return get_the_author_meta('description', $id);
- case 'login':
- return get_the_author_meta('user_login', $id);
- case 'first-name':
- return get_the_author_meta('first_name', $id);
- case 'last-name':
- return get_the_author_meta('last_name', $id);
- case 'nickname':
- return get_the_author_meta('nickname', $id);
- case 'id':
- return $id;
- case 'url':
- return get_the_author_meta('user_url', $id);
- case 'email':
- return get_the_author_meta('user_email', $id);
- case 'link':
- if (get_the_author_meta('user_url', $id)) {
- return '<a href="'.get_the_author_meta('user_url', $id).'" title="'.esc_attr(get_the_author()).'" rel="external">'.get_the_author().'</a>';
- }
- else {
- return get_the_author();
- }
- case 'aim':
- return get_the_author_meta('aim', $id);
- case 'yim':
- return get_the_author_meta('yim', $id);
- case 'posts':
- return get_the_author_posts();
- case 'posts-url':
- return get_author_posts_url(get_the_author_meta('ID'));
- }
-
- }
- else {
- return get_the_author();
- }
- }
-}
-
-
-/**
- * Echos a tag could
- * Example of use:
- * [mantra-tag-cloud min=10 max=15 number=5] where min and max are the minimum and the maximum font sizes and count is the number of tags to show in the cloud
- * Attributes:
- * "min" - optional
- * "max" - optional
- * "count" - optional
- */
-function mantra_tag_cloud_fn($attr) {
- if (isset($attr['min'])) $attr['min'] = (int)$attr['min'];
- if (isset($attr['max'])) $attr['max'] = (int)$attr['max'];
- if (isset($attr['count'])) $attr['count'] = (int)$attr['count'];
- $attr['echo'] = false;
- return wp_tag_cloud($attr);
-}
-
-
-/**
- * Creates the container for multi-column content, corresponding to the short code [mantra-multic].
- * No attributes are used. Should always be used to incapsulate [mantra-column] tags
- * No attributes
- */
-function mantra_multi_column_fn($attr, $content = null) {
- $content = do_shortcode($content);
- return "<div class='multi-colum'>".$content."</div>";
-}
-
-/**
- * Multiple columns
- * Uses [mantra-column] to create multiple columns
- * It should be used inside [mantra-multic] short codes.
- * Attributes:
- * "width" - can take values 1, 1/2, 1/3, 1/4, 1/6, 1/8, 2/3, 3/4, 5/6 The default value is 1.
- * "class" - optional - can be whatever you like for furter CSS editing
- * Example of use
- * [mantra-multi]
- * [mantra-column width='1/2']This is a half column[/mantra-column]
- * [mantra-column width='1/2']This is another half column[/mantra-column]
- * [/mantra-multi]
- * Or:
- * [mantra-multi]
- * [mantra-column width='1/3']This is a one third column[/mantra-column]
- * [mantra-column width='2/3']This is a two thirds column[/mantra-column]
- * [/mantra-multi]
- * Or:
- * [mantra-multi]
- * [mantra-column width='1/4']This is a quarter column[/mantra-column]
- * [mantra-column width='1/2']This is a half column [/mantra-column]
- * [mantra-column width='1/4']And this is another quarter column[/mantra-column]
- * [/mantra-multi]
- * Make sure the widths do not go over 100% ( ex: 1/4 + 1/2 + 1/4 = 1 =100%)
- *
-
- */
-function mantra_column_fn($attr, $content = null) {
- $content = do_shortcode($content);
- $width = isset($attr['width']) ? $attr['width'] : "1";
- $class = isset($attr['class']) ? $attr['class'] : "";
- $main_class = "column-1";
- switch ($width) {
-
- case "1/2":
- $main_class = "column-12";
- break;
-
- case "1/3":
- $main_class = "column-13";
- break;
-
- case "1/4":
- $main_class = "column-14";
- break;
-
- case "1/6":
- $main_class = "column-16";
- break;
-
- case "2/3":
- $main_class = "column-23";
- break;
-
- case "3/4":
- $main_class = "column-34";
- break;
-
- case "5/6":
- $main_class = "column-56";
- break;
-
- case "1":
- default:
- $main_class = "column-1";
- break;
- }
- return "<div class='short-columns $main_class $class'>".$content."</div>";
-}
-
-/**
- * Pullquotes
- * Uses [mantra-pullquote] to create pullquotes
- * Attributes:
- * "align" - optional - alignment of the pullquote itself - values: left / center /right
- * "width" - optional - whatever you want it to be in percenatage (ex:50%)
- * "textalign" - optional - alignment of text inside the pullquote - values: left / center / right
- * Example of use:
- * [mantra-pullquote align="right" width="40%" textalign="center"] Look at this beautiful text right here [/mantra-pullquote]
- */
-
-function mantra_pullquote_fn( $atts, $content = NULL, $code = '' ) {
- if ( ! $content ) return;
-
- $style = array();
-
- $class = array( 'pullquote', 'align' => 'alignleft' );
-
- if ( $atts ) {
- if ( array_key_exists( 'align', $atts ) ) {
- if ( in_array( $atts['align'], array( 'left', 'center', 'right' ) ) )
- $class['align'] = 'align' . $atts['align'];
- if ( $atts['align'] == 'center' ) $style['text-align'] = 'center';
- }
-
- if ( array_key_exists( 'width', $atts ) ) {
- if ( $atts['width'] ) $style['width'] = trim( $atts['width'] );
- }
-
- if ( array_key_exists( 'textalign', $atts ) ) {
- if ( in_array( $atts['textalign'], array( 'left', 'center', 'right' ) ) )
- $style['text-align'] = $atts['textalign'];
- }
- }
-
- $style_attr = '';
- if ( $style ) {
- foreach ( $style as $prop => $val ) {
- $style_attr .= $prop . ':' . $val . ';';
- }
- if ( $style_attr ) $style_attr = ' style="' . $style_attr . '"';
- }
-
- $attr = 'class="' . implode( ' ', $class ) . '"' . $style_attr;
-
- return '<div ' . $attr . '>' . wpautop( do_shortcode( $content ) ) . '</div>';
-}
-
-
-/**
- * Buttons
- * Uses [mantra-button-light], [mantra-button-dark] and [mantra-button-color] to create buttons.
- * Attributes:
- * "url" - optional - the link the button will send you to.
- * "color" - optional - only for the color button. The hexadecimal value of the color you need.
- * Example of use:
- * [mantra-button-light url="http://www.google.com"] More info [/mantra-button-light]
- * Or:
- * [mantra-button-color url="http://www.google.com" color="32F43A"] Color info [/mantra-button-color]
- */
-
-function mantra_button_light_fn($attr ,$content) {
- if (!isset($attr['url'])) $attr['url'] = '#';
- if (!isset($attr['target'])) $attr['target'] = "_blank";
- return '<a class="short-button-light" target="'.$attr['target'].'" href="'.$attr['url'].'" title="'.$content.'" >'.$content.'</a>';
-}
-
-function mantra_button_dark_fn($attr ,$content) {
- if (!isset($attr['url'])) $attr['url'] = '#';
- if (!isset($attr['target'])) $attr['target'] = "_blank";
- return '<a class="short-button-dark" target="'.$attr['target'].'" href="'.$attr['url'].'" title="'.$content.'" >'.$content.'</a>';
-}
-
-function mantra_button_color_fn($attr ,$content) {
- if (!isset($attr['url'])) $attr['url'] = '#';
- if (!isset($attr['target'])) $attr['target'] = "_blank";
- $style="";
- if (isset($attr["color"])) { $style=' style="background-color:'.$attr["color"].'"'; }
- return '<a class="short-button-color" target="'.$attr['target'].'"'.$style.' href="'.$attr['url'].'" title="'.$content.'" >'.$content.'</a>';
-}
-
-/**
- * Hooking the shortcode buttons to the TinyMCE editor
- */
-class mantra_shortcodes_buttons{
-
- function mantra_shortcodes_buttons(){
- if ( current_user_can( 'edit_posts' ) && current_user_can( 'edit_pages' ) ) {
- add_filter( 'mce_external_plugins', array(&$this, 'mantra_add_plugin' ) );
- add_filter( 'mce_buttons_2', array(&$this, 'mantra_add_button' ) );
- }
- }
-
- function mantra_add_button( $buttons ){
- array_push( $buttons, "separator", "button-light", "button-dark", "button-color", "separator", "pullquote", "separator", "multi-column");
- return $buttons;
- }
-
- function mantra_add_plugin( $plugin_array ){
- $plugin_array['mantrashortcodes'] = get_template_directory_uri() . '/js/mce-shortcodes.js';
- return $plugin_array;
- }
-}
-add_action( 'init', 'mantra_shortcodes_buttons' );
-
-function mantra_shortcodes_buttons(){
- global $mantra_shortcodes_buttons;
- $mantra_shortcodes_buttons = new mantra_shortcodes_buttons();
-}
-
-
-?>
\ No newline at end of file diff --git a/themes/mantra/includes/theme-styles.php b/themes/mantra/includes/theme-styles.php index b19e8687..430c5a06 100644 --- a/themes/mantra/includes/theme-styles.php +++ b/themes/mantra/includes/theme-styles.php @@ -10,10 +10,9 @@ function mantra_mobile_meta() {
global $mantra_options;
-foreach ($mantra_options as $key => $value) {
- ${"$key"} = $value ;
- }
- return '<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0">';
+if ($mantra_options['mantra_zoom'] == 1)
+ return '<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1.0, minimum-scale=1.0, maximum-scale=3.0">';
+else return '<meta name="viewport" content="width=device-width, user-scalable=no, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0">';
}
diff --git a/themes/mantra/js/buttons/button-color.png b/themes/mantra/js/buttons/button-color.png Binary files differdeleted file mode 100644 index e69892f1..00000000 --- a/themes/mantra/js/buttons/button-color.png +++ /dev/null diff --git a/themes/mantra/js/buttons/button-dark.png b/themes/mantra/js/buttons/button-dark.png Binary files differdeleted file mode 100644 index 4d322e6a..00000000 --- a/themes/mantra/js/buttons/button-dark.png +++ /dev/null diff --git a/themes/mantra/js/buttons/button-light.png b/themes/mantra/js/buttons/button-light.png Binary files differdeleted file mode 100644 index 29c074a3..00000000 --- a/themes/mantra/js/buttons/button-light.png +++ /dev/null diff --git a/themes/mantra/js/buttons/multi-column.png b/themes/mantra/js/buttons/multi-column.png Binary files differdeleted file mode 100644 index 5a87f612..00000000 --- a/themes/mantra/js/buttons/multi-column.png +++ /dev/null diff --git a/themes/mantra/js/buttons/pullquote.png b/themes/mantra/js/buttons/pullquote.png Binary files differdeleted file mode 100644 index 4f7465b9..00000000 --- a/themes/mantra/js/buttons/pullquote.png +++ /dev/null diff --git a/themes/mantra/js/mce-shortcodes.js b/themes/mantra/js/mce-shortcodes.js deleted file mode 100644 index ddea6b76..00000000 --- a/themes/mantra/js/mce-shortcodes.js +++ /dev/null @@ -1,59 +0,0 @@ -/**
- * Adding buttons to the the mce menu for the main short codes
- * @package mantra
- *
- */
-(function() {
- // Load plugin specific language pack
- tinymce.PluginManager.requireLangPack('mantrashortcodes');
-
- tinymce.create('tinymce.plugins.mantraShortCodes', {
- init : function(ed, url) {
-
- ed.addButton('button-light', {
- title : ed.getLang('mantrashortcodes.buttonlighttitle', 'Add a light button'),
- image : url+'/buttons/button-light.png',
- onclick : function() {
- ed.selection.setContent('[cryout-button-light url="#"]' + ed.selection.getContent() + '[/cryout-button-light]');
- }
- });
-
- ed.addButton('button-dark', {
- title : ed.getLang('mantrashortcodes.buttondarktitle', 'Add a dark button'),
- image : url+'/buttons/button-dark.png',
- onclick : function() {
- ed.selection.setContent('[cryout-button-dark url="#"]' + ed.selection.getContent() + '[/cryout-button-dark]');
- }
- });
-
- ed.addButton('button-color', {
- title : ed.getLang('mantrashortcodes.buttoncolortitle', 'Add a color button'),
- image : url+'/buttons/button-color.png',
- onclick : function() {
- ed.selection.setContent('[cryout-button-color url="#" color="#47AFFF"]' + ed.selection.getContent() + '[/cryout-button-color]');
- }
- });
-
- ed.addButton('pullquote', {
- title : ed.getLang('mantrashortcodes.pullquotetitle', 'Add a pullquote'),
- image : url + '/buttons/pullquote.png',
- onclick : function() {
- ed.selection.setContent('[cryout-pullquote align="left|center|right" textalign="left|center|right" width="33%"]' + ed.selection.getContent() + '[/cryout-pullquote]');
- }
- });
-
- ed.addButton('multi-column', {
- title : ed.getLang('mantrashortcodes.multicolumntitle', 'Add multiple columns'),
- image : url + '/buttons/multi-column.png',
- onclick : function() {
- ed.selection.setContent('[cryout-multi][cryout-column width="1/4"] [/cryout-column] [cryout-column width="1/2"]' + ed.selection.getContent() + '[/cryout-column] [cryout-column width="1/4"] [/cryout-column] [/cryout-multi]');
- }
- });
-
- },
- createControl : function(n, cm) {
- return null;
- },
- });
- tinymce.PluginManager.add('mantrashortcodes', tinymce.plugins.mantraShortCodes);
-})();
\ No newline at end of file diff --git a/themes/mantra/rtl.css b/themes/mantra/rtl.css index e2fceabc..3f2046cf 100644 --- a/themes/mantra/rtl.css +++ b/themes/mantra/rtl.css @@ -16,6 +16,11 @@ body { float:left;
}
+ol {margin-left:0;margin-right:1.5em;}
+
+.entry-content ul > li {padding-left:0;padding-right:20px;}
+.entry-content ul, .entry-summary ul {margin-right:0;}
+
/*
LAYOUT: Two-Column (Right)
DESCRIPTION: Two-column fixed layout with one sidebar right of content
@@ -157,7 +162,7 @@ margin-right:0; }
#content ul > li {
-background-position:right 10px;
+ background-position: right 10px;
}
.entry-title,
@@ -166,6 +171,15 @@ background-position:right 10px; float: right;
}
+.entry-meta {
+ width: 100%;
+ -webkit-box-sizing:border-box;
+ -moz-box-sizing:border-box;
+ box-sizing:border-box;
+}
+
+.entry-meta .comments-link {float: left;}
+
#content .format-status .entry-meta2 {
clear:left;
float:right;
@@ -182,6 +196,9 @@ float:right; padding-left:3px;
}
+.entry-meta2 .edit-link, .entry-meta3 .edit-link, .edit-link {
+ float: left;
+}
.entry-meta span .bl_sep, .entry-meta2 span .bl_sep {
float: left ;
@@ -233,6 +250,18 @@ margin-left:10px; margin: 0 104px 0 0;
}
+.continue-reading-link {
+ display:inline-block;
+}
+
+.continue-reading-link .meta-nav {
+ display:inline-block;
+ float:left;
+ -webkit-transform:rotate(180deg);
+ -moz-transform:rotate(180deg);
+ transform:rotate(180deg);
+}
+
.sticky hgroup {
background: url("images/icon-featured.png") no-repeat scroll right 10px transparent;
padding-right: 35px;
@@ -242,6 +271,15 @@ margin-left:10px; float:right;
}
+article.format-link, article.format-quote, article.format-image, article.format-chat, article.format-aside {
+ background-position: right 10px;
+}
+
+article.format-link header, article.format-quote header, article.format-image header, article.format-chat header, article.format-aside header {
+ padding-left: 0;
+ padding-right: 60px;
+}
+
#respond label {
float:right;
@@ -284,7 +322,7 @@ text-align:right; }
#content .entry-title {
-float:none;
+ float:none;
}
/* =Navigation
@@ -297,6 +335,10 @@ float:none; text-align:left;
}
+.theme-default .nivo-controlNav {
+ direction:ltr;
+}
+
/* =Comments
-------------------------------------------------------------- */
diff --git a/themes/mantra/style.css b/themes/mantra/style.css index 90952faa..50fa6423 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.3.4
+ * Version: 2.4.1.1
* 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
@@ -14,6 +14,17 @@ */
+/*
+IMPORTANT!
+
+Any changes made to this or any other of the theme's files will be lost at the next update.
+
+To safely make customizations to the theme, for CSS-only consider using the theme's dedicated
+"Custom CSS" field found under the Miscellaneous section of the theme settings page;
+for advanced CSS and other customizations, consider using a child theme.
+*/
+
+
/* =Reset default browser CSS. Based on work by Eric Meyer: http://meyerweb.com/eric/tools/css/reset/index.html
-------------------------------------------------------------- */
@@ -305,13 +316,13 @@ hr { margin-bottom:1.5em;
}
-.entry-content ul>li {
+.entry-content ul > li {
background: url(images/bullet.png) left 10px no-repeat;
- padding-left:20px;
+ padding-left: 20px;
}
.entry-content li li {
- margin-left:15px;
+ margin-left: 15px;
}
ol {
@@ -823,7 +834,6 @@ font-size:1.9em; margin-left:0px;
padding-left:4px;
display:inline;
- float:left;
font-size:14px;
color:#666 !important;
text-decoration:underline;
@@ -1218,6 +1228,8 @@ article.format-chat h3.entry-format, article.format-aside h3.entry-format { disp -moz-box-sizing:border-box;
box-sizing:border-box;
}
+#content table img {
+ max-width: initial; }
#content img:hover {
@@ -1822,11 +1834,17 @@ background:#AAA; margin:4px 0;
}
+.widget-area {
+ font-size: 14px;
+ line-height: 1.5;
+}
+
.widget-area a:link,
.widget-area a:visited {
text-decoration: none;
color:#0D85CC;
font-size:14px;
+ line-height: 1.5;
word-wrap:break-word;
}
.widget-area a:active,
@@ -2348,6 +2366,24 @@ background:#FAFAFA; font-weight:bold;
}
+.slider-navhover .nivo-directionNav a.nivo-prevNav,
+.slider-navhover .nivo-directionNav a.nivo-nextNav {
+ -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=0)";
+ filter: alpha(opacity=0);
+ opacity: 0;
+ -webkit-transition: .3s all ease-in-out;
+ -moz-transition: .3s all ease-in-out;
+ -o-transition: .3s all ease-in-out;
+ transition: .3s all ease-in-out;
+}
+
+.slider-navhover:hover .nivo-directionNav a.nivo-prevNav,
+.slider-navhover:hover .nivo-directionNav a.nivo-nextNav {
+ -ms-filter:"progid:DXImageTransform.Microsoft.Alpha(Opacity=90)";
+ filter: alpha(opacity=90);
+ opacity: 0.9;
+}
+
/*
Skin Name: Nivo Slider Default Theme
Skin URI: http://nivo.dev7studios.com
|