Example #1
0
 public function getMetaBox()
 {
     $this->createMetabox(array('id' => MAX_SHORTNAME . '_post_sidebar_metabox', 'title' => __('Sidebar Settings', MAX_SHORTNAME), 'priority' => "default", 'context' => 'side'));
     // get the custom sidebars and make a dropdown array
     $_sidebar_option_array = get_option_max('sidebar_array');
     $_dropdown_array = array('false' => __('Default or no Sidebar', MAX_SHORTNAME));
     if (is_array($_sidebar_option_array)) {
         foreach ($_sidebar_option_array as $sidebar_value) {
             $_s = explode(',', $sidebar_value);
             $_dropdown_array[$_s[1]] = $_s[0];
         }
     }
     // Sidebar select
     $this->addDropdown(array('id' => MAX_SHORTNAME . '_sidebar_select', 'label' => __('Choose a Sidebar', MAX_SHORTNAME), "options" => $_dropdown_array, "standard" => "false", "desc" => __('Select a sidebar to show on this page or post, when a sidebar is provided for this post or page template. You can create as many sidebars as you like on your Invictus theme settings.', MAX_SHORTNAME)));
 }
function gallery_register()
{
    $labels = array('name' => _x('Photos', 'post type general name', MAX_SHORTNAME), 'singular_name' => _x('Photo', 'post type singular name', MAX_SHORTNAME), 'add_new' => _x('Add New', 'gallery', MAX_SHORTNAME), 'add_new_item' => __('Add A New Photo to a Gallery', MAX_SHORTNAME), 'edit_item' => __('Edit Photo', MAX_SHORTNAME), 'new_item' => __('New Photo', MAX_SHORTNAME), 'view_item' => __('View Photo', MAX_SHORTNAME), 'search_items' => __('Search Photos', MAX_SHORTNAME), 'not_found' => __('No Photos found', MAX_SHORTNAME), 'not_found_in_trash' => __('No Photos found in Trash', MAX_SHORTNAME), 'parent_item_colon' => '', 'menu_name' => 'Photos');
    // rewrite option for permalinks on custom post-type
    $option_rewrite_pt = get_option_max('rewrite_posttype');
    $rewrite_posttype = !empty($option_rewrite_pt) ? array('slug' => $option_rewrite_pt) : true;
    $args = array('labels' => $labels, 'public' => true, 'show_ui' => true, 'publicly_queryable' => true, 'capability_type' => 'post', 'supports' => array('thumbnail', 'excerpt', 'comments', 'editor', 'title', 'revisions', 'author', 'custom-fields', 'page-attributes'), 'taxonomies' => array('post_tag'), 'menu_position' => 55, 'query_var' => true, 'rewrite' => $rewrite_posttype, 'menu_icon' => 'dashicons-format-gallery');
    register_post_type('gallery', $args);
    $gal_labels = array('name' => _x('Galleries', 'taxonomy general name', MAX_SHORTNAME), 'singular_name' => _x('Gallery', 'taxonomy singular name', MAX_SHORTNAME), 'search_items' => __('Search Galleries', MAX_SHORTNAME), 'popular_items' => __('Popular Galleries', MAX_SHORTNAME), 'all_items' => __('All Galleries', MAX_SHORTNAME), 'parent_item' => null, 'parent_item_colon' => null, 'edit_item' => __('Edit Galleries', MAX_SHORTNAME), 'update_item' => __('Update Galleries', MAX_SHORTNAME), 'add_new_item' => __('Add New Gallery', MAX_SHORTNAME), 'new_item_name' => __('New Gallery Name', MAX_SHORTNAME), 'separate_items_with_commas' => __('Separate galleries with commas', MAX_SHORTNAME), 'add_or_remove_items' => __('Add or remove Galleries', MAX_SHORTNAME), 'choose_from_most_used' => __('Choose from the most used Galleries', MAX_SHORTNAME), 'menu_name' => __('Galleries', MAX_SHORTNAME));
    add_post_type_support('gallery', 'thumbnail');
    // rewrite option for permalinks on taxonomy
    $option_rewrite_tax = get_option_max('rewrite_taxonomy');
    $rewrite_taxonomy = !empty($option_rewrite_tax) ? array('slug' => $option_rewrite_tax) : true;
    // register new taxonomy
    register_taxonomy(GALLERY_TAXONOMY, "gallery", array("hierarchical" => true, "label" => __('Galleries', MAX_SHORTNAME), "singular_label" => __('Gallery', MAX_SHORTNAME), "labels" => $gal_labels, "rewrite" => $rewrite_taxonomy));
}
Example #3
0
 function max_widgets_init()
 {
     $before_title = '<h2 class="widget-title">';
     $after_title = '</h2>';
     $before_widget = '<aside id="%1$s" class="widget %2$s">';
     $after_widget = '</aside>';
     $_sidebar_array = array(array("id" => "blog", "name" => __('Blog Sidebar', MAX_SHORTNAME), "description" => __('Blog Sidebar Widget Area', MAX_SHORTNAME)), array("id" => "homepage", "name" => __('Homepage Sidebar', MAX_SHORTNAME), "description" => __('Homepage Widget Area', MAX_SHORTNAME)), array("id" => "blog-post", "name" => __('Blog Post Sidebar', MAX_SHORTNAME), "description" => __('Blog Post Sidebar Widget Area', MAX_SHORTNAME)), array("id" => "gallery-project", "name" => __('Gallery Project Page Sidebar', MAX_SHORTNAME), "description" => __('Gallery Project Page Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-sortable", "name" => __('Gallery Sortable Sidebar', MAX_SHORTNAME), "description" => __('Gallery Sortable Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-four", "name" => __('Gallery 4 Column Sidebar', MAX_SHORTNAME), "description" => __('Gallery 4 Column Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-three", "name" => __('Gallery 3 Column Sidebar', MAX_SHORTNAME), "description" => __('Gallery 3 Column Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-two", "name" => __('Gallery 2 Column Sidebar', MAX_SHORTNAME), "description" => __('Gallery 2 Column Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-one", "name" => __('Gallery 1 Column Sidebar', MAX_SHORTNAME), "description" => __('Gallery 1 Column Template Widget Area', MAX_SHORTNAME)), array("id" => "tag", "name" => __('Tag Sidebar', MAX_SHORTNAME), "description" => __('Tag Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-flickr", "name" => __('Gallery Flickr Sidebar', MAX_SHORTNAME), "description" => __('Gallery Flickr Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-galleria", "name" => __('Galleria Template Sidebar', MAX_SHORTNAME), "description" => __('Galleria Template Widget Area', MAX_SHORTNAME)), array("id" => "gallery-taxonomy", "name" => __('Gallery Taxonomy Sidebar', MAX_SHORTNAME), "description" => __('Gallery Taxonomy Template Widget Area', MAX_SHORTNAME)), array("id" => "main", "name" => __('Sidebar left Template Sidebar', MAX_SHORTNAME), "description" => __('Sidebar for Custom Template with left sidebar', MAX_SHORTNAME)), array("id" => "search-result", "name" => __('Sidebar Search Result', MAX_SHORTNAME), "description" => __('Sidebar for Search results with left sidebar', MAX_SHORTNAME)), array("id" => "archive-result", "name" => __('Sidebar Archive', MAX_SHORTNAME), "description" => __('Sidebar for Archive with left sidebar', MAX_SHORTNAME)), array("id" => "contact", "name" => __('Sidebar Contact', MAX_SHORTNAME), "description" => __('Sidebar for Contact page with left sidebar', MAX_SHORTNAME)), array("id" => "fullsize-gallery", "name" => __('Sidebar Fullsize Gallery', MAX_SHORTNAME), "description" => __('Sidebar for fullsize gallery templates', MAX_SHORTNAME)), array("id" => "fullsize-video", "name" => __('Sidebar Fullsize Video', MAX_SHORTNAME), "description" => __('Sidebar for fullsize video templates', MAX_SHORTNAME)), array("id" => "fullsize-flickr", "name" => __('Sidebar Fullsize Flickr', MAX_SHORTNAME), "description" => __('Sidebar for fullsize flickr templates', MAX_SHORTNAME)), array("id" => "gallery-lightbox", "name" => __('Sidebar Lightbox Gallery', MAX_SHORTNAME), "description" => __('Sidebar for lightbox gallery templates', MAX_SHORTNAME)));
     // get the custom sidebars and make a dropdown array
     $_sidebar_option_array = get_option_max('sidebar_array');
     if (is_array($_sidebar_option_array)) {
         foreach ($_sidebar_option_array as $sidebar_value) {
             $_s = explode(',', $sidebar_value);
             $_sidebar_array[] = array("id" => $_s[1], "name" => $_s[0], "description" => "");
         }
     }
     // Loop array with sidebars
     foreach ($_sidebar_array as $index => $value) {
         register_sidebar(array('name' => $value['name'], 'id' => "sidebar-" . $value['id'], 'description' => $value['description'], 'before_widget' => $before_widget, 'after_widget' => $after_widget, 'before_title' => $before_title, 'after_title' => $after_title));
     }
 }
Example #4
0
    max_get_the_excerpt(true);
    ?>
</h2>
		<?php 
}
?>

		<?php 
if (has_post_thumbnail($post->ID)) {
    $image = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'single-post-thumbnail');
    $imageFull = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'full');
    $img_excerpt = get_the_excerpt();
    $img_title = get_the_title();
    $img_alt = get_the_title();
    // check wether to choose image or post meta informations on the lightbox
    if (get_option_max('general_use_image_meta') == 'true') {
        // get the meta from the image information on the media library
        $img_title = get_post_field('post_title', get_post_thumbnail_id());
        $img_excerpt = get_post_field('post_excerpt', get_post_thumbnail_id());
    }
    ?>

			<div class="entry-image">
			<a href="<?php 
    echo $imageFull[0];
    ?>
" data-rel="prettyPhoto" data-link="<?php 
    get_permalink($post_id);
    ?>
" title="<?php 
    echo strip_tags($img_excerpt);
Example #5
0
 function max_add_styles()
 {
     if (!is_admin()) {
         if (get_option_max("pretty_enable_lightbox", 'false') == 'false') {
             wp_enqueue_style('prettyphoto', get_template_directory_uri() . '/js/prettyPhoto/prettyPhoto.css', false, false);
         }
         wp_enqueue_style('responsive', get_template_directory_uri() . '/css/responsive.css', false, false);
         wp_enqueue_style('custom', get_template_directory_uri() . '/css/custom.css', false, false);
         wp_enqueue_style('headers', get_template_directory_uri() . '/css/headers.css', false, false);
         wp_enqueue_style('fontawesome', get_template_directory_uri() . '/css/fonts/font-awesome.min.css', array(), '3.0.2');
         if (get_option_max('menu_mega_menu', 'false') === 'true') {
             wp_enqueue_style('megamenu', get_template_directory_uri() . '/css/megamenu.css', false, MAX_VERSION);
         }
         // load galleria only on galleria page templates
         if (is_page_template('template-galleria.php')) {
             wp_enqueue_style('galleria-css', get_template_directory_uri() . '/js/galleria/galleria.classic.css', false, false);
         }
         // get the color file
         if (!MAX_DEMO_MODE) {
             wp_enqueue_style('color-main', get_template_directory_uri() . '/css/' . get_option_max('color_main', 'black') . '.css', false, MAX_VERSION);
         }
     }
 }
Example #6
0
		<div id="content" role="main">

			<header class="entry-header">

				<h1 class="page-title"><?php 
single_tag_title();
?>
</h1>

			</header><!-- .entry-header -->

			<?php 
// Only get gallery posts
if ($post_type == "gallery") {
    $tag_posts = query_posts(array('tag' => get_query_var('tag'), 'post_type' => 'gallery', 'paged' => $paged, 'order' => get_option_max('photo_post_archive_sorting')));
}
// Only get blog posts
if ($post_type == "post") {
    $tag_posts = query_posts(array('tag' => get_query_var('tag'), 'post_type' => 'post', 'paged' => $paged));
}
if ($post_type == "gallery") {
    // including the loop template tag-loop.inc.php
    get_template_part('includes/tag', 'loop.inc');
}
if ($post_type == "post") {
    // including the loop template blog-loop.inc.php
    get_template_part('includes/blog', 'loop.inc');
}
?>
Example #7
0
 function max_add_fullwidth_body_class($classes)
 {
     global $meta;
     @($custom_fields = get_post_custom_values('_wp_page_template', $post_id));
     $page_template = $custom_fields[0];
     // check if we have a full-width nav and fill content is activated
     $classes[] = 'fill-content-' . get_option_max("layout_fill_content", 'false');
     if (isset($meta[MAX_SHORTNAME . "_page_gallery_fullwidth"]) && $meta[MAX_SHORTNAME . "_page_gallery_fullwidth"] == 'true' || $page_template == 'template-sidebar-fullwidth.php' || $page_template == 'template-fullwidth-no-sidebar.php' || $page_template == 'template-facebook-gallery.php') {
         $classes[] = 'fullwidth-content';
     }
     return $classes;
 }
Example #8
0
            ?>

			<ol class="commentlist">
				<?php 
            /* Loop through and list the comments. Tell wp_list_comments()
             * to use max_comment() to format the comments.
             * If you want to overload this in a child theme then you can
             * define max_comment() and that will be used instead.
             * See max_comment() in doitmax_fw/max_comments.php for more.
             */
            wp_list_comments(array('callback' => 'max_comment'));
            ?>
			</ol>

<?php 
            if (get_comment_pages_count() > 1 && get_option_max('page_comments')) {
                // Are there comments to navigate through?
                ?>
			<div class="navigation">
				<div class="nav-previous"><?php 
                previous_comments_link(__('<span class="meta-nav">&larr;</span> Older Comments', MAX_SHORTNAME));
                ?>
</div>
				<div class="nav-next"><?php 
                next_comments_link(__('Newer Comments <span class="meta-nav">&rarr;</span>', MAX_SHORTNAME));
                ?>
</div>
			</div><!-- .navigation -->
<?php 
            }
            // check for comment navigation
Example #9
0
									<?php 
                        echo '<span class="excerpt">' . strip_tags(get_the_excerpt()) . '</span>';
                        ?>
									<?php 
                    }
                    ?>
								</div>
							</figcaption>

						<?php 
                }
            }
            ?>

						<?php 
            if (get_option_max('image_always_lightbox') == 'true') {
                ?>
						<a href="<?php 
                the_permalink();
                ?>
" class="hover-link-icon"><?php 
                _e('Link to detail page', MAX_SHORTNAME);
                ?>
</a>
						<?php 
            }
            ?>

					</figure>

					<?php 
Example #10
0
        echo get_the_title();
        ?>
 | <?php 
        echo get_bloginfo('name');
        ?>
" class="twitter-share-button" data-lang="en" data-url="<?php 
        echo get_permalink($post->ID);
        ?>
">Tweet</a>
			</div>
			<?php 
    }
    ?>

			<?php 
    if (get_option_max("post_social_google") == 'true') {
        // check if google+ should be shown
        ?>
			<!-- Google+ -->
			<div class="share-button share-google-plus">
				<script type="text/javascript" src="https://apis.google.com/js/plusone.js"></script>
				<g:plusone size="medium" href="<?php 
        echo get_permalink($post->ID);
        ?>
"></g:plusone>
			</div>
			<?php 
    }
    ?>

		</div>
Example #11
0
 */
global $meta, $post, $post_meta;
$meta = max_get_cutom_meta_array(get_the_ID());
$no_hover = get_option_max('image_show_fade') == 'false' ? ' no-hover' : "";
?>


<!--BEGIN slider -->
<div id="slider-<?php 
echo get_the_id();
?>
" class="slides-slider page-slider" data-loader="<?php 
echo get_template_directory_uri();
?>
/css/<?php 
echo get_option_max('color_main');
?>
/loading.gif">

	<?php 
$_temp_meta['imgID'] = get_post_thumbnail_id($post->ID);
if (function_exists('has_post_thumbnail') && has_post_thumbnail()) {
    ?>
	<div class="slide<?php 
    echo $no_hover;
    ?>
">
	<?php 
    max_get_slider_image($_temp_meta, 'slides-slider', 0, false, false, false);
    ?>
	</div>
Example #12
0
  /* <![CDATA[ */
  var splashvar = { 'theme': '<?php 
echo MAX_SHORTNAME;
?>
', 'cookieset': <?php 
echo get_option_max('splash_cookie_set');
?>
, 'cookieexpires' : <?php 
echo get_option_max('splash_cookie_expires');
?>
, 'fadeout': <?php 
echo $autohide;
?>
, 'timeout': <?php 
echo get_option_max('splash_timeout');
?>
, 'fade': <?php 
echo get_option_max('splash_fade');
?>
, 'logowidth' : <?php 
echo $logo_width;
?>
, 'logoheight' : <?php 
echo $logo_height;
?>
, 'enter_text' : '<?php 
echo $enter_text;
?>
' };
  /* ]]> */
  </script>
Example #13
0
// check if there is a excerpt
if (get_option_max('fullsize_featured_text') != '' && $show_fullsize_title == 'true') {
    ?>
				<h2 class="page-description"><?php 
    echo get_option_max('fullsize_featured_text');
    ?>
</h2>
				<?php 
}
?>

			</header>
		</div>

	</div>

	<?php 
// Check if Homepage Sidebar is activated
if (get_option_max('homepage_show_homepage_sidebar') == 'true') {
    /* Get the sidebar if we have set one - otherwise show nothing at all */
    $sidebar_string = max_get_custom_sidebar('sidebar-homepage');
    /* get the custom or default sidebar name */
    // include the sidebar.php template
    get_sidebar();
}
?>

</div>

<?php 
get_footer();
Example #14
0
function googlemap_shortcode($atts)
{
    extract(shortcode_atts(array('width' => '500px', 'height' => '300px', 'apikey' => get_option_max("general_google_map_api"), 'marker' => '', 'center' => '', 'zoom' => '13'), $atts));
    if ($center) {
        $setCenter = 'map.setCenter(new GLatLng(' . $center . '), ' . $zoom . ');';
    }
    if ($marker) {
        $setMarker = 'map.addOverlay(new GMarker(new GLatLng(' . $marker . ')));';
    }
    $rand = rand(1, 100) * rand(1, 100);
    return '
		<div id="map_canvas_' . $rand . '" class="google_maps_canvas"></div>
		<script src="http://maps.google.com/maps?file=api&amp;v=2&amp;sensor=false&amp;key=' . $apikey . '" type="text/javascript"></script>

	    <script type="text/javascript">
		    function initialize() {
		      if (GBrowserIsCompatible()) {
		        var map = new GMap2(document.getElementById("map_canvas_' . $rand . '"));
		        ' . $setCenter . '
		        ' . $setMarker . '
		        map.setUIToDefault();
		      }
		    }
		    initialize();
	    </script>
    ';
}
Example #15
0
 function max_login_logo_url($url)
 {
     if (get_option_max('admin_login_logo_url')) {
         return esc_url(get_option_max('admin_login_logo_url'));
     } else {
         return $url;
     }
 }
                    if( $showtitle.size() && $branding.size() ){
                      var collision = checkTitleLeftMargin( $showtitle, $branding );
                      if( collision ) {
                        if( !$showtitle.hasClass('showtitle-left-margin') ) $showtitle.addClass('showtitle-left-margin');
                      }else{
                        if( $showtitle.hasClass('showtitle-left-margin') ) $showtitle.removeClass('showtitle-left-margin');
                      }
                    }

                  })
  							<?php 
    }
    ?>

  							<?php 
    if (get_option_max('fullsize_show_title_excerpt') == 'true') {
        ?>
  							if(window.videoUrl.excerpt != ""){
  								jQuery('#showtitle span.imagecaption')
  									.html( window.videoUrl.excerpt ).removeClass('hidden');
  							}else{
  								jQuery('#showtitle span.imagecaption').addClass('hidden');
  							}
  							<?php 
    }
    ?>

                /* change full size gallery title links
                 *
                 * @desc  Shows lightbox videos in a full size gallery
                 * @since Invictus 3.0
Example #17
0
    }
    private function load_curl($url)
    {
        $curl = curl_init($url);
        curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
        $result = curl_exec($curl);
        curl_close($curl);
        return $result;
    }
}
// it's enabled so use the cool stuff
define('FONT_THEME_NAME', MAX_THEMENAME);
// The theme name
define('FONT_CACHE_INTERVAL', 604800);
// Checking once a week for new Fonts. The time interval for the remote XML cache in the database (21600 seconds = 6 hours)
define('FONT_API_KEY', get_option_max('google_fontapi_key'));
// The font api key
$google_font_array = array("Abel" => "Abel:regular", "Abril Fatface" => "Abril+Fatface:400", "Aclonica" => "Aclonica:regular", "Acme" => "Acme:400", "Actor" => "Actor:regular", "Adamina" => "Adamina:400", "Aguafina Script" => "Aguafina+Script:400", "Aladin" => "Aladin:400", "Aldrich" => "Aldrich:regular", "Alegreya" => "Alegreya:400,400italic,700,700italic,900,900italic", "Alegreya SC" => "Alegreya+SC:400,400italic,700,700italic,900,900italic", "Alex Brush" => "Alex+Brush:400", "Alfa Slab One" => "Alfa+Slab+One:400", "Alice" => "Alice:regular", "Alike" => "Alike:regular", "Alike Angular" => "Alike+Angular:regular", "Allan" => "Allan:bold", "Allerta" => "Allerta:regular", "Allerta Stencil" => "Allerta+Stencil:regular", "Almendra" => "Almendra:400,bold", "Almendra SC" => "Almendra+SC:400", "Amaranth" => "Amaranth:regular,400italic,700,700italic", "Amatic SC" => "Amatic+SC:400,700", "Amethysta" => "Amethysta:400", "Andada" => "Andada:400", "Andika" => "Andika:regular", "Angkor" => "Angkor:regular", "Annie Use Your Telescope" => "Annie+Use+Your+Telescope:regular", "Anonymous Pro" => "Anonymous+Pro:regular,italic,bold,bolditalic", "Antic" => "Antic:400", "Anton" => "Anton:regular", "Arapey" => "Arapey:400,400italic", "Arbutus" => "Arbutus:400", "Architects Daughter" => "Architects+Daughter:regular", "Arimo" => "Arimo:regular,italic,bold,bolditalic", "Arizonia" => "Arizonia:400", "Armata" => "Armata:400", "Artifika" => "Artifika:regular", "Arvo" => "Arvo:regular,italic,bold,bolditalic", "Asap" => "Asap:400,400italic,700,700italic", "Asset" => "Asset:regular", "Astloch" => "Astloch:regular,bold", "Asul" => "Asul:400,bold", "Atomic Age" => "Atomic+Age:400", "Aubrey" => "Aubrey:regular", "Bad Script" => "Bad+Script:400", "Balthazar" => "Balthazar:400", "Bangers" => "Bangers:regular", "Basic" => "Basic:400", "Battambang" => "Battambang:regular,bold", "Baumans" => "Baumans:400", "Bayon" => "Bayon:regular", "Belgrano" => "Belgrano:400", "Bentham" => "Bentham:regular", "Bevan" => "Bevan:regular", "Bigshot One" => "Bigshot+One:regular", "Bilbo" => "Bilbo:400", "Bilbo Swash Caps" => "Bilbo+Swash+Caps:400", "Bitter" => "Bitter:400,400italic,700", "Black Ops One" => "Black+Ops+One:regular", "Bokor" => "Bokor:regular", "Bonbon" => "Bonbon:400", "Boogaloo" => "Boogaloo:regular", "Bowlby One" => "Bowlby+One:regular", "Bowlby One SC" => "Bowlby+One+SC:regular", "Brawler" => "Brawler:regular", "Bree Serif" => "Bree+Serif:400", "Bubblegum Sans" => "Bubblegum+Sans:400", "Buda" => "Buda:300", "Buenard" => "Buenard:400,bold", "Butcherman" => "Butcherman:400", "Cabin" => "Cabin:400,400italic,500,500italic,600,600italic,bold,bolditalic", "Cabin Condensed" => "Cabin+Condensed:400,500,600,700", "Cabin Sketch" => "Cabin+Sketch:regular,bold", "Caesar Dressing" => "Caesar+Dressing:400", "Cagliostro" => "Cagliostro:400", "Calligraffitti" => "Calligraffitti:regular", "Cambo" => "Cambo:400", "Candal" => "Candal:regular", "Cantarell" => "Cantarell:regular,italic,bold,bolditalic", "Cardo" => "Cardo:regular,400italic,700", "Carme" => "Carme:regular", "Carter One" => "Carter+One:regular", "Caudex" => "Caudex:400,italic,700,700italic", "Cedarville Cursive" => "Cedarville+Cursive:regular", "Ceviche One" => "Ceviche+One:400", "Changa One" => "Changa+One:regular,italic", "Chango" => "Chango:400", "Chelsea Market" => "Chelsea+Market:400", "Chenla" => "Chenla:regular", "Cherry Cream Soda" => "Cherry+Cream+Soda:regular", "Chewy" => "Chewy:regular", "Chicle" => "Chicle:400", "Chivo" => "Chivo:400,400italic,900,900italic", "Coda" => "Coda:400,800", "Coda Caption" => "Coda+Caption:800", "Comfortaa" => "Comfortaa:300,400,700", "Coming Soon" => "Coming+Soon:regular", "Concert One" => "Concert+One:400", "Condiment" => "Condiment:400", "Content" => "Content:regular,bold", "Contrail One" => "Contrail+One:regular", "Convergence" => "Convergence:400", "Cookie" => "Cookie:400", "Copse" => "Copse:regular", "Corben" => "Corben:400,bold", "Cousine" => "Cousine:regular,italic,bold,bolditalic", "Coustard" => "Coustard:400,900", "Covered By Your Grace" => "Covered+By+Your+Grace:regular", "Crafty Girls" => "Crafty+Girls:regular", "Creepster" => "Creepster:regular", "Crete Round" => "Crete+Round:400,400italic", "Crimson Text" => "Crimson+Text:regular,400italic,600,600italic,700,700italic", "Crushed" => "Crushed:regular", "Cuprum" => "Cuprum:regular", "Damion" => "Damion:regular", "Dancing Script" => "Dancing+Script:regular,bold", "Dangrek" => "Dangrek:regular", "Dawning of a New Day" => "Dawning+of+a+New+Day:regular", "Days One" => "Days+One:400", "Delius" => "Delius:400", "Delius Swash Caps" => "Delius+Swash+Caps:400", "Delius Unicase" => "Delius+Unicase:400,700", "Devonshire" => "Devonshire:400", "Didact Gothic" => "Didact+Gothic:regular", "Diplomata" => "Diplomata:400", "Diplomata SC" => "Diplomata+SC:400", "Dorsa" => "Dorsa:400", "Dr Sugiyama" => "Dr+Sugiyama:400", "Droid Sans" => "Droid+Sans:regular,bold", "Droid Sans Mono" => "Droid+Sans+Mono:regular", "Droid Serif" => "Droid+Serif:regular,italic,bold,bolditalic", "Duru Sans" => "Duru+Sans:400", "Dynalight" => "Dynalight:400", "EB Garamond" => "EB+Garamond:regular", "Eater" => "Eater:400", "Electrolize" => "Electrolize:400", "Emblema One" => "Emblema+One:400", "Engagement" => "Engagement:400", "Enriqueta" => "Enriqueta:400,700", "Esteban" => "Esteban:400", "Expletus Sans" => "Expletus+Sans:400,400italic,500,500italic,600,600italic,700,700italic", "Fanwood Text" => "Fanwood+Text:400,400italic", "Fascinate" => "Fascinate:400", "Fascinate Inline" => "Fascinate+Inline:400", "Federant" => "Federant:400", "Federo" => "Federo:regular", "Fjord One" => "Fjord+One:400", "Flamenco" => "Flamenco:300,400", "Flavors" => "Flavors:400", "Fondamento" => "Fondamento:400,400italic", "Fontdiner Swanky" => "Fontdiner+Swanky:regular", "Forum" => "Forum:regular", "Francois One" => "Francois+One:regular", "Fredericka the Great" => "Fredericka+the+Great:regular", "Freehand" => "Freehand:regular", "Fresca" => "Fresca:400", "Frijole" => "Frijole:400", "Fugaz One" => "Fugaz+One:400", "GFS Didot" => "GFS+Didot:regular", "GFS Neohellenic" => "GFS+Neohellenic:regular,italic,bold,bolditalic", "Galdeano" => "Galdeano:400", "Gentium Basic" => "Gentium+Basic:regular,italic,bold,bolditalic", "Gentium Book Basic" => "Gentium+Book+Basic:regular,italic,bold,bolditalic", "Geo" => "Geo:regular", "Geostar" => "Geostar:regular", "Geostar Fill" => "Geostar+Fill:regular", "Germania One" => "Germania+One:400", "Give You Glory" => "Give+You+Glory:regular", "Glegoo" => "Glegoo:400", "Gloria Hallelujah" => "Gloria+Hallelujah:regular", "Goblin One" => "Goblin+One:regular", "Gochi Hand" => "Gochi+Hand:400", "Goudy Bookletter 1911" => "Goudy+Bookletter+1911:regular", "Gravitas One" => "Gravitas+One:regular", "Gruppo" => "Gruppo:regular", "Gudea" => "Gudea:400,italic,bold", "Habibi" => "Habibi:400", "Hammersmith One" => "Hammersmith+One:regular", "Handlee" => "Handlee:400", "Hanuman" => "Hanuman:regular,bold", "Herr Von Muellerhoff" => "Herr+Von+Muellerhoff:400", "Holtwood One SC" => "Holtwood+One+SC:regular", "Homemade Apple" => "Homemade+Apple:regular", "Homenaje" => "Homenaje:400", "IM Fell DW Pica" => "IM+Fell+DW+Pica:regular,italic", "IM Fell DW Pica SC" => "IM+Fell+DW+Pica+SC:regular", "IM Fell Double Pica" => "IM+Fell+Double+Pica:regular,italic", "IM Fell Double Pica SC" => "IM+Fell+Double+Pica+SC:regular", "IM Fell English" => "IM+Fell+English:regular,italic", "IM Fell English SC" => "IM+Fell+English+SC:regular", "IM Fell French Canon" => "IM+Fell+French+Canon:regular,italic", "IM Fell French Canon SC" => "IM+Fell+French+Canon+SC:regular", "IM Fell Great Primer" => "IM+Fell+Great+Primer:regular,italic", "IM Fell Great Primer SC" => "IM+Fell+Great+Primer+SC:regular", "Iceberg" => "Iceberg:400", "Iceland" => "Iceland:400", "Inconsolata" => "Inconsolata:regular", "Inder" => "Inder:400", "Indie Flower" => "Indie+Flower:regular", "Inika" => "Inika:400,bold", "Irish Grover" => "Irish+Grover:regular", "Istok Web" => "Istok+Web:400,400italic,700,700italic", "Italianno" => "Italianno:400", "Jim Nightshade" => "Jim+Nightshade:400", "Jockey One" => "Jockey+One:400", "Josefin Sans" => "Josefin+Sans:100,100italic,300,300italic,400,400italic,600,600italic,700,700italic", "Josefin Slab" => "Josefin+Slab:100,100italic,300,300italic,400,400italic,600,600italic,700,700italic", "Judson" => "Judson:400,400italic,700", "Julee" => "Julee:regular", "Junge" => "Junge:400", "Jura" => "Jura:300,400,500,600", "Just Another Hand" => "Just+Another+Hand:regular", "Just Me Again Down Here" => "Just+Me+Again+Down+Here:regular", "Kameron" => "Kameron:400,700", "Kaushan Script" => "Kaushan+Script:400", "Kelly Slab" => "Kelly+Slab:regular", "Kenia" => "Kenia:regular", "Khmer" => "Khmer:regular", "Knewave" => "Knewave:400", "Kotta One" => "Kotta+One:400", "Koulen" => "Koulen:regular", "Kranky" => "Kranky:regular", "Kreon" => "Kreon:300,400,700", "Kristi" => "Kristi:regular", "La Belle Aurore" => "La+Belle+Aurore:regular", "Lancelot" => "Lancelot:400", "Lato" => "Lato:100,100italic,300,300italic,400,400italic,700,700italic,900,900italic", "League Script" => "League+Script:400", "Leckerli One" => "Leckerli+One:regular", "Lekton" => "Lekton:400,italic,700", "Lemon" => "Lemon:400", "Lilita One" => "Lilita+One:400", "Limelight" => "Limelight:regular", "Linden Hill" => "Linden+Hill:400,400italic", "Lobster" => "Lobster:regular", "Lobster Two" => "Lobster+Two:400,400italic,700,700italic", "Lora" => "Lora:regular,italic,bold,bolditalic", "Love Ya Like A Sister" => "Love+Ya+Like+A+Sister:regular", "Loved by the King" => "Loved+by+the+King:regular", "Luckiest Guy" => "Luckiest+Guy:regular", "Lusitana" => "Lusitana:400,bold", "Lustria" => "Lustria:400", "Macondo" => "Macondo:400", "Macondo Swash Caps" => "Macondo+Swash+Caps:400", "Magra" => "Magra:400,bold", "Maiden Orange" => "Maiden+Orange:regular", "Mako" => "Mako:regular", "Marck Script" => "Marck+Script:400", "Marko One" => "Marko+One:400", "Marmelad" => "Marmelad:400", "Marvel" => "Marvel:400,400italic,700,700italic", "Mate" => "Mate:400,400italic", "Mate SC" => "Mate+SC:400", "Maven Pro" => "Maven+Pro:400,500,700,900", "Meddon" => "Meddon:regular", "MedievalSharp" => "MedievalSharp:regular", "Medula One" => "Medula+One:400", "Megrim" => "Megrim:regular", "Merienda One" => "Merienda+One:regular", "Merriweather" => "Merriweather:300,regular,700,900", "Metal" => "Metal:regular", "Metamorphous" => "Metamorphous:400", "Metrophobic" => "Metrophobic:regular", "Michroma" => "Michroma:regular", "Miltonian" => "Miltonian:regular", "Miltonian Tattoo" => "Miltonian+Tattoo:regular", "Miniver" => "Miniver:400", "Miss Fajardose" => "Miss+Fajardose:400", "Modern Antiqua" => "Modern+Antiqua:regular", "Molengo" => "Molengo:regular", "Monofett" => "Monofett:regular", "Monoton" => "Monoton:400", "Monsieur La Doulaise" => "Monsieur+La+Doulaise:400", "Montaga" => "Montaga:400", "Montez" => "Montez:regular", "Montserrat" => "Montserrat:400", "Moul" => "Moul:regular", "Moulpali" => "Moulpali:regular", "Mountains of Christmas" => "Mountains+of+Christmas:regular,700", "Mr Bedfort" => "Mr+Bedfort:400", "Mr Dafoe" => "Mr+Dafoe:400", "Mr De Haviland" => "Mr+De+Haviland:400", "Mrs Saint Delafield" => "Mrs+Saint+Delafield:400", "Mrs Sheppards" => "Mrs+Sheppards:400", "Muli" => "Muli:300,300italic,400,400italic", "Neucha" => "Neucha:regular", "Neuton" => "Neuton:200,300,regular,italic,700,800", "News Cycle" => "News+Cycle:regular", "Niconne" => "Niconne:regular", "Nixie One" => "Nixie+One:regular", "Nobile" => "Nobile:regular,italic,bold,bolditalic", "Nokora" => "Nokora:400,700", "Nosifer" => "Nosifer:400", "Nothing You Could Do" => "Nothing+You+Could+Do:regular", "Noticia Text" => "Noticia+Text:400,400italic,700,700italic", "Nova Cut" => "Nova+Cut:regular", "Nova Flat" => "Nova+Flat:regular", "Nova Mono" => "Nova+Mono:regular", "Nova Oval" => "Nova+Oval:regular", "Nova Round" => "Nova+Round:regular", "Nova Script" => "Nova+Script:regular", "Nova Slim" => "Nova+Slim:regular", "Nova Square" => "Nova+Square:regular", "Numans" => "Numans:400", "Nunito" => "Nunito:300,400,700", "Odor Mean Chey" => "Odor+Mean+Chey:regular", "Old Standard TT" => "Old+Standard+TT:regular,italic,bold", "Oldenburg" => "Oldenburg:400", "Open Sans" => "Open+Sans:300,300italic,400,400italic,600,600italic,700,700italic,800,800italic", "Open Sans Condensed" => "Open+Sans+Condensed:300,300italic", "Orbitron" => "Orbitron:400,500,700,900", "Original Surfer" => "Original+Surfer:400", "Oswald" => "Oswald:regular", "Over the Rainbow" => "Over+the+Rainbow:regular", "Overlock" => "Overlock:400,400italic,700,700italic,900,900italic", "Overlock SC" => "Overlock+SC:400", "Ovo" => "Ovo:regular", "PT Sans" => "PT+Sans:regular,italic,bold,bolditalic", "PT Sans Caption" => "PT+Sans+Caption:regular,bold", "PT Sans Narrow" => "PT+Sans+Narrow:regular,bold", "PT Serif" => "PT+Serif:regular,italic,bold,bolditalic", "PT Serif Caption" => "PT+Serif+Caption:regular,italic", "Pacifico" => "Pacifico:regular", "Parisienne" => "Parisienne:400", "Passero One" => "Passero+One:regular", "Passion One" => "Passion+One:400,700,900", "Patrick Hand" => "Patrick+Hand:regular", "Patua One" => "Patua+One:400", "Paytone One" => "Paytone+One:regular", "Permanent Marker" => "Permanent+Marker:regular", "Petrona" => "Petrona:400", "Philosopher" => "Philosopher:regular,italic,bold,bolditalic", "Piedra" => "Piedra:400", "Pinyon Script" => "Pinyon+Script:regular", "Plaster" => "Plaster:400", "Play" => "Play:regular,bold", "Playball" => "Playball:400", "Playfair Display" => "Playfair+Display:regular,400italic", "Podkova" => "Podkova:regular,700", "Poller One" => "Poller+One:regular", "Poly" => "Poly:400,400italic", "Pompiere" => "Pompiere:regular", "Port Lligat Sans" => "Port+Lligat+Sans:400", "Port Lligat Slab" => "Port+Lligat+Slab:400", "Prata" => "Prata:400", "Preahvihear" => "Preahvihear:regular", "Prociono" => "Prociono:400", "Puritan" => "Puritan:regular,italic,bold,bolditalic", "Quantico" => "Quantico:400,400italic,700,700italic", "Quattrocento" => "Quattrocento:regular", "Quattrocento Sans" => "Quattrocento+Sans:regular", "Questrial" => "Questrial:400", "Quicksand" => "Quicksand:300,400,700", "Qwigley" => "Qwigley:400", "Radley" => "Radley:regular,400italic", "Raleway" => "Raleway:100", "Rammetto One" => "Rammetto+One:400", "Rancho" => "Rancho:400", "Rationale" => "Rationale:regular", "Redressed" => "Redressed:regular", "Reenie Beanie" => "Reenie+Beanie:regular", "Ribeye" => "Ribeye:400", "Ribeye Marrow" => "Ribeye+Marrow:400", "Righteous" => "Righteous:400", "Rochester" => "Rochester:regular", "Rock Salt" => "Rock+Salt:regular", "Rokkitt" => "Rokkitt:regular,700", "Ropa Sans" => "Ropa+Sans:400,400italic", "Rosario" => "Rosario:regular,italic,700,700italic", "Rouge Script" => "Rouge+Script:400", "Ruda" => "Ruda:400,bold,900", "Ruge Boogie" => "Ruge+Boogie:400", "Ruluko" => "Ruluko:400", "Ruslan Display" => "Ruslan+Display:regular", "Ruthie" => "Ruthie:400", "Sail" => "Sail:400", "Salsa" => "Salsa:400", "Sancreek" => "Sancreek:400", "Sansita One" => "Sansita+One:regular", "Sarina" => "Sarina:400", "Satisfy" => "Satisfy:400", "Schoolbell" => "Schoolbell:regular", "Shadows Into Light" => "Shadows+Into+Light:regular", "Shanti" => "Shanti:regular", "Shojumaru" => "Shojumaru:400", "Short Stack" => "Short+Stack:400", "Siemreap" => "Siemreap:regular", "Sigmar One" => "Sigmar+One:regular", "Signika" => "Signika:300,400,600,700", "Signika Negative" => "Signika+Negative:300,400,600,700", "Sirin Stencil" => "Sirin+Stencil:400", "Six Caps" => "Six+Caps:regular", "Slackey" => "Slackey:regular", "Smokum" => "Smokum:regular", "Smythe" => "Smythe:regular", "Sniglet" => "Sniglet:800", "Snippet" => "Snippet:regular", "Sofia" => "Sofia:400", "Sonsie One" => "Sonsie+One:400", "Sorts Mill Goudy" => "Sorts+Mill+Goudy:400,400italic", "Special Elite" => "Special+Elite:regular", "Spicy Rice" => "Spicy+Rice:400", "Spinnaker" => "Spinnaker:regular", "Spirax" => "Spirax:400", "Squada One" => "Squada+One:400", "Stardos Stencil" => "Stardos+Stencil:regular,bold", "Stint Ultra Condensed" => "Stint+Ultra+Condensed:400", "Stoke" => "Stoke:400", "Sue Ellen Francisco" => "Sue+Ellen+Francisco:regular", "Sunshiney" => "Sunshiney:regular", "Supermercado One" => "Supermercado+One:400", "Suwannaphum" => "Suwannaphum:regular", "Swanky and Moo Moo" => "Swanky+and+Moo+Moo:regular", "Syncopate" => "Syncopate:regular,bold", "Tangerine" => "Tangerine:regular,bold", "Taprom" => "Taprom:regular", "Telex" => "Telex:400", "Tenor Sans" => "Tenor+Sans:regular", "Terminal Dosis" => "Terminal+Dosis:200,300,400,500,600,700,800", "The Girl Next Door" => "The+Girl+Next+Door:regular", "Tienne" => "Tienne:400,700,900", "Tinos" => "Tinos:regular,italic,bold,bolditalic", "Titan One" => "Titan+One:400", "Trade Winds" => "Trade+Winds:400", "Trochut" => "Trochut:400,italic,bold", "Trykker" => "Trykker:400", "Tulpen One" => "Tulpen+One:regular", "Ubuntu" => "Ubuntu:300,300italic,regular,italic,500,500italic,bold,bolditalic", "Ubuntu Condensed" => "Ubuntu+Condensed:400", "Ubuntu Mono" => "Ubuntu+Mono:regular,italic,bold,bolditalic", "Ultra" => "Ultra:regular", "Uncial Antiqua" => "Uncial+Antiqua:400", "UnifrakturCook" => "UnifrakturCook:bold", "UnifrakturMaguntia" => "UnifrakturMaguntia:regular", "Unkempt" => "Unkempt:regular,700", "Unlock" => "Unlock:regular", "Unna" => "Unna:regular", "VT323" => "VT323:regular", "Varela" => "Varela:regular", "Varela Round" => "Varela+Round:regular", "Vast Shadow" => "Vast+Shadow:regular", "Vibur" => "Vibur:regular", "Vidaloka" => "Vidaloka:400", "Viga" => "Viga:400", "Volkhov" => "Volkhov:400,400italic,700,700italic", "Vollkorn" => "Vollkorn:regular,italic,bold,bolditalic", "Voltaire" => "Voltaire:400", "Waiting for the Sunrise" => "Waiting+for+the+Sunrise:regular", "Wallpoet" => "Wallpoet:regular", "Walter Turncoat" => "Walter+Turncoat:regular", "Wellfleet" => "Wellfleet:400", "Wire One" => "Wire+One:regular", "Yanone Kaffeesatz" => "Yanone+Kaffeesatz:200,300,400,700", "Yellowtail" => "Yellowtail:regular", "Yeseva One" => "Yeseva+One:regular", "Yesteryear" => "Yesteryear:400", "Zeyada" => "Zeyada:regular");
// Only get fonts, if you have an API key set
if (FONT_API_KEY != "") {
    // get cached fields
    $db_cache_field = 'googlefont-cache';
    $db_cache_field_last_updated = 'googlefont-cache-last-updated';
    $db_cache_field_themename = 'googlefont-cache-' . MAX_SHORTNAME;
    $current_fonts = get_option($db_cache_field);
    $content = get_option($db_cache_field);
    $last = get_option($db_cache_field_last_updated);
    $theme = get_option($db_cache_field_themename);
    // get current timestamp
    $now = time();
    if (ini_get('allow_url_fopen') === true || function_exists('curl_init')) {
Example #18
0
/*--------------------------------------------------------------------------*/
register_nav_menus(array('primary' => __('Primary Navigation', MAX_SHORTNAME), 'footer-navigation' => __('Footer Navigation', MAX_SHORTNAME)));
/*--------------------------------------------------------------------------*/
/*	Get our wp_nav_menu() fallback, wp_page_menu(), to show a home link.
/*--------------------------------------------------------------------------*/
function max_page_menu_args($args)
{
    $args['show_home'] = true;
    return $args;
}
add_filter('wp_page_menu_args', 'max_page_menu_args');
/*--------------------------------------------------------------------------*/
/*	Build the WP Navigation Menues
/*--------------------------------------------------------------------------*/
$max_show_mega_menus = get_option_max('menu_mega_menu', false);
$max_navigation_type = get_option_max('header_type', false);
if ($max_show_mega_menus === 'true' && $max_navigation_type !== 'full-height') {
    // Initialize the new mega menu
    require_once MAX_FW_PATH . '/mega_menu/max_mega_menu_framework.php';
    function max_create_theme_menu()
    {
        global $max_main_menu;
        if (has_nav_menu('primary')) {
            $max_main_menu = wp_nav_menu(array('theme_location' => 'primary', 'menu_class' => 'nav max-navbar-nav sf-menu', 'container' => false, 'items_wrap' => '%3$s', 'fallback_cb' => 'MaxFrameFrontendWalker::fallback', 'walker' => new MaxFrameFrontendWalker(), 'echo' => false));
        }
    }
} else {
    // Get the old menu instead
    function max_create_theme_menu()
    {
        global $max_main_menu;
Example #19
0
    }
    ?>
	</nav><!-- #navigation -->
	<?php 
}
?>

</header><!-- #branding -->

<?php 
// Check if we are on the main front page Welcome teaser should be shown
if ($main_homepage === true && get_option_max('homepage_show_welcome_teaser') == 'true') {
    $welcome = stripslashes(get_option_max('homepage_welcome_teaser'));
    ?>
	<div id="welcomeTeaser"<?php 
    if (get_option_max('mobile_show_welcome_teaser', 'false') == 'true') {
        ?>
 class="show-teaser"<?php 
    }
    ?>
><span class="inner"><?php 
    echo $welcome;
    ?>
</span></div>
<?php 
}
?>

<div id="page">

	<div id="main" class="clearfix zIndex">
Example #20
0
				// initialize SuperBGImage
				$('#superbgimage').superbgimage().hide();

			});

		</script>

  <?php 
    }
}
?>

  <?php 
// Get Google Analyric Code if set in options menu
$google_id = get_option_max('google_analytics_id');
if (!empty($google_id)) {
    // including the google anylytics template google-analytics.inc.php
    get_template_part('includes/google', 'analytic.inc');
}
?>
  <?php 
wp_footer();
?>

  <script type='text/javascript' src='http://a.vimeocdn.com/js/froogaloop2.min.js'></script>

  <?php 
if (!empty($post)) {
    // get infinite scroll JS if needed
    $infinite_scroll_meta = get_post_meta($post->ID, MAX_SHORTNAME . '_page_infinite_scroll', TRUE);
				total_slides			: <?php 
    echo $meta['max_fullsize_flickr_total_slides'];
    ?>
, //How many pictures to pull (Between 1-500)
				image_size    			: '<?php 
    echo $meta['max_fullsize_flickr_image_size'];
    ?>
', //Flickr Image Size - t,s,m,z,b  (Details: http://www.flickr.com/services/api/misc.urls.html)
				slides 					: [{}],	//Initiate slides array

				/**
	    		FLICKR API KEY
	    		NEED TO GET YOUR OWN -- http://www.flickr.com/services/apps/create/
	    		**/
				api_key					: '<?php 
    echo get_option_max("flickr_api_key");
    ?>
' //Flickr API Key

			});

			// place the prev and next thumb bottom to the colophons height
			jQuery('#controls-wrapper').css({ bottom: jQuery('#colophon').outerHeight() });

			jQuery('body').addClass('fullsize-gallery fullsize-gallery-flickr');
		});

	</script>
<?php 
}
get_footer();
Example #22
0
										<?php 
        // check if blog should be shown full
        if (get_option_max('general_show_fullblog') == 'true') {
            the_content();
        } else {
            the_excerpt();
        }
        ?>
										</div><!-- .entry-content -->

									</div>

									<footer>
										<?php 
        // check if blog should be shown full
        if (get_option_max('general_show_fullblog') != 'true') {
            ?>
										<br />
										<p class="read-more"><a href="<?php 
            the_permalink();
            ?>
" title="<?php 
            echo __('Continue Reading...', 'invictus');
            ?>
" class="more-link"><?php 
            echo __('Continue Reading...', 'invictus');
            ?>
</a></p>
										<?php 
        }
        ?>
Example #23
0
    public function getMetaBox()
    {
        global $cropping_array;
        $this->createMetabox(array('id' => MAX_SHORTNAME . '_blog_settings_meta_box', 'title' => __('Post Settings', MAX_SHORTNAME), 'priority' => "high"));
        // Photo item type
        $this->addDropdown(array('id' => MAX_SHORTNAME . "_photo_item_type_value", 'label' => __('Show a video?', MAX_SHORTNAME), 'options' => array('none' => 'No video', 'selfhosted' => __('Self hosted video', MAX_SHORTNAME), 'youtube_embed' => __('YouTube embedded video', MAX_SHORTNAME), 'vimeo_embed' => __('Vimeo embedded video', MAX_SHORTNAME)), 'standard' => "lightbox"));
        /*-----------------------------------------------------------------------------------*/
        /* Embeded Video Options */
        /*-----------------------------------------------------------------------------------*/
        $this->addGroupOpen(array("id" => MAX_SHORTNAME . '_photo_group_embeded', "dependency" => MAX_SHORTNAME . '_photo_item_type_value::{contains}embed', "display" => false));
        /** Embedded Code **/
        $this->addTextarea(array("id" => MAX_SHORTNAME . "_video_embeded_value", "label" => __('Embed-Code', MAX_SHORTNAME), "display" => true, "rows" => '8', "size" => "480", "standard" => "", "desc" => __('If you want to embed a video on the photo details page, paste the embed code here. The recommend width is ' . MAX_CONTENT_WIDTH . 'px with any height to fit the content dimensions. <strong>Add "?wmode=transparent" to the URL in your embeded code to avoid content overlapping.</strong>', MAX_SHORTNAME)));
        $this->addGroupClose(array("id" => MAX_SHORTNAME . '_photo_group_embeded_close'));
        /*-----------------------------------------------------------------------------------*/
        /*	Self hosted video options
        		/*-----------------------------------------------------------------------------------*/
        $this->addGroupOpen(array("id" => MAX_SHORTNAME . '_photo_group_selfhosted', "dependency" => MAX_SHORTNAME . '_photo_item_type_value::selfhosted', "display" => false));
        // Video H.264 Url
        $this->addInput(array("id" => MAX_SHORTNAME . "_video_url_m4v_value", "label" => __('H.264 File URL (required)', MAX_SHORTNAME), "size" => 640, "display" => true, "desc" => __('The URL of your self hosted H.264 video file ( .mp4, .m4v, .f4v ). This file is required to make your video run in all browsers!', MAX_SHORTNAME), "standard" => ""));
        // Video Url OGV
        $this->addInput(array("id" => MAX_SHORTNAME . "_video_url_ogv_value", "label" => __('OGV File URL (required)', MAX_SHORTNAME), "size" => 640, "display" => true, "desc" => __('The URL of your self hosted OGG Theora video file ( .ogg, .ogv ). This file is required to make your video run in all browsers!', MAX_SHORTNAME), "standard" => ""));
        // Photo link taregt
        $this->addDropdown(array("id" => MAX_SHORTNAME . '_video_poster_value', "label" => __('Video preview image', MAX_SHORTNAME), "options" => array('featured' => "Post featured image", 'url' => "Image URL"), "standard" => 'featured', "desc" => __('Choose image you want to use for your video preview. This picture is displayed when the video was not played yet.', MAX_SHORTNAME)));
        // Video Preview url
        $this->addInput(array("id" => MAX_SHORTNAME . "_video_url_poster_value", "label" => __('Video preview image URL', MAX_SHORTNAME), "size" => 640, "display" => false, "dependency" => MAX_SHORTNAME . '_video_poster_value::url', "desc" => __('The URL of your video preview image file.', MAX_SHORTNAME)));
        // Video Height
        $this->addSlider(array("id" => MAX_SHORTNAME . "_video_height_value", "label" => __('Video Height', MAX_SHORTNAME), "max" => 1000, "min" => 1, "step" => 1, "standard" => "529", "desc" => __('The height the size of your videos depends on a wide of 940px. This height is important to make the video look good in all browsers and on all devices.', MAX_SHORTNAME)));
        // Autoplay Video on page ready
        $this->addDropdown(array("id" => MAX_SHORTNAME . '_video_fill_value', "label" => __('Stretching', MAX_SHORTNAME), "options" => array('none' => __('None', MAX_SHORTNAME), 'fill' => __('Fill', MAX_SHORTNAME), 'excactfit' => __('Exactfit', MAX_SHORTNAME), 'uniform' => __('Uniform', MAX_SHORTNAME)), "standard" => 'fill', "desc" => __('Stretching defines how to resize the poster image and video to fit the display. <a href="#" onclick="jQuery(\'#strechInfo\').toggle(); return false;">Show detailed information</a>', MAX_SHORTNAME) . '
											<ul id="strechInfo" style="display: none; font-size: 11px; padding: 10px; background: #eee; margin: 10px 0 0">
											<li><strong>None</strong>: keep the original dimensions.</li>
											<li><strong>Exactfit</strong>: disproportionally stretch the video/image to exactly fit the display.</li>
											<li><strong>Uniform</strong>: stretch the image/video while maintaining its aspect ratio. There\'ll be black borders.</li>
											<li><strong>Fill</strong>: stretch the image/video while maintaining its aspect ratio, completely filling the display.</li>
											</ul>'));
        // Autoplay Video on page ready
        $this->addDropdown(array("id" => MAX_SHORTNAME . '_video_autoplay_value', 'label' => __('Autoplay video', MAX_SHORTNAME), "options" => array('true' => __('Yes', MAX_SHORTNAME), 'false' => __('No', MAX_SHORTNAME)), "standard" => 'false', "desc" => __('If set to "Yes", your video will automatically start on page load.', MAX_SHORTNAME)));
        $this->addGroupClose(array("id" => MAX_SHORTNAME . '_photo_group_selfhosted_close'));
        // Featured image cropping direction
        $this->addDropdown(array('id' => MAX_SHORTNAME . '_photo_cropping_direction_value', 'label' => __('Preview cropping direction', MAX_SHORTNAME), "options" => $cropping_array, "standard" => "c", "desc" => __('Choose the position from where your thumbnail of an image will be cropped if cropping is activated in your Invictus Theme Settings.', MAX_SHORTNAME)));
        // Show Fullsize Background Image
        $this->addDropdown(array('id' => 'max_show_page_fullsize', 'label' => __('Show fullsize background image', MAX_SHORTNAME), "options" => array('true' => 'Yes', 'false' => 'No'), "standard" => "true", "desc" => __('Choose, if you want to show a Fullsize Background Image for this gallery page.', MAX_SHORTNAME)));
        /** Fullsize Background Group **/
        $this->addGroupOpen(array("id" => MAX_SHORTNAME . '_photo_fullsizeshow_group', "dependency" => 'max_show_page_fullsize::true', "display" => false));
        // get default background option from theme options
        $default_background = get_option_max('general_blog_background_default');
        $default_galleries = get_option_max('general_blog_background_galleries');
        $std_max_show_page_fullsize_type = !empty($default_background) ? $default_background : "single";
        $std_max_show_page_gallery = !empty($default_galleries) ? $default_galleries : "9999";
        //** Fullsize Background Slideshow
        $this->addDropdown(array('id' => 'max_show_page_fullsize_type', 'label' => __('Type of fullsize background', MAX_SHORTNAME), "options" => array("single" => __('Single Image', MAX_SHORTNAME), "slideshow" => __('Slideshow from Gallery', MAX_SHORTNAME), 'default' => __('Default Theme Option', MAX_SHORTNAME)), "standard" => $std_max_show_page_fullsize_type, "desc" => __('Do you want to show a single image or a slideshow from the gallery the photo is attached to for your background on this page. If this set to "Default Theme Option", you have to set the default type at the "Blog" tab of your Invictus theme settings.', MAX_SHORTNAME)));
        /** Fullsize Background Slideshow **/
        $this->addGroupOpen(array("id" => MAX_SHORTNAME . '_photo_fullsizeslideshow_group', "dependency" => 'max_show_page_fullsize_type::slideshow', "display" => false));
        // Choose the galleries to display
        $this->addMultiGalleryCheckbox(array('id' => 'max_show_page_fullsize_gallery', 'label' => __('Available Galleries', MAX_SHORTNAME), "standard" => $std_max_show_page_gallery, "options" => 'gallery', "desc" => __('Choose the Galleries, the single background image or the slideshow images are drawn from.', MAX_SHORTNAME)));
        // slideshow speed
        $this->addSlider(array('id' => 'max_show_page_fullsize_interval', "standard" => 3500, "max" => 20000, "min" => 500, "step" => 50, "label" => __('Slideshow Interval', MAX_SHORTNAME), "desc" => __('Enter the slideshow interval for the fullsize background in milliseconds (ms).', MAX_SHORTNAME)));
        $this->addGroupClose(array("id" => MAX_SHORTNAME . '_photo_fullsizeslideshow_group_close'));
        //** Fullsize Background URL for Photo posts
        $this->addInput(array("id" => MAX_SHORTNAME . "_show_page_fullsize_url", "label" => __('URL for Fullsize Background Image', MAX_SHORTNAME), "size" => 640, "display" => false, "dependency" => MAX_SHORTNAME . '_show_random_fullsize_value::false', "standard" => "", "desc" => __('Leave blank to show the current featured image as background', MAX_SHORTNAME), "dependency" => 'max_show_page_fullsize_type::single', "display" => false));
        $this->addGroupClose(array("id" => MAX_SHORTNAME . '_photo_fullsizeshow_group_close'));
    }
Example #24
0
function max_get_google_font_html()
{
    // get the fonts
    $body_font = get_option_max('font_body');
    $widget_font = get_option_max('font_widget');
    $nav_font = get_option_max('font_navigation');
    $pulldown_font = get_option_max('font_navigation_pulldown');
    $fsg_title_font = get_option_max('font_fullsize_title');
    $fsg_excerpt_font = get_option_max('font_fullsize_excerpt');
    $welcome_teaser_font = get_option_max('font_welcome_teaser');
    $blog_font = get_option_max('font_blog_header');
    $font_array = array($body_font['font_family'], $widget_font['font_family'], $nav_font['font_family'], $pulldown_font['font_family'], $blog_font['font_family']);
    $_google_fonts = array();
    for ($h = 1; $h <= 6; $h++) {
        $_google_fonts['h' . $h] = get_option_max('font_h' . $h);
    }
    foreach ($_google_fonts as $get_google_font) {
        // get the headline font
        $_temp_font_array[] = $get_google_font['font_family'];
    }
    // combine both arrays
    $get_fonts = array_merge($font_array, $_temp_font_array);
    // Main Color styles
    ?>
<style type="text/css">

	body.black-theme,
	body.white-theme  {
		font: <?php 
    echo $body_font['font_size'];
    ?>
px/<?php 
    echo $body_font['line_height'];
    ?>
px <?php 
    echo max_get_font_string($body_font['font_family']);
    ?>
; font-weight: <?php 
    echo $body_font['font_weight'];
    ?>
;
		color: <?php 
    echo $body_font['font_color'];
    ?>
	}

	#showtitle, #slidecaption, #responsiveTitle  {
		font-family: <?php 
    echo max_get_font_string($_google_fonts['h1']['font_family']) . ', "Helvetica Neue", Helvetica, Arial, sans-serif';
    ?>
;
		font-weight: 300;
	}

	nav#navigation ul li a {
		color: <?php 
    echo $nav_font['font_color'];
    ?>
; font: <?php 
    echo $nav_font['font_size'];
    ?>
px/<?php 
    echo $nav_font['line_height'];
    ?>
px <?php 
    echo max_get_font_string($nav_font['font_family']);
    ?>
; font-weight: <?php 
    echo $nav_font['font_weight'];
    ?>
	}

	nav#navigation ul ul.sub-menu li a  {
		color: <?php 
    echo $pulldown_font['font_color'];
    ?>
; font: <?php 
    echo $pulldown_font['font_size'];
    ?>
px/<?php 
    echo $pulldown_font['line_height'];
    ?>
px <?php 
    echo max_get_font_string($pulldown_font['font_family']);
    ?>
; font-weight: <?php 
    echo $pulldown_font['font_weight'];
    ?>
	}

	h1, h1 a:link, h1 a:visited { color: <?php 
    echo $_google_fonts['h1']['font_color'];
    ?>
; font: <?php 
    echo $_google_fonts['h1']['font_size'];
    ?>
px/<?php 
    echo $_google_fonts['h1']['line_height'];
    ?>
px <?php 
    echo max_get_font_string($_google_fonts['h1']['font_family']);
    ?>
; font-weight: <?php 
    echo $_google_fonts['h1']['font_weight'];
    ?>
; }
	h2 { color: <?php 
    echo $_google_fonts['h2']['font_color'];
    ?>
; font: <?php 
    echo $_google_fonts['h2']['font_size'];
    ?>
px/<?php 
    echo $_google_fonts['h2']['line_height'];
    ?>
px <?php 
    echo max_get_font_string($_google_fonts['h2']['font_family']);
    ?>
; font-weight: <?php 
    echo $_google_fonts['h2']['font_weight'];
    ?>
; }
	h3 { color: <?php 
    echo $_google_fonts['h3']['font_color'];
    ?>
; font: <?php 
    echo $_google_fonts['h3']['font_size'];
    ?>
px/<?php 
    echo $_google_fonts['h3']['line_height'];
    ?>
px <?php 
    echo max_get_font_string($_google_fonts['h3']['font_family']);
    ?>
; font-weight: <?php 
    echo $_google_fonts['h3']['font_weight'];
    ?>
; }
	h4 { color: <?php 
    echo $_google_fonts['h4']['font_color'];
    ?>
; font: <?php 
    echo $_google_fonts['h4']['font_size'];
    ?>
px/<?php 
    echo $_google_fonts['h4']['line_height'];
    ?>
px <?php 
    echo max_get_font_string($_google_fonts['h4']['font_family']);
    ?>
; font-weight: <?php 
    echo $_google_fonts['h4']['font_weight'];
    ?>
; }
	h5 { color: <?php 
    echo $_google_fonts['h5']['font_color'];
    ?>
; font: <?php 
    echo $_google_fonts['h5']['font_size'];
    ?>
px/<?php 
    echo $_google_fonts['h5']['line_height'];
    ?>
px <?php 
    echo max_get_font_string($_google_fonts['h5']['font_family']);
    ?>
; font-weight: <?php 
    echo $_google_fonts['h5']['font_weight'];
    ?>
; }
	h6 { color: <?php 
    echo $_google_fonts['h6']['font_color'];
    ?>
; font: <?php 
    echo $_google_fonts['h6']['font_size'];
    ?>
px/<?php 
    echo $_google_fonts['h6']['line_height'];
    ?>
px <?php 
    echo max_get_font_string($_google_fonts['h6']['font_family']);
    ?>
; font-weight:  <?php 
    echo $_google_fonts['h6']['font_weight'];
    ?>
; }


	#sidebar h1.widget-title, #sidebar h2.widget-title {
		color: <?php 
    echo $widget_font['font_color'];
    ?>
; font: <?php 
    echo $widget_font['font_size'];
    ?>
px/<?php 
    echo $widget_font['line_height'];
    ?>
px <?php 
    echo max_get_font_string($widget_font['font_family']);
    ?>
 !important; font-weight: <?php 
    echo $widget_font['font_weight'];
    ?>
;
	}

	#welcomeTeaser, #sidebar .max_widget_teaser {
  	font-family: <?php 
    echo $welcome_teaser_font['font_family'];
    ?>
;
  	font-size: <?php 
    echo $welcome_teaser_font['font_size'];
    ?>
px;
  	color: <?php 
    echo $welcome_teaser_font['font_color'];
    ?>
;
  	line-height: <?php 
    echo $welcome_teaser_font['line_height'];
    ?>
px;
  	font-weight: <?php 
    echo $welcome_teaser_font['font_weight'];
    ?>
;
	}

  <?php 
    if (!empty($blog_font)) {
        ?>
  .blog h2.entry-title,
  .tag h2.entry-title {
		font: <?php 
        echo $blog_font['font_size'];
        ?>
px/<?php 
        echo $blog_font['line_height'];
        ?>
px <?php 
        echo max_get_font_string($blog_font['font_family']);
        ?>
; font-weight: <?php 
        echo $blog_font['font_weight'];
        ?>
;
		color: <?php 
        echo $blog_font['font_color'];
        ?>
  }
  <?php 
    }
    ?>

	<?php 
    if (get_option_max('homepage_teaser_font_size_bold') != "") {
        ?>
	#welcomeTeaser .inner strong, #sidebar .max_widget_teaser strong { font-size: <?php 
        echo get_option_max('homepage_teaser_font_size_bold');
        ?>
%; }
	<?php 
    }
    ?>

	<?php 
    if (get_option_max('font_fullsize_title') != "") {
        ?>
	#showtitle .imagetitle { color: <?php 
        echo $fsg_title_font['font_color'];
        ?>
!important; font: <?php 
        echo $fsg_title_font['font_size'];
        ?>
px/<?php 
        echo $fsg_title_font['line_height'];
        ?>
px <?php 
        echo max_get_font_string($fsg_title_font['font_family']);
        ?>
!important; font-weight: <?php 
        echo $fsg_title_font['font_weight'];
        ?>
 !important; }
	<?php 
    }
    ?>

	<?php 
    if (get_option_max('font_fullsize_excerpt') != "") {
        ?>
	#showtitle .imagecaption { color: <?php 
        echo $fsg_excerpt_font['font_color'];
        ?>
; font: <?php 
        echo $fsg_excerpt_font['font_size'];
        ?>
px/<?php 
        echo $fsg_excerpt_font['line_height'];
        ?>
px <?php 
        echo max_get_font_string($fsg_excerpt_font['font_family']);
        ?>
!important; font-weight: <?php 
        echo $fsg_excerpt_font['font_weight'];
        ?>
 !important; }
	<?php 
    }
    ?>

</style>
	<?php 
}
Example #25
0
function max_get_timthumb_image($return = false, $p_id = false, $img_size = 'full')
{
    global $post, $imgDimensions, $imgDimensions1x, $p_tpl, $resize_images, $is_retina;
    $max_mobile_detect = new Mobile_Detect();
    // get the sting we need for the different devices
    $size = $img_size;
    // set the attachment image size
    $post_id = !$p_id ? $post->ID : $p_id;
    // check if its a lightbox or a project page link
    $photo_item_type = get_post_meta($post_id, MAX_SHORTNAME . '_photo_item_type_value', true);
    // get the item type
    $imgUrl = max_get_post_image_url($post_id, $size);
    // Get the post image url
    $tpl_show_lightbox = get_post_meta(get_query_var('page_id'), MAX_SHORTNAME . '_disable_post_lightbox', true);
    // check to show the lightbox on this page template
    $use_timthumb = get_option_max('image_use_timthumb');
    $pretty_rel = get_option_max('pretty_enable_lightbox', 'false') == 'false' ? ' data-rel="prettyPhoto"' : '';
    $pretty_rel_gal = get_option_max('pretty_enable_lightbox', 'false') == 'false' ? ' data-rel="prettyPhoto[gal]"' : '';
    // calculate the image dimensions
    if ($max_mobile_detect->isMobile() && !$max_mobile_detect->isTablet() && !empty($imgDimensions1x) && is_array($imgDimensions1x)) {
        // its a mobile phone device so we need other images to display properly
        $_dimensions = max_calculate_image($imgDimensions1x, $imgUrl);
    } else {
        $_dimensions = max_calculate_image($imgDimensions, $imgUrl);
        // desktop images are larger
    }
    // Build the image link
    if (has_post_thumbnail($post_id)) {
        // Get Image URL
        $imgSrc = max_get_image_path($post_id);
        $imgFull = max_get_post_image_url($post_id);
        // get the title
        $title = !get_the_excerpt() ? '' : ' title="' . strip_tags(htmlspecialchars(get_the_excerpt())) . '"';
        $alt = ' alt="' . strip_tags(get_the_title()) . '"';
        $cat_list = array();
        foreach (get_the_category() as $category) {
            $cat_list[] = $category->cat_ID;
        }
        $output = "";
        // check if we have to show a link or links are disabled
        if ($photo_item_type != "Disable Link" && $photo_item_type != 'disable_link') {
            // check if option to show lightbox on this page template is enabled
            if (empty($tpl_show_lightbox) || $tpl_show_lightbox == 'false') {
                if ($photo_item_type == "Lightbox" || $photo_item_type == 'lightbox' || $p_tpl == "template-lightbox.php" || get_option_max('image_always_lightbox') == 'true') {
                    $lightbox_type = get_post_meta($post_id, MAX_SHORTNAME . '_photo_lightbox_type_value', true);
                    $lightbox_link = get_post_meta($post_id, MAX_SHORTNAME . '_photo_item_custom_lightbox', true);
                    if ($p_tpl == "template-lightbox.php") {
                        // check for youtube or vimeo id
                        if ($photo_item_type == 'youtube_embed') {
                            $output .= '<a href="http://www.youtube.com/watch?v=' . get_post_meta($post_id, MAX_SHORTNAME . '_video_embeded_url_value', true) . '"' . $pretty_rel_gal . ' data-link="' . get_permalink($post_id) . '"' . $title . '>';
                        } else {
                            if ($photo_item_type == 'vimeo_embed') {
                                $output .= '<a href="http://www.vimeo.com/' . get_post_meta($post_id, MAX_SHORTNAME . '_video_embeded_url_value', true) . '"' . $pretty_rel_gal . ' data-link="' . get_permalink($post_id) . '"' . $title . '>';
                            } else {
                                if ($photo_item_type == 'selfhosted_embed' || $photo_item_type == 'selfhosted') {
                                    $output .= '<a href="' . get_post_meta($post_id, MAX_SHORTNAME . '_video_url_m4v_value', true) . '?iframe=true" ' . $pretty_rel_gal . ' data-link="' . get_permalink($post_id) . '"' . $title . '>';
                                    // check for lightbox videos
                                } else {
                                    if ($photo_item_type == 'lightbox' && $lightbox_type == 'vimeo') {
                                        $output .= '<a href="' . get_post_meta($post_id, MAX_SHORTNAME . '_photo_video_vimeo_value', true) . '"' . $pretty_rel . $title . ' data-link="' . get_permalink($post_id) . '">';
                                    } else {
                                        if ($photo_item_type == 'lightbox' && $lightbox_type == 'youtube') {
                                            $output .= '<a href="' . get_post_meta($post_id, MAX_SHORTNAME . '_photo_video_youtube_value', true) . '"' . $pretty_rel . $title . ' data-link="' . get_permalink($post_id) . '">';
                                            // by default get the featured image
                                        } else {
                                            $output .= '<a href="' . $imgFull[0] . '"' . $pretty_rel_gal . ' data-link="' . get_permalink($post_id) . '"' . $title . '>';
                                        }
                                    }
                                }
                            }
                        }
                    } else {
                        // Display Lightbox custom link
                        if (!empty($lightbox_link) && $lightbox_type == 'custom') {
                            $output .= '<a href="' . $lightbox_link . '?iframe=true&amp;width=800&amp;height=600" ' . $pretty_rel . ' data-link="' . get_permalink($post_id) . '"' . $title . '>';
                        }
                        // Display Lightbox Photo
                        if ($lightbox_type == "Photo" || $lightbox_type == "photo") {
                            $output .= '<a href="' . $imgFull[0] . '"' . $pretty_rel_gal . ' data-link="' . get_permalink($post_id) . '"' . $title . '>';
                        }
                        // Display Lightbox YouTube Video
                        if ($lightbox_type == "YouTube-Video" || $lightbox_type == "youtube") {
                            $output .= '<a href="' . get_post_meta($post_id, MAX_SHORTNAME . '_photo_video_youtube_value', true) . '"' . $pretty_rel . $title . ' data-link="' . get_permalink($post_id) . '">';
                        }
                        // Display Lightbox Vimeo Video
                        if ($lightbox_type == "Vimeo-Video" || $lightbox_type == "vimeo") {
                            $output .= '<a href="' . get_post_meta($post_id, MAX_SHORTNAME . '_photo_video_vimeo_value', true) . '"' . $pretty_rel . $title . ' data-link="' . get_permalink($post_id) . '">';
                        }
                    }
                } else {
                    if ($photo_item_type == "Project Page" || $photo_item_type == 'projectpage' || $photo_item_type == 'selfhosted_embed' || $photo_item_type == 'selfhosted' || $photo_item_type == 'youtube_embed' || $photo_item_type == 'vimeo_embed') {
                        // Photo Type is a Project Page
                        $output .= '<a href="' . get_permalink($post_id) . '"' . $title . '>';
                    } else {
                        if ($photo_item_type == "External Link" || $photo_item_type == 'external') {
                            $target = get_post_meta($post_id, MAX_SHORTNAME . '_external_link_target_value', true);
                            $str_target = isset($target) && $target != "" ? $target : "_blank";
                            // Photo Type is an external Link
                            $output .= '<a href="' . get_post_meta($post_id, MAX_SHORTNAME . '_photo_external_link_value', true) . '" target="' . get_post_meta($post_id, MAX_SHORTNAME . '_external_link_target_value', true) . '"' . $title . '">';
                        } else {
                            // Get the image link
                            $output .= '<a href="' . $imgFull[0] . '"' . $pretty_rel . $title . ' data-link="' . get_permalink($post_id) . '">';
                        }
                    }
                }
            }
        }
        // fallback to lightbox if something is wrong to not break the image link
    } else {
        if (empty($tpl_show_lightbox) || $tpl_show_lightbox == 'false') {
            // check if option to show lightbox on this page template is enabled
            // Get the image link
            $output .= '<a href="' . $imgFull[0] . '"' . $pretty_rel . $title . ' data-link="' . get_permalink($post_id) . '">';
        }
    }
    // get the new image width calculation if no height or width is set
    if ($_dimensions['height'] == 0) {
        $_dimensions['height'] = "";
    }
    if ($_dimensions['width'] == 0) {
        $_dimensions['width'] = "";
    }
    // resize the image if needed otherwise get the cropped WP version
    if ($resize_images === true) {
        // change to retina image size
        if (!empty($is_retina) && true === $is_retina) {
            $_dimensions['height'] = $_dimensions['height'] * 2;
            $_dimensions['width'] = $_dimensions['width'] * 2;
        }
        $data1x_img = max_get_custom_image_url(get_post_thumbnail_id($post_id), false, $_dimensions['width'], $_dimensions['height'], get_cropping_direction(get_post_meta($post_id, MAX_SHORTNAME . '_photo_cropping_direction_value', true)), false, true);
    } else {
        // lets get the cropped WP version
        // retina size array
        $size_array = array('mobile' => 'large', 'large' => 'full', 'tablet' => 'full', 'full' => 'full');
        // change to retina image size
        if (!empty($is_retina) && true === $is_retina) {
            $size = $size_array[$size];
        }
        $_wp_image = max_get_post_image_url($post_id, $size);
        $data1x_img = $_wp_image[0];
    }
    // get the image tag, it's always the same
    $output .= '<img src="' . $data1x_img . '" ' . $alt . ' data-src="' . $data1x_img . '" class="the-post-image" />';
    // Close Link if its not a disabled link
    if ($photo_item_type != "Disable Link" && $photo_item_type != 'disable_link') {
        if (empty($tpl_show_lightbox) || $tpl_show_lightbox == 'false') {
            // check if option to show lightbox on this page template is enabled
            $output .= '</a>';
        }
    }
    if ($return === true) {
        return $output;
    } else {
        echo $output;
    }
}
Example #26
0
function max_get_infinitescroll_js()
{
    ?>
	<script type="text/javascript">

		//<![CDATA[
		jQuery(document).ready(function($) {

			var $container   = jQuery('#portfolioList'),
					$pagination  = jQuery('.pagination');

					// hide pagination
					$pagination.hide();

			if(jQuery('.pagination').size() > 0){

				jQuery(window).load(function(){

					$container.infinitescroll({
						navSelector  : '.pagination',    // selector for the paged navigation
						nextSelector : '.pagination a',  // selector for the NEXT link (to page 2)
						itemSelector : '.portfolio-list li.item', // selector for all items you'll retrieve
						bufferPx     : 100,
						prefill      : true,
						loading: {
							msgText: '<?php 
    _e('Loading new photos...', MAX_SHORTNAME);
    ?>
',
							finishedMsg: 'No more photos to load.',
							img: '<?php 
    echo get_template_directory_uri();
    ?>
/css/<?php 
    echo get_option_max('color_main');
    ?>
/loading.gif',
								selector: '.infscr-loading'
							}
						},

						// call Isotope as a callback
						function( newElements ) {

							$container.livequery(function(){
							})

							$( newElements ).find('img').imagesLoaded(function(){

								if( $container.data('isotope') ){
									$( newElements ).css({ width: $container.find('li:first').outerWidth() }); // set the width to the current first item width
									$container.isotope( 'appended', $( newElements ) ); // append item set to existing isotope
								}else{
									$container.append( $( newElements ) );
								}

								$container.css({ background: 'none' }).find('li.item').css({ visibility: 'visible' });

							});
						}
					);

				});

			}

		});
		//]]>
	</script>

<?php 
}
Example #27
0
        echo '<li>' . get_option_max('contact_adress_2') . '</li>';
    }
    ?>
							<?php 
    if (get_option_max('contact_phone') != "") {
        echo '<li>' . __('Phone', MAX_SHORTNAME) . ': ' . get_option_max('contact_phone') . '</li>';
    }
    ?>
							<?php 
    if (get_option_max('contact_fax') != "") {
        echo '<li>' . __('Fax', MAX_SHORTNAME) . ': ' . get_option_max('contact_fax') . '</li>';
    }
    ?>
							<?php 
    if (get_option_max('contact_info_email') != "") {
        echo '<li>' . __('eMail', MAX_SHORTNAME) . ': <a href="mailto:' . get_option_max('contact_info_email') . '">' . get_option_max('contact_info_email') . '</a></li>';
    }
    ?>
						</ul>
					</div>
					<?php 
}
?>


					<?php 
$class_3 = "col_one_third col_one_third_last";
?>
					<div class="<?php 
echo $class_3;
?>
Example #28
0
the_content();
?>
						<?php 
wp_link_pages();
?>
					</div><!-- .entry-content -->

				</div>

			<?php 
if (!post_password_required()) {
    ?>

			<?php 
    // Check if author should be shown
    if (get_option_max('general_show_author') == "true") {
        echo do_shortcode("[authorbox]");
    }
    ?>

			<?php 
    echo do_shortcode("[related_posts]");
    ?>

			<?php 
    comments_template('', true);
    ?>

			<div class="pagination hidden"><p><?php 
    posts_nav_link(' ');
    ?>
Example #29
0
/**
 * Template Name: Portfolio 1 Column
 *
 * @package WordPress
 * @subpackage Invictus
 * @since Invictus 1.0
 */
get_header();
wp_reset_query();
// show the item caption of an image?
$itemCaption = true;
// check for header type
$header_type = get_option_max("header_type", 'default');
// check if we have a full-width nav and fill content is activated
$fill_content = $header_type == 'full-width' ? get_option_max("layout_fill_content", 'false') : 'false';
// get the image dimensions
if ($fill_content === 'false') {
    $imgDimensions = array('width' => 800, 'height' => 600);
} else {
    $imgDimensions = array('width' => 1024, 'height' => 768);
}
?>
<div id="single-page" class="clearfix left-sidebar">


	<div id="primary" class="portfolio-one-column" >
		<div id="content" role="main">

			<?php 
// get the page header template part
Example #30
0
							<div class="shadow">
							<?php 
        // get the gallery item
        max_get_post_custom_image(get_post_thumbnail_id(), false, false, $image_size);
        if (!empty($itemCaption) && $itemCaption === true) {
            // check if caption option is selected
            if (get_option_max('image_show_caption') == 'true' || get_option_max('image_show_caption') == 'always') {
                ?>

									<div class="item-caption">
										<strong><?php 
                echo get_the_title();
                ?>
</strong><br />
										<?php 
                if (get_the_excerpt() != "" && get_option_max('image_caption_excerpt', 'false') == 'false') {
                    // check the excerpt length and cut it off, if necessary
                    $_excerpt = get_the_excerpt();
                    echo strlen($_excerpt) > $substrExcerpt ? substr($_excerpt, 0, $substrExcerpt - 3) . "..." : $_excerpt;
                }
                ?>
									</div>

									<?php 
            }
        }
        ?>
							</div>

						</li>